aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gregtech/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/gregtech/common')
-rw-r--r--src/main/java/gregtech/common/GT_Client.java330
-rw-r--r--src/main/java/gregtech/common/GT_DummyWorld.java102
-rw-r--r--src/main/java/gregtech/common/GT_IteratorRandom.java1
-rw-r--r--src/main/java/gregtech/common/GT_Network.java50
-rw-r--r--src/main/java/gregtech/common/GT_PlayerActivityLogger.java9
-rw-r--r--src/main/java/gregtech/common/GT_Pollution.java168
-rw-r--r--src/main/java/gregtech/common/GT_Proxy.java2073
-rw-r--r--src/main/java/gregtech/common/GT_RecipeAdder.java1762
-rw-r--r--src/main/java/gregtech/common/GT_Server.java1
-rw-r--r--src/main/java/gregtech/common/GT_ThaumcraftCompat.java86
-rw-r--r--src/main/java/gregtech/common/GT_UndergroundOil.java82
-rw-r--r--src/main/java/gregtech/common/GT_Worldgen_GT_Ore_Layer.java437
-rw-r--r--src/main/java/gregtech/common/GT_Worldgen_GT_Ore_SmallPieces.java88
-rw-r--r--src/main/java/gregtech/common/GT_Worldgen_Stone.java235
-rw-r--r--src/main/java/gregtech/common/GT_Worldgenerator.java353
-rw-r--r--src/main/java/gregtech/common/bees/GT_AlleleBeeSpecies.java20
-rw-r--r--src/main/java/gregtech/common/bees/GT_AlleleHelper.java97
-rw-r--r--src/main/java/gregtech/common/bees/GT_Bee_Mutation.java48
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings1.java31
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings2.java19
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings3.java15
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings4.java114
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings5.java8
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings6.java8
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings8.java65
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings9.java10
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java21
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Concretes.java15
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Granites.java10
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Machines.java115
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Metal.java8
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Ores.java75
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java86
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Ores_UB1.java60
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Ores_UB2.java64
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Ores_UB3.java64
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Reinforced.java87
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Stones.java18
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java47
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Block_Storage.java10
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Cyclotron_Coils.java10
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Cyclotron_Item_Casings.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings1.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings2.java2
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings3.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings4.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings5.java19
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings6.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings8.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings9.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java55
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Concretes.java9
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Granites.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_LongDistancePipe.java15
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Machines.java245
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Ores.java39
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java11
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Item_Storage.java5
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Material_Casings.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Material_Machines.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Material_Reinforced.java1
-rw-r--r--src/main/java/gregtech/common/blocks/GT_Packet_Ores.java9
-rw-r--r--src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java159
-rw-r--r--src/main/java/gregtech/common/covers/CoverInfo.java27
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Arm.java236
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_ControlsWork.java132
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Conveyor.java161
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Crafting.java51
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_DoesWork.java114
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Drain.java110
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_EUMeter.java160
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_FacadeAE.java4
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_FacadeBase.java223
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_FluidLimiter.java63
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_FluidRegulator.java325
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_FluidStorageMonitor.java157
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Fluidfilter.java319
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_ItemFilter.java120
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_ItemMeter.java165
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Lens.java5
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java121
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_NeedMaintainance.java220
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_PlayerDetector.java103
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Pump.java177
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneConductor.java32
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverExternal.java15
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverInternal.java21
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneSignalizer.java31
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterExternal.java15
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterInternal.java16
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_RedstoneWirelessBase.java108
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Screen.java32
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Shutter.java124
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_SolarPanel.java42
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_SteamValve.java7
-rw-r--r--src/main/java/gregtech/common/covers/GT_Cover_Vent.java21
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverBase.java61
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverExternal.java17
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverInternal.java17
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterBase.java64
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterExternal.java13
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterInternal.java17
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedWirelessRedstoneBase.java117
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessFluidDetector.java46
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessItemDetector.java110
-rw-r--r--src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessMaintenanceDetector.java70
-rw-r--r--src/main/java/gregtech/common/entities/GT_EntityFXPollution.java1
-rw-r--r--src/main/java/gregtech/common/entities/GT_Entity_Arrow.java156
-rw-r--r--src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java30
-rw-r--r--src/main/java/gregtech/common/fluid/GT_Fluid.java33
-rw-r--r--src/main/java/gregtech/common/fluid/GT_FluidBuilder.java18
-rw-r--r--src/main/java/gregtech/common/gui/modularui/UIHelper.java80
-rw-r--r--src/main/java/gregtech/common/gui/modularui/uifactory/SelectItemUIFactory.java124
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/AESlotWidget.java7
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/CoverCycleButtonWidget.java28
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/CoverDataControllerWidget.java77
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_CycleButtonWidget.java5
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_SlotWidget.java11
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_TextFieldWidget.java9
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_ToggleButtonWidget.java8
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java41
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/FluidDisplaySlotWidget.java82
-rw-r--r--src/main/java/gregtech/common/gui/modularui/widget/ItemWatcherSlotWidget.java10
-rw-r--r--src/main/java/gregtech/common/items/CombType.java39
-rw-r--r--src/main/java/gregtech/common/items/DropType.java18
-rw-r--r--src/main/java/gregtech/common/items/GT_DepletetCell_Item.java22
-rw-r--r--src/main/java/gregtech/common/items/GT_FluidDisplayItem.java58
-rw-r--r--src/main/java/gregtech/common/items/GT_IntegratedCircuit_Item.java269
-rw-r--r--src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java6526
-rw-r--r--src/main/java/gregtech/common/items/GT_MetaGenerated_Item_02.java4319
-rw-r--r--src/main/java/gregtech/common/items/GT_MetaGenerated_Item_03.java1434
-rw-r--r--src/main/java/gregtech/common/items/GT_MetaGenerated_Item_98.java76
-rw-r--r--src/main/java/gregtech/common/items/GT_MetaGenerated_Item_99.java42
-rw-r--r--src/main/java/gregtech/common/items/GT_MetaGenerated_Tool_01.java243
-rw-r--r--src/main/java/gregtech/common/items/GT_NeutronReflector_Item.java15
-rw-r--r--src/main/java/gregtech/common/items/GT_SensorCard_Item.java21
-rw-r--r--src/main/java/gregtech/common/items/GT_VolumetricFlask.java113
-rw-r--r--src/main/java/gregtech/common/items/ItemComb.java1390
-rw-r--r--src/main/java/gregtech/common/items/ItemDrop.java33
-rw-r--r--src/main/java/gregtech/common/items/ItemPollen.java11
-rw-r--r--src/main/java/gregtech/common/items/ItemPropolis.java38
-rw-r--r--src/main/java/gregtech/common/items/PollenType.java8
-rw-r--r--src/main/java/gregtech/common/items/PropolisType.java7
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow.java65
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow_Potion.java40
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Cover_Tool.java94
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Crowbar.java24
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_DataOrb.java7
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_DataStick.java7
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Hoe.java36
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Lighter.java63
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_None.java62
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Essentia.java45
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Fluid.java47
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Item.java52
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_PrintedPages.java7
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Prospecting.java75
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Scanner.java31
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Scoop.java42
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Screwdriver.java24
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Sense.java29
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_SensorKit.java30
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_SoftHammer.java65
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Sonictron.java34
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Spray_Color.java40
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Switch_Metadata.java25
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_Wrench.java67
-rw-r--r--src/main/java/gregtech/common/items/behaviors/Behaviour_WrittenBook.java25
-rw-r--r--src/main/java/gregtech/common/misc/GT_ClientPollutionMap.java67
-rw-r--r--src/main/java/gregtech/common/misc/GT_Command.java235
-rw-r--r--src/main/java/gregtech/common/misc/GT_DrillingLogicDelegate.java56
-rw-r--r--src/main/java/gregtech/common/misc/GT_IDrillingLogicDelegateOwner.java3
-rw-r--r--src/main/java/gregtech/common/misc/GlobalEnergyWorldSavedData.java4
-rw-r--r--src/main/java/gregtech/common/net/MessageSetFlaskCapacity.java11
-rw-r--r--src/main/java/gregtech/common/net/MessageUpdateFluidDisplayItem.java11
-rw-r--r--src/main/java/gregtech/common/power/BasicMachineEUPower.java6
-rw-r--r--src/main/java/gregtech/common/power/EUPower.java1
-rw-r--r--src/main/java/gregtech/common/power/Power.java1
-rw-r--r--src/main/java/gregtech/common/power/SteamPower.java3
-rw-r--r--src/main/java/gregtech/common/power/UnspecifiedEUPower.java1
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BasicLogic.java12
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BitAnd.java10
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_CombinationLock.java1
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Equals.java8
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Pulser.java10
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Randomizer.java5
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_RedstoneMeter.java8
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Repeater.java1
-rw-r--r--src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Timer.java1
-rw-r--r--src/main/java/gregtech/common/render/CosmicItemRendererGT.java4
-rw-r--r--src/main/java/gregtech/common/render/GT_CapeRenderer.java46
-rw-r--r--src/main/java/gregtech/common/render/GT_CopiedBlockTexture.java26
-rw-r--r--src/main/java/gregtech/common/render/GT_CopiedCTMBlockTexture.java48
-rw-r--r--src/main/java/gregtech/common/render/GT_FlaskRenderer.java13
-rw-r--r--src/main/java/gregtech/common/render/GT_FluidDisplayStackRenderer.java20
-rw-r--r--src/main/java/gregtech/common/render/GT_IconFlipped.java4
-rw-r--r--src/main/java/gregtech/common/render/GT_MetaGenerated_Tool_Renderer.java28
-rw-r--r--src/main/java/gregtech/common/render/GT_MultiTexture.java14
-rw-r--r--src/main/java/gregtech/common/render/GT_PollutionRenderer.java52
-rw-r--r--src/main/java/gregtech/common/render/GT_RenderUtil.java20
-rw-r--r--src/main/java/gregtech/common/render/GT_RenderedTexture.java69
-rw-r--r--src/main/java/gregtech/common/render/GT_Renderer_Block.java319
-rw-r--r--src/main/java/gregtech/common/render/GT_Renderer_Entity_Arrow.java4
-rw-r--r--src/main/java/gregtech/common/render/GT_SidedTexture.java32
-rw-r--r--src/main/java/gregtech/common/render/GT_TextureBase.java6
-rw-r--r--src/main/java/gregtech/common/render/GT_TextureBuilder.java19
-rw-r--r--src/main/java/gregtech/common/render/IRenderedBlock.java11
-rw-r--r--src/main/java/gregtech/common/render/IRenderedBlockSideCheck.java6
-rw-r--r--src/main/java/gregtech/common/render/items/CosmicNeutroniumRenderer.java11
-rw-r--r--src/main/java/gregtech/common/render/items/GT_GeneratedItem_Renderer.java26
-rw-r--r--src/main/java/gregtech/common/render/items/GT_GeneratedMaterial_Renderer.java24
-rw-r--r--src/main/java/gregtech/common/render/items/GT_MetaGenerated_Item_Renderer.java12
-rw-r--r--src/main/java/gregtech/common/render/items/GaiaSpiritRenderer.java8
-rw-r--r--src/main/java/gregtech/common/render/items/InfinityRenderer.java16
-rw-r--r--src/main/java/gregtech/common/render/items/TranscendentMetalRenderer.java49
-rw-r--r--src/main/java/gregtech/common/render/items/UniversiumRenderer.java26
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java53
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java132
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java73
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java43
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java143
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java53
-rw-r--r--src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_TypeFilter.java51
-rw-r--r--src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler.java148
-rw-r--r--src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Bronze.java225
-rw-r--r--src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Lava.java61
-rw-r--r--src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar.java163
-rw-r--r--src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar_Steel.java38
-rw-r--r--src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Steel.java41
-rw-r--r--src/main/java/gregtech/common/tileentities/debug/GT_MetaTileEntity_AdvDebugStructureWriter.java201
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_DieselGenerator.java185
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_GasTurbine.java182
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_LightningRod.java69
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicEnergyConverter.java106
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicalEnergyAbsorber.java221
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_NaquadahReactor.java127
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_PlasmaGenerator.java65
-rw-r--r--src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_SteamTurbine.java149
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Bronze.java24
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_BronzeBricks.java35
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Steel.java18
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_SteelBricks.java34
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_InputBus_ME.java115
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_OutputBus_ME.java75
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_Output_ME.java78
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_AdvSeismicProspector.java174
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Boxinator.java115
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Charger.java29
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_CuringOven.java94
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Disassembler.java197
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java474
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Massfabricator.java88
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MicrowaveEnergyTransmitter.java235
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Miner.java178
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MonsterRepellent.java85
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_PotionBrewer.java83
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Printer.java46
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Pump.java293
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Replicator.java82
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_RockBreaker.java77
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Scanner.java166
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_SeismicProspector.java213
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Teleporter.java387
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineBase.java113
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineFluid.java67
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineItem.java65
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AbstractMultiFurnace.java3
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AssemblyLine.java209
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BrickedBlastFurnace.java44
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BronzeBlastFurnace.java30
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Charcoal_Pit.java115
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Cleanroom.java163
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller1.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller2.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfillerBase.java35
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DieselEngine.java218
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DistillationTower.java149
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DrillerBase.java183
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ElectricBlastFurnace.java247
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ExtremeDieselEngine.java143
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer.java389
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer1.java27
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer2.java27
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer3.java27
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_HeatExchanger.java210
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ImplosionCompressor.java76
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_IntegratedOreFactory.java235
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler.java181
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Bronze.java3
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Steel.java4
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Titanium.java4
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_TungstenSteel.java4
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeChemicalReactor.java198
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java242
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java79
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_GasAdvanced.java77
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java95
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java218
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java92
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_MultiFurnace.java249
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_NanoForge.java192
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilCracker.java177
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill1.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill2.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill3.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillBase.java157
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillInfinite.java19
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant1.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant2.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant3.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant4.java1
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlantBase.java128
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PCBFactory.java946
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PlasmaForge.java1554
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PrimitiveBlastFurnace.java237
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java269
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PyrolyseOven.java124
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_VacuumFreezer.java81
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/multiblock/MultiBlock_Macerator.java63
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Bronze.java89
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Steel.java89
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Bronze.java88
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Steel.java88
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Bronze.java87
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Steel.java87
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Bronze.java102
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Steel.java102
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Bronze.java95
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Steel.java93
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Bronze.java107
-rw-r--r--src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Steel.java106
-rw-r--r--src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalChestBase.java221
-rw-r--r--src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalTankBase.java347
-rw-r--r--src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_Locker.java34
-rw-r--r--src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumChest.java8
-rw-r--r--src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumTank.java40
-rw-r--r--src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_SuperTank.java38
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool.java48
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Axe.java71
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_BranchCutter.java46
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_ButcheryKnife.java21
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_BuzzSaw.java26
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_HV.java9
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_LV.java87
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_MV.java9
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Crowbar.java33
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Drill_HV.java14
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Drill_LV.java36
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Drill_MV.java9
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_File.java28
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_HardHammer.java77
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Hoe.java33
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_JackHammer.java52
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Knife.java23
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Mortar.java18
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Pickaxe.java34
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Plow.java64
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Plunger.java30
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_RollingPin.java20
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Saw.java57
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Scoop.java29
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Screwdriver.java36
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Screwdriver_LV.java12
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Sense.java62
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Shovel.java36
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_SoftHammer.java35
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Soldering_Iron.java36
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Sword.java18
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Turbine.java18
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Turbine_Huge.java1
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Turbine_Large.java1
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Turbine_Normal.java1
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Turbine_Small.java1
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_UniversalSpade.java38
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_WireCutter.java25
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Wrench.java33
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Wrench_HV.java12
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Wrench_LV.java20
-rw-r--r--src/main/java/gregtech/common/tools/GT_Tool_Wrench_MV.java12
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_BranchCutter.java4
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_File.java4
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Knife.java4
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Multitool.java6
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Saw.java4
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Screwdriver.java4
-rw-r--r--src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_WireCutter.java4
386 files changed, 21592 insertions, 24907 deletions
diff --git a/src/main/java/gregtech/common/GT_Client.java b/src/main/java/gregtech/common/GT_Client.java
index 20d0eca81f..3978a6383b 100644
--- a/src/main/java/gregtech/common/GT_Client.java
+++ b/src/main/java/gregtech/common/GT_Client.java
@@ -1,7 +1,7 @@
// Decompiled by Jad v1.5.8g. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.kpdus.com/jad.html
// Decompiler options: packimports(3)
-// Source File Name: GT_Client.java
+// Source File Name: GT_Client.java
package gregtech.common;
@@ -9,12 +9,44 @@ import static gregtech.api.enums.GT_Values.ALL_VALID_SIDES;
import static gregtech.api.enums.GT_Values.calculateMaxPlasmaTurbineEfficiency;
import static org.lwjgl.opengl.GL11.GL_LINE_LOOP;
+import java.net.URL;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Scanner;
+
+import net.minecraft.block.Block;
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.renderer.GLAllocation;
+import net.minecraft.client.renderer.Tessellator;
+import net.minecraft.client.resources.IReloadableResourceManager;
+import net.minecraft.client.resources.IResourceManager;
+import net.minecraft.client.resources.IResourceManagerReloadListener;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.MovingObjectPosition;
+import net.minecraft.world.ChunkCoordIntPair;
+import net.minecraft.world.World;
+import net.minecraftforge.client.event.DrawBlockHighlightEvent;
+import net.minecraftforge.common.MinecraftForge;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.oredict.OreDictionary;
+
+import org.lwjgl.opengl.GL11;
+
import codechicken.lib.vec.Rotation;
import codechicken.lib.vec.Scale;
import codechicken.lib.vec.Transformation;
import codechicken.lib.vec.Translation;
+
import com.gtnewhorizon.structurelib.alignment.IAlignment;
import com.gtnewhorizon.structurelib.alignment.IAlignmentProvider;
+
import cpw.mods.fml.client.event.ConfigChangedEvent;
import cpw.mods.fml.client.registry.RenderingRegistry;
import cpw.mods.fml.common.Loader;
@@ -51,76 +83,33 @@ import gregtech.common.tileentities.debug.GT_MetaTileEntity_AdvDebugStructureWri
import gregtech.loaders.ExtraIcons;
import gregtech.loaders.preload.GT_PreLoad;
import ic2.api.tile.IWrenchable;
-import java.net.URL;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Scanner;
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.renderer.GLAllocation;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.resources.IReloadableResourceManager;
-import net.minecraft.client.resources.IResourceManager;
-import net.minecraft.client.resources.IResourceManagerReloadListener;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.MovingObjectPosition;
-import net.minecraft.world.ChunkCoordIntPair;
-import net.minecraft.world.World;
-import net.minecraftforge.client.event.DrawBlockHighlightEvent;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.oredict.OreDictionary;
-import org.lwjgl.opengl.GL11;
// Referenced classes of package gregtech.common:
-// GT_Proxy
+// GT_Proxy
public class GT_Client extends GT_Proxy implements Runnable {
- public static final String GTNH_CAPE_LIST_URL =
- "https://raw.githubusercontent.com/GTNewHorizons/CustomGTCapeHook-Cape-List/master/capes.txt";
- public static final String GT_CAPE_LIST_URL =
- "http://gregtech.overminddl1.com/com/gregoriust/gregtech/supporterlist.txt";
+ public static final String GTNH_CAPE_LIST_URL = "https://raw.githubusercontent.com/GTNewHorizons/CustomGTCapeHook-Cape-List/master/capes.txt";
+ public static final String GT_CAPE_LIST_URL = "http://gregtech.overminddl1.com/com/gregoriust/gregtech/supporterlist.txt";
private static final List<Block> ROTATABLE_VANILLA_BLOCKS;
- private static final int[][] GRID_SWITCH_TABLE = new int[][] {
- {0, 5, 3, 1, 2, 4},
- {5, 0, 1, 3, 2, 4},
- {1, 3, 0, 5, 2, 4},
- {3, 1, 5, 0, 2, 4},
- {4, 2, 3, 1, 0, 5},
- {2, 4, 3, 1, 5, 0},
- };
+ private static final int[][] GRID_SWITCH_TABLE = new int[][] { { 0, 5, 3, 1, 2, 4 }, { 5, 0, 1, 3, 2, 4 },
+ { 1, 3, 0, 5, 2, 4 }, { 3, 1, 5, 0, 2, 4 }, { 4, 2, 3, 1, 0, 5 }, { 2, 4, 3, 1, 5, 0 }, };
// don't ask. these "just works"
private static final Transformation ROTATION_MARKER_TRANSFORM_CENTER = new Scale(0.5);
private static final Transformation[] ROTATION_MARKER_TRANSFORMS_SIDES_TRANSFORMS = {
- new Scale(0.25).with(new Translation(0, 0, 0.375)).compile(),
- new Scale(0.25).with(new Translation(0.375, 0, 0)).compile(),
- new Scale(0.25).with(new Translation(0, 0, -0.375)).compile(),
- new Scale(0.25).with(new Translation(-0.375, 0, 0)).compile(),
- };
- private static final int[] ROTATION_MARKER_TRANSFORMS_SIDES = {
- -1, -1, 2, 0, 3, 1,
- -1, -1, 0, 2, 3, 1,
- 0, 2, -1, -1, 3, 1,
- 2, 0, -1, -1, 3, 1,
- 1, 3, 2, 0, -1, -1,
- 3, 1, 2, 0, -1, -1
- };
+ new Scale(0.25).with(new Translation(0, 0, 0.375)).compile(),
+ new Scale(0.25).with(new Translation(0.375, 0, 0)).compile(),
+ new Scale(0.25).with(new Translation(0, 0, -0.375)).compile(),
+ new Scale(0.25).with(new Translation(-0.375, 0, 0)).compile(), };
+ private static final int[] ROTATION_MARKER_TRANSFORMS_SIDES = { -1, -1, 2, 0, 3, 1, -1, -1, 0, 2, 3, 1, 0, 2, -1,
+ -1, 3, 1, 2, 0, -1, -1, 3, 1, 1, 3, 2, 0, -1, -1, 3, 1, 2, 0, -1, -1 };
private static final Transformation[] ROTATION_MARKER_TRANSFORMS_CORNER = {
- new Scale(0.25).with(new Translation(0.375, 0, 0.375)).compile(),
- new Scale(0.25).with(new Translation(-0.375, 0, 0.375)).compile(),
- new Scale(0.25).with(new Translation(0.375, 0, -0.375)).compile(),
- new Scale(0.25).with(new Translation(-0.375, 0, -0.375)).compile(),
- };
+ new Scale(0.25).with(new Translation(0.375, 0, 0.375)).compile(),
+ new Scale(0.25).with(new Translation(-0.375, 0, 0.375)).compile(),
+ new Scale(0.25).with(new Translation(0.375, 0, -0.375)).compile(),
+ new Scale(0.25).with(new Translation(-0.375, 0, -0.375)).compile(), };
private static int rotationMarkerDisplayList;
private static boolean rotationMarkerDisplayListCompiled = false;
@@ -284,8 +273,8 @@ public class GT_Client extends GT_Proxy implements Runnable {
private static boolean checkedForChicken = false;
- private static void drawGrid(
- DrawBlockHighlightEvent aEvent, boolean showCoverConnections, boolean aIsWrench, boolean aIsSneaking) {
+ private static void drawGrid(DrawBlockHighlightEvent aEvent, boolean showCoverConnections, boolean aIsWrench,
+ boolean aIsSneaking) {
if (!checkedForChicken) {
try {
Class.forName("codechicken.lib.vec.Rotation");
@@ -322,8 +311,8 @@ public class GT_Client extends GT_Proxy implements Runnable {
GL11.glVertex3d(+.25D, .0D, +.50D);
GL11.glVertex3d(-.25D, .0D, -.50D);
GL11.glVertex3d(-.25D, .0D, +.50D);
- final TileEntity tTile =
- aEvent.player.worldObj.getTileEntity(aEvent.target.blockX, aEvent.target.blockY, aEvent.target.blockZ);
+ final TileEntity tTile = aEvent.player.worldObj
+ .getTileEntity(aEvent.target.blockX, aEvent.target.blockY, aEvent.target.blockZ);
// draw connection indicators
byte tConnections = 0;
@@ -406,8 +395,8 @@ public class GT_Client extends GT_Proxy implements Runnable {
}
} else {
drawExtendedRotationMarker(
- ROTATION_MARKER_TRANSFORMS_SIDES_TRANSFORMS[
- ROTATION_MARKER_TRANSFORMS_SIDES[tSideHit * 6 + direction.ordinal()]],
+ ROTATION_MARKER_TRANSFORMS_SIDES_TRANSFORMS[ROTATION_MARKER_TRANSFORMS_SIDES[tSideHit * 6
+ + direction.ordinal()]],
aIsSneaking,
true);
}
@@ -526,39 +515,29 @@ public class GT_Client extends GT_Proxy implements Runnable {
super.onPreLoad();
MinecraftForge.EVENT_BUS.register(new ExtraIcons());
- Minecraft.getMinecraft()
- .getResourcePackRepository()
- .rprMetadataSerializer
+ Minecraft.getMinecraft().getResourcePackRepository().rprMetadataSerializer
.registerMetadataSectionType(new ColorsMetadataSectionSerializer(), ColorsMetadataSection.class);
new GT_MetaTileEntity_AdvDebugStructureWriter.ForgeEventHandler();
- final String[] arr = {
- "renadi", "hanakocz", "MysteryDump", "Flaver4", "x_Fame", "Peluche321", "Goshen_Ithilien", "manf", "Bimgo",
- "leagris",
- "IAmMinecrafter02", "Cerous", "Devilin_Pixy", "Bkarlsson87", "BadAlchemy", "CaballoCraft", "melanclock",
- "Resursator", "demanzke", "AndrewAmmerlaan",
- "Deathlycraft", "Jirajha", "Axlegear", "kei_kouma", "Dracion", "dungi", "Dorfschwein", "Zero Tw0",
- "mattiagraz85", "sebastiank30",
- "Plem", "invultri", "grillo126", "malcanteth", "Malevolence_", "Nicholas_Manuel", "Sirbab", "kehaan",
- "bpgames123", "semig0d",
- "9000bowser", "Sovereignty89", "Kris1432", "xander_cage_", "samuraijp", "bsaa", "SpwnX", "tworf", "Kadah",
- "kanni",
- "Stute", "Hegik", "Onlyme", "t3hero", "Hotchi", "jagoly", "Nullav", "BH5432", "Sibmer", "inceee",
- "foxxx0", "Hartok", "TMSama", "Shlnen", "Carsso", "zessirb", "meep310", "Seldron", "yttr1um", "hohounk",
- "freebug", "Sylphio", "jmarler", "Saberawr", "r00teniy", "Neonbeta", "yinscape", "voooon24", "Quintine",
- "peach774",
- "lepthymo", "bildeman", "Kremnari", "Aerosalo", "OndraSter", "oscares91", "mr10movie", "Daxx367x2",
- "EGERTRONx", "aka13_404",
- "Abouttabs", "Johnstaal", "djshiny99", "megatronp", "DZCreeper", "Kane_Hart", "Truculent", "vidplace7",
- "simon6689", "MomoNasty",
- "UnknownXLV", "goreacraft", "Fluttermine", "Daddy_Cecil", "MrMaleficus", "TigersFangs", "cublikefoot",
- "chainman564", "NikitaBuker", "Misha999777",
- "25FiveDetail", "AntiCivilBoy", "michaelbrady", "xXxIceFirexXx", "Speedynutty68", "GarretSidzaka",
- "HallowCharm977", "mastermind1919", "The_Hypersonic", "diamondguy2798",
- "zF4ll3nPr3d4t0r", "CrafterOfMines57", "XxELIT3xSNIP3RxX", "SuterusuKusanagi", "xavier0014", "adamros",
- "alexbegt"
- };
+ final String[] arr = { "renadi", "hanakocz", "MysteryDump", "Flaver4", "x_Fame", "Peluche321",
+ "Goshen_Ithilien", "manf", "Bimgo", "leagris", "IAmMinecrafter02", "Cerous", "Devilin_Pixy",
+ "Bkarlsson87", "BadAlchemy", "CaballoCraft", "melanclock", "Resursator", "demanzke", "AndrewAmmerlaan",
+ "Deathlycraft", "Jirajha", "Axlegear", "kei_kouma", "Dracion", "dungi", "Dorfschwein", "Zero Tw0",
+ "mattiagraz85", "sebastiank30", "Plem", "invultri", "grillo126", "malcanteth", "Malevolence_",
+ "Nicholas_Manuel", "Sirbab", "kehaan", "bpgames123", "semig0d", "9000bowser", "Sovereignty89",
+ "Kris1432", "xander_cage_", "samuraijp", "bsaa", "SpwnX", "tworf", "Kadah", "kanni", "Stute", "Hegik",
+ "Onlyme", "t3hero", "Hotchi", "jagoly", "Nullav", "BH5432", "Sibmer", "inceee", "foxxx0", "Hartok",
+ "TMSama", "Shlnen", "Carsso", "zessirb", "meep310", "Seldron", "yttr1um", "hohounk", "freebug",
+ "Sylphio", "jmarler", "Saberawr", "r00teniy", "Neonbeta", "yinscape", "voooon24", "Quintine",
+ "peach774", "lepthymo", "bildeman", "Kremnari", "Aerosalo", "OndraSter", "oscares91", "mr10movie",
+ "Daxx367x2", "EGERTRONx", "aka13_404", "Abouttabs", "Johnstaal", "djshiny99", "megatronp", "DZCreeper",
+ "Kane_Hart", "Truculent", "vidplace7", "simon6689", "MomoNasty", "UnknownXLV", "goreacraft",
+ "Fluttermine", "Daddy_Cecil", "MrMaleficus", "TigersFangs", "cublikefoot", "chainman564", "NikitaBuker",
+ "Misha999777", "25FiveDetail", "AntiCivilBoy", "michaelbrady", "xXxIceFirexXx", "Speedynutty68",
+ "GarretSidzaka", "HallowCharm977", "mastermind1919", "The_Hypersonic", "diamondguy2798",
+ "zF4ll3nPr3d4t0r", "CrafterOfMines57", "XxELIT3xSNIP3RxX", "SuterusuKusanagi", "xavier0014", "adamros",
+ "alexbegt" };
for (String tName : arr) {
mCapeList.add(tName.toLowerCase());
}
@@ -611,9 +590,10 @@ public class GT_Client extends GT_Proxy implements Runnable {
}
// reobf doesn't work with lambda, so this must be a class
- //noinspection Convert2Lambda
+ // noinspection Convert2Lambda
((IReloadableResourceManager) Minecraft.getMinecraft().getResourceManager())
.registerReloadListener(new IResourceManagerReloadListener() {
+
@Override
public void onResourceManagerReload(IResourceManager l) {
GT_GUIColorOverride.onResourceManagerReload();
@@ -717,9 +697,8 @@ public class GT_Client extends GT_Proxy implements Runnable {
recipe.mHidden = false;
}
}
- for (Iterator<Map.Entry<GT_PlayedSound, Integer>> iterator =
- GT_Utility.sPlayedSoundMap.entrySet().iterator();
- iterator.hasNext(); ) {
+ for (Iterator<Map.Entry<GT_PlayedSound, Integer>> iterator = GT_Utility.sPlayedSoundMap.entrySet()
+ .iterator(); iterator.hasNext();) {
Map.Entry<GT_PlayedSound, Integer> tEntry = iterator.next();
if (tEntry.getValue() < 0) {
iterator.remove();
@@ -730,22 +709,23 @@ public class GT_Client extends GT_Proxy implements Runnable {
if (!GregTech_API.mServerStarted) GregTech_API.mServerStarted = true;
if (GT_Values.updateFluidDisplayItems) {
final MovingObjectPosition trace = Minecraft.getMinecraft().objectMouseOver;
- if (trace != null
- && trace.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK
- && (mLastUpdatedBlockX != trace.blockX
- && mLastUpdatedBlockY != trace.blockY
- && mLastUpdatedBlockZ != trace.blockZ
- || afterSomeTime % 10 == 0)) {
+ if (trace != null && trace.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK
+ && (mLastUpdatedBlockX != trace.blockX && mLastUpdatedBlockY != trace.blockY
+ && mLastUpdatedBlockZ != trace.blockZ || afterSomeTime % 10 == 0)) {
mLastUpdatedBlockX = trace.blockX;
mLastUpdatedBlockY = trace.blockY;
mLastUpdatedBlockZ = trace.blockZ;
- final TileEntity tileEntity =
- aEvent.player.worldObj.getTileEntity(trace.blockX, trace.blockY, trace.blockZ);
+ final TileEntity tileEntity = aEvent.player.worldObj
+ .getTileEntity(trace.blockX, trace.blockY, trace.blockZ);
if (tileEntity instanceof IGregTechTileEntity) {
final IGregTechTileEntity gtTile = (IGregTechTileEntity) tileEntity;
if (gtTile.getMetaTileEntity() instanceof IHasFluidDisplayItem) {
- GT_Values.NW.sendToServer(new MessageUpdateFluidDisplayItem(
- trace.blockX, trace.blockY, trace.blockZ, gtTile.getWorld().provider.dimensionId));
+ GT_Values.NW.sendToServer(
+ new MessageUpdateFluidDisplayItem(
+ trace.blockX,
+ trace.blockY,
+ trace.blockZ,
+ gtTile.getWorld().provider.dimensionId));
}
}
}
@@ -766,15 +746,15 @@ public class GT_Client extends GT_Proxy implements Runnable {
@SubscribeEvent
public void onDrawBlockHighlight(DrawBlockHighlightEvent aEvent) {
- final Block aBlock =
- aEvent.player.worldObj.getBlock(aEvent.target.blockX, aEvent.target.blockY, aEvent.target.blockZ);
- final TileEntity aTileEntity =
- aEvent.player.worldObj.getTileEntity(aEvent.target.blockX, aEvent.target.blockY, aEvent.target.blockZ);
+ final Block aBlock = aEvent.player.worldObj
+ .getBlock(aEvent.target.blockX, aEvent.target.blockY, aEvent.target.blockZ);
+ final TileEntity aTileEntity = aEvent.player.worldObj
+ .getTileEntity(aEvent.target.blockX, aEvent.target.blockY, aEvent.target.blockZ);
if (GT_Utility.isStackInList(aEvent.currentItem, GregTech_API.sWrenchList)) {
- if (aTileEntity instanceof ITurnable
- || ROTATABLE_VANILLA_BLOCKS.contains(aBlock)
- || aTileEntity instanceof IWrenchable) drawGrid(aEvent, false, true, aEvent.player.isSneaking());
+ if (aTileEntity instanceof ITurnable || ROTATABLE_VANILLA_BLOCKS.contains(aBlock)
+ || aTileEntity instanceof IWrenchable)
+ drawGrid(aEvent, false, true, aEvent.player.isSneaking());
return;
}
@@ -791,11 +771,10 @@ public class GT_Client extends GT_Proxy implements Runnable {
|| GT_Utility.isStackInList(aEvent.currentItem, GregTech_API.sCrowbarList)
|| GT_Utility.isStackInList(aEvent.currentItem, GregTech_API.sScrewdriverList)) {
if (((ICoverable) aTileEntity).getCoverIDAtSide((byte) aEvent.target.sideHit) == 0)
- for (byte tSide : ALL_VALID_SIDES)
- if (((ICoverable) aTileEntity).getCoverIDAtSide(tSide) > 0) {
- drawGrid(aEvent, true, false, true);
- return;
- }
+ for (byte tSide : ALL_VALID_SIDES) if (((ICoverable) aTileEntity).getCoverIDAtSide(tSide) > 0) {
+ drawGrid(aEvent, true, false, true);
+ return;
+ }
return;
}
@@ -938,84 +917,79 @@ public class GT_Client extends GT_Proxy implements Runnable {
if (tString.startsWith(SoundResource.RANDOM_EXPLODE.toString()))
if (aStack.stackSize == 3) tString = SoundResource.RANDOM_FUSE.toString();
else if (aStack.stackSize == 2) tString = "random.old_explode";
- if (tString.startsWith("streaming."))
- switch (aStack.stackSize) {
- case 1: // '\001'
- tString = tString + "13";
- break;
+ if (tString.startsWith("streaming.")) switch (aStack.stackSize) {
+ case 1: // '\001'
+ tString = tString + "13";
+ break;
- case 2: // '\002'
- tString = tString + "cat";
- break;
+ case 2: // '\002'
+ tString = tString + "cat";
+ break;
- case 3: // '\003'
- tString = tString + "blocks";
- break;
+ case 3: // '\003'
+ tString = tString + "blocks";
+ break;
- case 4: // '\004'
- tString = tString + "chirp";
- break;
+ case 4: // '\004'
+ tString = tString + "chirp";
+ break;
- case 5: // '\005'
- tString = tString + "far";
- break;
+ case 5: // '\005'
+ tString = tString + "far";
+ break;
- case 6: // '\006'
- tString = tString + "mall";
- break;
+ case 6: // '\006'
+ tString = tString + "mall";
+ break;
- case 7: // '\007'
- tString = tString + "mellohi";
- break;
+ case 7: // '\007'
+ tString = tString + "mellohi";
+ break;
- case 8: // '\b'
- tString = tString + "stal";
- break;
+ case 8: // '\b'
+ tString = tString + "stal";
+ break;
- case 9: // '\t'
- tString = tString + "strad";
- break;
+ case 9: // '\t'
+ tString = tString + "strad";
+ break;
- case 10: // '\n'
- tString = tString + "ward";
- break;
+ case 10: // '\n'
+ tString = tString + "ward";
+ break;
- case 11: // '\013'
- tString = tString + "11";
- break;
+ case 11: // '\013'
+ tString = tString + "11";
+ break;
- case 12: // '\f'
- tString = tString + "wait";
- break;
+ case 12: // '\f'
+ tString = tString + "wait";
+ break;
- default:
- tString = tString + "wherearewenow";
- break;
- }
+ default:
+ tString = tString + "wherearewenow";
+ break;
+ }
if (tString.startsWith("streaming.")) {
- new WorldSpawnedEventBuilder.RecordEffectEventBuilder()
- .setIdentifier(tString.substring(10))
- .setPosition(aX, aY, aZ)
- .run();
+ new WorldSpawnedEventBuilder.RecordEffectEventBuilder().setIdentifier(tString.substring(10))
+ .setPosition(aX, aY, aZ).run();
} else {
- new WorldSpawnedEventBuilder.SoundEventBuilder()
- .setVolume(3f)
- .setPitch(
- tString.startsWith("note.")
- ? (float) Math.pow(2D, (double) (aStack.stackSize - 13) / 12D)
- : 1.0F)
- .setIdentifier(tString)
- .setPosition(aX, aY, aZ)
- .run();
+ new WorldSpawnedEventBuilder.SoundEventBuilder().setVolume(3f).setPitch(
+ tString.startsWith("note.") ? (float) Math.pow(2D, (double) (aStack.stackSize - 13) / 12D) : 1.0F)
+ .setIdentifier(tString).setPosition(aX, aY, aZ).run();
}
}
public static int hideValue = 0;
/**
- * <p>Client tick counter that is set to 5 on hiding pipes and covers.</p>
- * <p>It triggers a texture update next client tick when reaching 4, with provision for 3 more update tasks,
- * spreading client change detection related work and network traffic on different ticks, until it reaches 0.</p>
+ * <p>
+ * Client tick counter that is set to 5 on hiding pipes and covers.
+ * </p>
+ * <p>
+ * It triggers a texture update next client tick when reaching 4, with provision for 3 more update tasks, spreading
+ * client change detection related work and network traffic on different ticks, until it reaches 0.
+ * </p>
*/
public static int changeDetected = 0;
diff --git a/src/main/java/gregtech/common/GT_DummyWorld.java b/src/main/java/gregtech/common/GT_DummyWorld.java
index cfc89c9df6..321e0688ce 100644
--- a/src/main/java/gregtech/common/GT_DummyWorld.java
+++ b/src/main/java/gregtech/common/GT_DummyWorld.java
@@ -1,6 +1,7 @@
package gregtech.common;
import java.io.File;
+
import net.minecraft.block.Block;
import net.minecraft.entity.Entity;
import net.minecraft.init.Blocks;
@@ -18,68 +19,61 @@ import net.minecraft.world.storage.ISaveHandler;
import net.minecraft.world.storage.WorldInfo;
public class GT_DummyWorld extends World {
+
public GT_IteratorRandom mRandom = new GT_IteratorRandom();
public ItemStack mLastSetBlock = null;
- public GT_DummyWorld(
- ISaveHandler saveHandler,
- String name,
- WorldProvider worldProvider,
- WorldSettings worldSettings,
- Profiler profiler) {
+ public GT_DummyWorld(ISaveHandler saveHandler, String name, WorldProvider worldProvider,
+ WorldSettings worldSettings, Profiler profiler) {
super(saveHandler, name, worldSettings, worldProvider, profiler);
this.rand = this.mRandom;
}
public GT_DummyWorld() {
- this(
- new ISaveHandler() {
- @Override
- public void saveWorldInfoWithPlayer(WorldInfo worldInfo, NBTTagCompound nbtTagCompound) {}
-
- @Override
- public void saveWorldInfo(WorldInfo worldInfo) {}
-
- @Override
- public WorldInfo loadWorldInfo() {
- return null;
- }
-
- @Override
- public IPlayerFileData getSaveHandler() {
- return null;
- }
-
- @Override
- public File getMapFileFromName(String mapName) {
- return null;
- }
-
- @Override
- public IChunkLoader getChunkLoader(WorldProvider worldProvider) {
- return null;
- }
-
- @Override
- public void flush() {}
-
- @Override
- public void checkSessionLock() {}
-
- @Override
- public String getWorldDirectoryName() {
- return null;
- }
-
- @Override
- public File getWorldDirectory() {
- return null;
- }
- },
- "DUMMY_DIMENSION",
- null,
- new WorldSettings(new WorldInfo(new NBTTagCompound())),
- new Profiler());
+ this(new ISaveHandler() {
+
+ @Override
+ public void saveWorldInfoWithPlayer(WorldInfo worldInfo, NBTTagCompound nbtTagCompound) {}
+
+ @Override
+ public void saveWorldInfo(WorldInfo worldInfo) {}
+
+ @Override
+ public WorldInfo loadWorldInfo() {
+ return null;
+ }
+
+ @Override
+ public IPlayerFileData getSaveHandler() {
+ return null;
+ }
+
+ @Override
+ public File getMapFileFromName(String mapName) {
+ return null;
+ }
+
+ @Override
+ public IChunkLoader getChunkLoader(WorldProvider worldProvider) {
+ return null;
+ }
+
+ @Override
+ public void flush() {}
+
+ @Override
+ public void checkSessionLock() {}
+
+ @Override
+ public String getWorldDirectoryName() {
+ return null;
+ }
+
+ @Override
+ public File getWorldDirectory() {
+ return null;
+ }
+ }, "DUMMY_DIMENSION", null, new WorldSettings(new WorldInfo(new NBTTagCompound())), new Profiler());
}
@Override
diff --git a/src/main/java/gregtech/common/GT_IteratorRandom.java b/src/main/java/gregtech/common/GT_IteratorRandom.java
index 1141da4deb..addce0a456 100644
--- a/src/main/java/gregtech/common/GT_IteratorRandom.java
+++ b/src/main/java/gregtech/common/GT_IteratorRandom.java
@@ -3,6 +3,7 @@ package gregtech.common;
import java.util.Random;
public class GT_IteratorRandom extends Random {
+
private static final long serialVersionUID = 1L;
public int mIterationStep = 2147483647;
diff --git a/src/main/java/gregtech/common/GT_Network.java b/src/main/java/gregtech/common/GT_Network.java
index 4e1a58b4db..77a7e3477e 100644
--- a/src/main/java/gregtech/common/GT_Network.java
+++ b/src/main/java/gregtech/common/GT_Network.java
@@ -2,8 +2,17 @@ package gregtech.common;
import static gregtech.GT_Mod.GT_FML_LOGGER;
+import java.util.EnumMap;
+import java.util.List;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.world.World;
+import net.minecraft.world.chunk.Chunk;
+
import com.google.common.io.ByteArrayDataInput;
import com.google.common.io.ByteStreams;
+
import cpw.mods.fml.common.network.FMLEmbeddedChannel;
import cpw.mods.fml.common.network.FMLOutboundHandler;
import cpw.mods.fml.common.network.NetworkRegistry;
@@ -20,16 +29,11 @@ import io.netty.channel.ChannelHandler;
import io.netty.channel.ChannelHandlerContext;
import io.netty.channel.SimpleChannelInboundHandler;
import io.netty.handler.codec.MessageToMessageCodec;
-import java.util.EnumMap;
-import java.util.List;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.world.World;
-import net.minecraft.world.chunk.Chunk;
@ChannelHandler.Sharable
@SuppressWarnings("deprecation")
public class GT_Network extends MessageToMessageCodec<FMLProxyPacket, GT_Packet> implements IGT_NetworkHandler {
+
private final EnumMap<Side, FMLEmbeddedChannel> mChannel;
private final GT_Packet[] mSubChannels;
@@ -55,7 +59,7 @@ public class GT_Network extends MessageToMessageCodec<FMLProxyPacket, GT_Packet>
new GT_Packet_SendCoverData(), // 16
new GT_Packet_RequestCoverData(), // 17
new GT_Packet_MultiTileEntity() // 18
- );
+ );
}
public GT_Network(String channelName, GT_Packet... packetTypes) {
@@ -72,15 +76,13 @@ public class GT_Network extends MessageToMessageCodec<FMLProxyPacket, GT_Packet>
protected void encode(ChannelHandlerContext aContext, GT_Packet aPacket, List<Object> aOutput) throws Exception {
final ByteBuf tBuf = Unpooled.buffer().writeByte(aPacket.getPacketID());
aPacket.encode(tBuf);
- aOutput.add(new FMLProxyPacket(
- tBuf, aContext.channel().attr(NetworkRegistry.FML_CHANNEL).get()));
+ aOutput.add(new FMLProxyPacket(tBuf, aContext.channel().attr(NetworkRegistry.FML_CHANNEL).get()));
}
@Override
protected void decode(ChannelHandlerContext aContext, FMLProxyPacket aPacket, List<Object> aOutput)
throws Exception {
- final ByteArrayDataInput aData =
- ByteStreams.newDataInput(aPacket.payload().array());
+ final ByteArrayDataInput aData = ByteStreams.newDataInput(aPacket.payload().array());
final GT_Packet tPacket = this.mSubChannels[aData.readByte()].decode(aData);
tPacket.setINetHandler(aPacket.handler());
aOutput.add(tPacket);
@@ -96,35 +98,23 @@ public class GT_Network extends MessageToMessageCodec<FMLProxyPacket, GT_Packet>
GT_FML_LOGGER.info("player null");
return;
}
- this.mChannel
- .get(Side.SERVER)
- .attr(FMLOutboundHandler.FML_MESSAGETARGET)
+ this.mChannel.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGET)
.set(FMLOutboundHandler.OutboundTarget.PLAYER);
- this.mChannel
- .get(Side.SERVER)
- .attr(FMLOutboundHandler.FML_MESSAGETARGETARGS)
- .set(aPlayer);
+ this.mChannel.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGETARGS).set(aPlayer);
this.mChannel.get(Side.SERVER).writeAndFlush(aPacket);
}
@Override
public void sendToAllAround(GT_Packet aPacket, NetworkRegistry.TargetPoint aPosition) {
- this.mChannel
- .get(Side.SERVER)
- .attr(FMLOutboundHandler.FML_MESSAGETARGET)
+ this.mChannel.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGET)
.set(FMLOutboundHandler.OutboundTarget.ALLAROUNDPOINT);
- this.mChannel
- .get(Side.SERVER)
- .attr(FMLOutboundHandler.FML_MESSAGETARGETARGS)
- .set(aPosition);
+ this.mChannel.get(Side.SERVER).attr(FMLOutboundHandler.FML_MESSAGETARGETARGS).set(aPosition);
this.mChannel.get(Side.SERVER).writeAndFlush(aPacket);
}
@Override
public void sendToServer(GT_Packet aPacket) {
- this.mChannel
- .get(Side.CLIENT)
- .attr(FMLOutboundHandler.FML_MESSAGETARGET)
+ this.mChannel.get(Side.CLIENT).attr(FMLOutboundHandler.FML_MESSAGETARGET)
.set(FMLOutboundHandler.OutboundTarget.TOSERVER);
this.mChannel.get(Side.CLIENT).writeAndFlush(aPacket);
}
@@ -138,8 +128,7 @@ public class GT_Network extends MessageToMessageCodec<FMLProxyPacket, GT_Packet>
}
EntityPlayerMP tPlayer = (EntityPlayerMP) tObject;
Chunk tChunk = aWorld.getChunkFromBlockCoords(aX, aZ);
- if (tPlayer.getServerForPlayer()
- .getPlayerManager()
+ if (tPlayer.getServerForPlayer().getPlayerManager()
.isPlayerWatchingChunk(tPlayer, tChunk.xPosition, tChunk.zPosition)) {
sendToPlayer(aPacket, tPlayer);
}
@@ -149,6 +138,7 @@ public class GT_Network extends MessageToMessageCodec<FMLProxyPacket, GT_Packet>
@ChannelHandler.Sharable
static final class HandlerShared extends SimpleChannelInboundHandler<GT_Packet> {
+
@Override
protected void channelRead0(ChannelHandlerContext ctx, GT_Packet aPacket) {
final EntityPlayer aPlayer = GT_Values.GT.getThePlayer();
diff --git a/src/main/java/gregtech/common/GT_PlayerActivityLogger.java b/src/main/java/gregtech/common/GT_PlayerActivityLogger.java
index 49ddb9dc23..384a3a8eb4 100644
--- a/src/main/java/gregtech/common/GT_PlayerActivityLogger.java
+++ b/src/main/java/gregtech/common/GT_PlayerActivityLogger.java
@@ -1,14 +1,16 @@
package gregtech.common;
+import java.util.ArrayList;
+
import gregtech.GT_Mod;
import gregtech.api.util.GT_Log;
-import java.util.ArrayList;
public class GT_PlayerActivityLogger implements Runnable {
+
@Override
public void run() {
try {
- for (; ; ) {
+ for (;;) {
if (GT_Log.pal == null) {
return;
}
@@ -24,7 +26,6 @@ public class GT_PlayerActivityLogger implements Runnable {
}
Thread.sleep(10000L);
}
- } catch (Throwable e) {
- }
+ } catch (Throwable e) {}
}
}
diff --git a/src/main/java/gregtech/common/GT_Pollution.java b/src/main/java/gregtech/common/GT_Pollution.java
index 4d726a2a46..12ea4650e9 100644
--- a/src/main/java/gregtech/common/GT_Pollution.java
+++ b/src/main/java/gregtech/common/GT_Pollution.java
@@ -3,19 +3,6 @@ package gregtech.common;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
import static gregtech.common.GT_Proxy.dimensionWisePollution;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.gameevent.TickEvent;
-import cpw.mods.fml.common.network.NetworkRegistry;
-import gregtech.GT_Mod;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.interfaces.metatileentity.IMachineCallback;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.net.GT_Packet_Pollution;
-import gregtech.api.util.GT_ChunkAssociatedData;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.render.GT_PollutionRenderer;
-import gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_Cleanroom;
import java.io.DataInput;
import java.io.DataOutput;
import java.io.IOException;
@@ -24,8 +11,10 @@ import java.util.HashSet;
import java.util.List;
import java.util.Set;
import java.util.function.Consumer;
+
import javax.annotation.Nullable;
import javax.annotation.ParametersAreNonnullByDefault;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -44,45 +33,46 @@ import net.minecraftforge.event.world.ChunkDataEvent;
import net.minecraftforge.event.world.ChunkWatchEvent;
import net.minecraftforge.event.world.WorldEvent;
+import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+import cpw.mods.fml.common.gameevent.TickEvent;
+import cpw.mods.fml.common.network.NetworkRegistry;
+import gregtech.GT_Mod;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.interfaces.metatileentity.IMachineCallback;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.net.GT_Packet_Pollution;
+import gregtech.api.util.GT_ChunkAssociatedData;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.render.GT_PollutionRenderer;
+import gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_Cleanroom;
+
public class GT_Pollution {
+
private static final Storage STORAGE = new Storage();
/**
- * Pollution dispersion until effects start:
- * Calculation: ((Limit * 0.01) + 2000) * (4 <- spreading rate)
+ * Pollution dispersion until effects start: Calculation: ((Limit * 0.01) + 2000) * (4 <- spreading rate)
* <p>
- * SMOG(500k) 466.7 pollution/sec
- * Poison(750k) 633,3 pollution/sec
- * Dying Plants(1mio) 800 pollution/sec
- * Sour Rain(1.5mio) 1133.3 pollution/sec
+ * SMOG(500k) 466.7 pollution/sec Poison(750k) 633,3 pollution/sec Dying Plants(1mio) 800 pollution/sec Sour
+ * Rain(1.5mio) 1133.3 pollution/sec
* <p>
- * Pollution producers (pollution/sec)
- * Bronze Boiler(20)
- * Lava Boiler(20)
- * High Pressure Boiler(20)
- * Bronze Blast Furnace(50)
- * Diesel Generator(40/80/160)
- * Gas Turbine(20/40/80)
- * Charcoal Pile(100)
+ * Pollution producers (pollution/sec) Bronze Boiler(20) Lava Boiler(20) High Pressure Boiler(20) Bronze Blast
+ * Furnace(50) Diesel Generator(40/80/160) Gas Turbine(20/40/80) Charcoal Pile(100)
* <p>
- * Large Diesel Engine(320)
- * Electric Blast Furnace(100)
- * Implosion Compressor(2000)
- * Large Boiler(240)
- * Large Gas Turbine(160)
- * Multi Smelter(100)
- * Pyrolyse Oven(400)
+ * Large Diesel Engine(320) Electric Blast Furnace(100) Implosion Compressor(2000) Large Boiler(240) Large Gas
+ * Turbine(160) Multi Smelter(100) Pyrolyse Oven(400)
* <p>
* Machine Explosion(100,000)
* <p>
* Other Random Shit: lots and lots
* <p>
- * Muffler Hatch Pollution reduction: ** inaccurate **
- * LV (0%), MV (30%), HV (52%), EV (66%), IV (76%), LuV (84%), ZPM (89%), UV (92%), MAX (95%)
+ * Muffler Hatch Pollution reduction: ** inaccurate ** LV (0%), MV (30%), HV (52%), EV (66%), IV (76%), LuV (84%),
+ * ZPM (89%), UV (92%), MAX (95%)
*/
private List<ChunkCoordIntPair> pollutionList = new ArrayList<>(); // chunks left to process in this cycle
- private final Set<ChunkCoordIntPair> pollutedChunks =
- new HashSet<>(); // a global list of all chunks with positive pollution
+ private final Set<ChunkCoordIntPair> pollutedChunks = new HashSet<>(); // a global list of all chunks with positive
+ // pollution
private int operationsPerTick = 0; // how much chunks should be processed in each cycle
private static final short cycleLen = 1200;
private final World world;
@@ -167,25 +157,28 @@ public class GT_Pollution {
if (!(GT_Utility.isWearingFullGasHazmat(tEnt))) {
switch (XSTR_INSTANCE.nextInt(3)) {
default:
- tEnt.addPotionEffect(new PotionEffect(
- Potion.digSlowdown.id,
- Math.min(tPollution / 1000, 1000),
- tPollution / 400000));
+ tEnt.addPotionEffect(
+ new PotionEffect(
+ Potion.digSlowdown.id,
+ Math.min(tPollution / 1000, 1000),
+ tPollution / 400000));
case 1:
- tEnt.addPotionEffect(new PotionEffect(
- Potion.weakness.id,
- Math.min(tPollution / 1000, 1000),
- tPollution / 400000));
+ tEnt.addPotionEffect(
+ new PotionEffect(
+ Potion.weakness.id,
+ Math.min(tPollution / 1000, 1000),
+ tPollution / 400000));
case 2:
- tEnt.addPotionEffect(new PotionEffect(
- Potion.moveSlowdown.id,
- Math.min(tPollution / 1000, 1000),
- tPollution / 400000));
+ tEnt.addPotionEffect(
+ new PotionEffect(
+ Potion.moveSlowdown.id,
+ Math.min(tPollution / 1000, 1000),
+ tPollution / 400000));
}
}
}
- // Poison effects
+ // Poison effects
if (tPollution > GT_Mod.gregtechproxy.mPollutionPoisonLimit) {
// AxisAlignedBB chunk = AxisAlignedBB.getBoundingBox(tPos.chunkPosX*16, 0, tPos.chunkPosZ*16,
// tPos.chunkPosX*16+16, 256, tPos.chunkPosZ*16+16);
@@ -198,21 +191,28 @@ public class GT_Pollution {
default:
tEnt.addPotionEffect(new PotionEffect(Potion.hunger.id, tPollution / 500000));
case 1:
- tEnt.addPotionEffect(new PotionEffect(
- Potion.confusion.id, Math.min(tPollution / 2000, 1000), 1));
+ tEnt.addPotionEffect(
+ new PotionEffect(
+ Potion.confusion.id,
+ Math.min(tPollution / 2000, 1000),
+ 1));
case 2:
- tEnt.addPotionEffect(new PotionEffect(
- Potion.poison.id,
- Math.min(tPollution / 4000, 1000),
- tPollution / 500000));
+ tEnt.addPotionEffect(
+ new PotionEffect(
+ Potion.poison.id,
+ Math.min(tPollution / 4000, 1000),
+ tPollution / 500000));
case 3:
- tEnt.addPotionEffect(new PotionEffect(
- Potion.blindness.id, Math.min(tPollution / 2000, 1000), 1));
+ tEnt.addPotionEffect(
+ new PotionEffect(
+ Potion.blindness.id,
+ Math.min(tPollution / 2000, 1000),
+ 1));
}
}
}
- // killing plants
+ // killing plants
if (tPollution > GT_Mod.gregtechproxy.mPollutionVegetationLimit) {
int f = 20;
for (; f < (tPollution / 25000); f++) {
@@ -231,7 +231,11 @@ public class GT_Pollution {
// Send new value to players nearby
if (tPollution > POLLUTIONPACKET_MINVALUE) {
NetworkRegistry.TargetPoint point = new NetworkRegistry.TargetPoint(
- world.provider.dimensionId, (actualPos.chunkXPos << 4), 64, (actualPos.chunkZPos << 4), 256);
+ world.provider.dimensionId,
+ (actualPos.chunkXPos << 4),
+ 64,
+ (actualPos.chunkZPos << 4),
+ 256);
GT_Values.NW.sendToAllAround(new GT_Packet_Pollution(actualPos, tPollution), point);
}
}
@@ -259,8 +263,7 @@ public class GT_Pollution {
tBlock.dropBlockAsItem(world, x, y, z, tMeta, 0);
world.setBlockToAir(x, y, z);
}
- if (tBlock == Blocks.waterlily
- || tBlock == Blocks.wheat
+ if (tBlock == Blocks.waterlily || tBlock == Blocks.wheat
|| tBlock == Blocks.cactus
|| tBlock.getMaterial() == Material.cactus
|| tBlock == Blocks.melon_block
@@ -268,8 +271,7 @@ public class GT_Pollution {
tBlock.dropBlockAsItem(world, x, y, z, tMeta, 0);
world.setBlockToAir(x, y, z);
}
- if (tBlock == Blocks.red_flower
- || tBlock == Blocks.yellow_flower
+ if (tBlock == Blocks.red_flower || tBlock == Blocks.yellow_flower
|| tBlock == Blocks.carrots
|| tBlock == Blocks.potatoes
|| tBlock == Blocks.pumpkin
@@ -289,8 +291,7 @@ public class GT_Pollution {
world.setBlock(x, y, z, Blocks.sand);
}
- if (sourRain
- && world.isRaining()
+ if (sourRain && world.isRaining()
&& (tBlock == Blocks.stone || tBlock == Blocks.gravel || tBlock == Blocks.cobblestone)
&& world.getBlock(x, y + 1, z) == Blocks.air
&& world.canBlockSeeTheSky(x, y, z)) {
@@ -333,12 +334,12 @@ public class GT_Pollution {
}
/**
- * Add some pollution to given chunk. Can pass in negative to remove pollution.
- * Will clamp the final pollution number to 0 if it would be changed into negative.
+ * Add some pollution to given chunk. Can pass in negative to remove pollution. Will clamp the final pollution
+ * number to 0 if it would be changed into negative.
*
- * @param w world to modify. do nothing if it's a client world
- * @param chunkX chunk coordinate X, i.e. blockX >> 4
- * @param chunkZ chunk coordinate Z, i.e. blockZ >> 4
+ * @param w world to modify. do nothing if it's a client world
+ * @param chunkX chunk coordinate X, i.e. blockX >> 4
+ * @param chunkZ chunk coordinate Z, i.e. blockZ >> 4
* @param aPollution desired delta. Positive means the pollution in chunk would go higher.
*/
public static void addPollution(World w, int chunkX, int chunkZ, int aPollution) {
@@ -346,8 +347,8 @@ public class GT_Pollution {
mutatePollution(w, chunkX, chunkZ, d -> d.changeAmount(aPollution), null);
}
- private static void mutatePollution(
- World world, int x, int z, Consumer<ChunkData> mutator, @Nullable Set<ChunkCoordIntPair> chunks) {
+ private static void mutatePollution(World world, int x, int z, Consumer<ChunkData> mutator,
+ @Nullable Set<ChunkCoordIntPair> chunks) {
ChunkData data = STORAGE.get(world, x, z);
boolean hadPollution = data.getAmount() > 0;
mutator.accept(data);
@@ -359,23 +360,24 @@ public class GT_Pollution {
}
}
- /** @see #getPollution(World, int, int) */
+ /** @see #getPollution(World, int, int) */
public static int getPollution(IGregTechTileEntity te) {
return getPollution(te.getWorld(), te.getXCoord() >> 4, te.getZCoord() >> 4);
}
- /** @see #getPollution(World, int, int) */
+ /** @see #getPollution(World, int, int) */
public static int getPollution(Chunk ch) {
return getPollution(ch.worldObj, ch.xPosition, ch.zPosition);
}
/**
* Get the pollution in specified chunk
- * @param w world to look in. can be a client world, but that limits the knowledge to what server side send us
+ *
+ * @param w world to look in. can be a client world, but that limits the knowledge to what server side send us
* @param chunkX chunk coordinate X, i.e. blockX >> 4
* @param chunkZ chunk coordinate Z, i.e. blockZ >> 4
- * @return pollution amount. may be 0 if pollution is disabled, or if it's a client world and server did not send
- * us info about this chunk
+ * @return pollution amount. may be 0 if pollution is disabled, or if it's a client world and server did not send us
+ * info about this chunk
*/
public static int getPollution(World w, int chunkX, int chunkZ) {
if (!GT_Mod.gregtechproxy.mPollution) return 0;
@@ -392,12 +394,11 @@ public class GT_Pollution {
public static boolean hasPollution(Chunk ch) {
if (!GT_Mod.gregtechproxy.mPollution) return false;
- return STORAGE.isCreated(ch.worldObj, ch.getChunkCoordIntPair())
- && STORAGE.get(ch).getAmount() > 0;
+ return STORAGE.isCreated(ch.worldObj, ch.getChunkCoordIntPair()) && STORAGE.get(ch).getAmount() > 0;
}
// Add compatibility with old code
- @Deprecated /*Don't use it... too weird way of passing position*/
+ @Deprecated /* Don't use it... too weird way of passing position */
public static void addPollution(World aWorld, ChunkPosition aPos, int aPollution) {
// The abuse of ChunkPosition to store block position and dim...
// is just bad especially when that is both used to store ChunkPos and BlockPos depending on context
@@ -409,6 +410,7 @@ public class GT_Pollution {
}
public static class GT_PollutionEventHandler {
+
@SubscribeEvent
public void chunkWatch(ChunkWatchEvent.Watch event) {
if (!GT_Mod.gregtechproxy.mPollution) return;
@@ -429,6 +431,7 @@ public class GT_Pollution {
@ParametersAreNonnullByDefault
private static final class Storage extends GT_ChunkAssociatedData<ChunkData> {
+
private Storage() {
super("Pollution", ChunkData.class, 64, (byte) 0, false);
}
@@ -465,6 +468,7 @@ public class GT_Pollution {
}
private static final class ChunkData implements GT_ChunkAssociatedData.IData {
+
public int amount;
private ChunkData() {
diff --git a/src/main/java/gregtech/common/GT_Proxy.java b/src/main/java/gregtech/common/GT_Proxy.java
index 62bc9f7654..ccc04f171e 100644
--- a/src/main/java/gregtech/common/GT_Proxy.java
+++ b/src/main/java/gregtech/common/GT_Proxy.java
@@ -14,65 +14,6 @@ import static gregtech.api.enums.GT_Values.W;
import static gregtech.api.enums.GT_Values.debugEntityCramming;
import static gregtech.api.util.GT_Util.LAST_BROKEN_TILEENTITY;
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.IFuelHandler;
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.common.ModContainer;
-import cpw.mods.fml.common.ProgressManager;
-import cpw.mods.fml.common.eventhandler.Event.Result;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.gameevent.TickEvent;
-import cpw.mods.fml.common.network.FMLNetworkEvent;
-import cpw.mods.fml.common.network.IGuiHandler;
-import cpw.mods.fml.common.network.NetworkRegistry;
-import cpw.mods.fml.common.registry.GameRegistry;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.ConfigCategories;
-import gregtech.api.enums.Dyes;
-import gregtech.api.enums.FluidState;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OreDictNames;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.SubTag;
-import gregtech.api.enums.TC_Aspects.TC_AspectStack;
-import gregtech.api.enums.ToolDictNames;
-import gregtech.api.fluid.GT_FluidFactory;
-import gregtech.api.interfaces.IBlockOnWalkOver;
-import gregtech.api.interfaces.IGlobalWirelessEnergy;
-import gregtech.api.interfaces.IProjectileItem;
-import gregtech.api.interfaces.internal.IGT_Mod;
-import gregtech.api.interfaces.internal.IThaumcraftCompat;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.objects.GT_ChunkManager;
-import gregtech.api.objects.GT_FluidStack;
-import gregtech.api.objects.GT_ItemStack;
-import gregtech.api.objects.GT_UO_DimensionList;
-import gregtech.api.objects.ItemData;
-import gregtech.api.util.GT_BlockMap;
-import gregtech.api.util.GT_CLS_Compat;
-import gregtech.api.util.GT_ChunkAssociatedData;
-import gregtech.api.util.GT_ClientPreference;
-import gregtech.api.util.GT_CoverBehaviorBase;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_OreDictUnificator;
-import gregtech.api.util.GT_Recipe;
-import gregtech.api.util.GT_RecipeRegistrator;
-import gregtech.api.util.GT_Shaped_Recipe;
-import gregtech.api.util.GT_Shapeless_Recipe;
-import gregtech.api.util.GT_Utility;
-import gregtech.api.util.WorldSpawnedEventBuilder;
-import gregtech.common.entities.GT_Entity_Arrow;
-import gregtech.common.items.GT_MetaGenerated_Item_98;
-import gregtech.common.items.GT_MetaGenerated_Tool_01;
-import gregtech.common.misc.GlobalEnergyWorldSavedData;
import java.io.File;
import java.lang.reflect.InvocationTargetException;
import java.text.DateFormat;
@@ -92,6 +33,7 @@ import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
import java.util.concurrent.locks.ReentrantLock;
import java.util.stream.Collectors;
+
import net.minecraft.block.Block;
import net.minecraft.enchantment.Enchantment;
import net.minecraft.enchantment.EnchantmentHelper;
@@ -140,7 +82,68 @@ import net.minecraftforge.oredict.RecipeSorter;
import net.minecraftforge.oredict.ShapedOreRecipe;
import net.minecraftforge.oredict.ShapelessOreRecipe;
+import cpw.mods.fml.common.FMLCommonHandler;
+import cpw.mods.fml.common.IFuelHandler;
+import cpw.mods.fml.common.Loader;
+import cpw.mods.fml.common.ModContainer;
+import cpw.mods.fml.common.ProgressManager;
+import cpw.mods.fml.common.eventhandler.Event.Result;
+import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+import cpw.mods.fml.common.gameevent.TickEvent;
+import cpw.mods.fml.common.network.FMLNetworkEvent;
+import cpw.mods.fml.common.network.IGuiHandler;
+import cpw.mods.fml.common.network.NetworkRegistry;
+import cpw.mods.fml.common.registry.GameRegistry;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.ConfigCategories;
+import gregtech.api.enums.Dyes;
+import gregtech.api.enums.FluidState;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OreDictNames;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.SubTag;
+import gregtech.api.enums.TC_Aspects.TC_AspectStack;
+import gregtech.api.enums.ToolDictNames;
+import gregtech.api.fluid.GT_FluidFactory;
+import gregtech.api.interfaces.IBlockOnWalkOver;
+import gregtech.api.interfaces.IGlobalWirelessEnergy;
+import gregtech.api.interfaces.IProjectileItem;
+import gregtech.api.interfaces.internal.IGT_Mod;
+import gregtech.api.interfaces.internal.IThaumcraftCompat;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.objects.GT_ChunkManager;
+import gregtech.api.objects.GT_FluidStack;
+import gregtech.api.objects.GT_ItemStack;
+import gregtech.api.objects.GT_UO_DimensionList;
+import gregtech.api.objects.ItemData;
+import gregtech.api.util.GT_BlockMap;
+import gregtech.api.util.GT_CLS_Compat;
+import gregtech.api.util.GT_ChunkAssociatedData;
+import gregtech.api.util.GT_ClientPreference;
+import gregtech.api.util.GT_CoverBehaviorBase;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.api.util.GT_Recipe;
+import gregtech.api.util.GT_RecipeRegistrator;
+import gregtech.api.util.GT_Shaped_Recipe;
+import gregtech.api.util.GT_Shapeless_Recipe;
+import gregtech.api.util.GT_Utility;
+import gregtech.api.util.WorldSpawnedEventBuilder;
+import gregtech.common.entities.GT_Entity_Arrow;
+import gregtech.common.items.GT_MetaGenerated_Item_98;
+import gregtech.common.items.GT_MetaGenerated_Tool_01;
+import gregtech.common.misc.GlobalEnergyWorldSavedData;
+
public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IGlobalWirelessEnergy {
+
private static final EnumSet<OreGenEvent.GenerateMinable.EventType> PREVENTED_ORES = EnumSet.of(
OreGenEvent.GenerateMinable.EventType.COAL,
OreGenEvent.GenerateMinable.EventType.IRON,
@@ -154,344 +157,347 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
public final ArrayList<ItemStack> mSoundItems = new ArrayList<>();
public final ArrayList<Integer> mSoundCounts = new ArrayList<>();
private final Collection<OreDictEventContainer> mEvents = new HashSet<>();
- private final Collection<String> mIgnoredItems = new HashSet<>(Arrays.asList(
- "itemGhastTear",
- "itemFlint",
- "itemClay",
- "itemBucketSaltWater",
- "itemBucketFreshWater",
- "itemBucketWater",
- "itemRock",
- "itemReed",
- "itemArrow",
- "itemSaw",
- "itemKnife",
- "itemHammer",
- "itemChisel",
- "itemRubber",
- "itemEssence",
- "itemIlluminatedPanel",
- "itemSkull",
- "itemRawRubber",
- "itemBacon",
- "itemJetpackAccelerator",
- "itemLazurite",
- "itemIridium",
- "itemTear",
- "itemClaw",
- "itemFertilizer",
- "itemTar",
- "itemSlimeball",
- "itemCoke",
- "itemBeeswax",
- "itemBeeQueen",
- "itemForcicium",
- "itemForcillium",
- "itemRoyalJelly",
- "itemHoneydew",
- "itemHoney",
- "itemPollen",
- "itemReedTypha",
- "itemSulfuricAcid",
- "itemPotash",
- "itemCompressedCarbon",
- "itemBitumen",
- "itemBioFuel",
- "itemCokeSugar",
- "itemCokeCactus",
- "itemCharcoalSugar",
- "itemCharcoalCactus",
- "itemSludge",
- "itemEnrichedAlloy",
- "itemQuicksilver",
- "itemMercury",
- "itemOsmium",
- "itemUltimateCircuit",
- "itemEnergizedStar",
- "itemAntimatterMolecule",
- "itemAntimatterGlob",
- "itemCoal",
- "itemBoat",
- "itemHerbalMedicineCake",
- "itemCakeSponge",
- "itemFishandPumpkinCakeSponge",
- "itemSoulCleaver",
- "itemInstantCake",
- "itemWhippingCream",
- "itemGlisteningWhippingCream",
- "itemCleaver",
- "itemHerbalMedicineWhippingCream",
- "itemStrangeWhippingCream",
- "itemBlazeCleaver",
- "itemBakedCakeSponge",
- "itemMagmaCake",
- "itemGlisteningCake",
- "itemOgreCleaver",
- "itemFishandPumpkinCake",
- "itemMagmaWhippingCream",
- "itemMultimeter",
- "itemSuperconductor"));
- private final Collection<String> mIgnoredNames = new HashSet<>(Arrays.asList(
- "grubBee",
- "chainLink",
- "candyCane",
- "bRedString",
- "bVial",
- "bFlask",
- "anorthositeSmooth",
- "migmatiteSmooth",
- "slateSmooth",
- "travertineSmooth",
- "limestoneSmooth",
- "orthogneissSmooth",
- "marbleSmooth",
- "honeyDrop",
- "lumpClay",
- "honeyEqualssugar",
- "flourEqualswheat",
- "bluestoneInsulated",
- "blockWaterstone",
- "blockSand",
- "blockTorch",
- "blockPumpkin",
- "blockClothRock",
- "blockStainedHardenedClay",
- "blockQuartzPillar",
- "blockQuartzChiselled",
- "blockSpawner",
- "blockCloth",
- "mobHead",
- "mobEgg",
- "enderFlower",
- "enderChest",
- "clayHardened",
- "dayGemMaterial",
- "nightGemMaterial",
- "snowLayer",
- "bPlaceholder",
- "hardenedClay",
- "eternalLifeEssence",
- "sandstone",
- "wheatRice",
- "transdimBlock",
- "bambooBasket",
- "lexicaBotania",
- "livingwoodTwig",
- "redstoneCrystal",
- "pestleAndMortar",
- "glowstone",
- "whiteStone",
- "stoneSlab",
- "transdimBlock",
- "clayBowl",
- "clayPlate",
- "ceramicBowl",
- "ceramicPlate",
- "ovenRack",
- "clayCup",
- "ceramicCup",
- "batteryBox",
- "transmutationStone",
- "torchRedstoneActive",
- "coal",
- "charcoal",
- "cloth",
- "cobblestoneSlab",
- "stoneBrickSlab",
- "cobblestoneWall",
- "stoneBrickWall",
- "cobblestoneStair",
- "stoneBrickStair",
- "blockCloud",
- "blockDirt",
- "blockTyrian",
- "blockCarpet",
- "blockFft",
- "blockLavastone",
- "blockHolystone",
- "blockConcrete",
- "sunnariumPart",
- "brSmallMachineCyaniteProcessor",
- "meteoriteCoal",
- "blockCobble",
- "pressOreProcessor",
- "crusherOreProcessor",
- "grinderOreProcessor",
- "blockRubber",
- "blockHoney",
- "blockHoneydew",
- "blockPeat",
- "blockRadioactive",
- "blockSlime",
- "blockCocoa",
- "blockSugarCane",
- "blockLeather",
- "blockClayBrick",
- "solarPanelHV",
- "cableRedNet",
- "stoneBowl",
- "crafterWood",
- "taintedSoil",
- "brickXyEngineering",
- "breederUranium",
- "wireMill",
- "chunkLazurite",
- "aluminumNatural",
- "aluminiumNatural",
- "naturalAluminum",
- "naturalAluminium",
- "antimatterMilligram",
- "antimatterGram",
- "strangeMatter",
- "coalGenerator",
- "electricFurnace",
- "unfinishedTank",
- "valvePart",
- "aquaRegia",
- "leatherSeal",
- "leatherSlimeSeal",
- "hambone",
- "slimeball",
- "clay",
- "enrichedUranium",
- "camoPaste",
- "antiBlock",
- "burntQuartz",
- "salmonRaw",
- "blockHopper",
- "blockEnderObsidian",
- "blockIcestone",
- "blockMagicWood",
- "blockEnderCore",
- "blockHeeEndium",
- "oreHeeEndPowder",
- "oreHeeStardust",
- "oreHeeIgneousRock",
- "oreHeeInstabilityOrb",
- "crystalPureFluix",
- "shardNether",
- "gemFluorite",
- "stickObsidian",
- "caveCrystal",
- "shardCrystal",
- "dyeCrystal",
- "shardFire",
- "shardWater",
- "shardAir",
- "shardEarth",
- "ingotRefinedIron",
- "blockMarble",
- "ingotUnstable"));
- private final Collection<String> mInvalidNames = new HashSet<>(Arrays.asList(
- "diamondShard",
- "redstoneRoot",
- "obsidianStick",
- "bloodstoneOre",
- "universalCable",
- "bronzeTube",
- "ironTube",
- "netherTube",
- "obbyTube",
- "infiniteBattery",
- "eliteBattery",
- "advancedBattery",
- "10kEUStore",
- "blueDye",
- "MonazitOre",
- "quartzCrystal",
- "whiteLuminiteCrystal",
- "darkStoneIngot",
- "invisiumIngot",
- "demoniteOrb",
- "enderGem",
- "starconiumGem",
- "osmoniumIngot",
- "tapaziteGem",
- "zectiumIngot",
- "foolsRubyGem",
- "rubyGem",
- "meteoriteGem",
- "adamiteShard",
- "sapphireGem",
- "copperIngot",
- "ironStick",
- "goldStick",
- "diamondStick",
- "reinforcedStick",
- "draconicStick",
- "emeraldStick",
- "copperStick",
- "tinStick",
- "silverStick",
- "bronzeStick",
- "steelStick",
- "leadStick",
- "manyullynStick",
- "arditeStick",
- "cobaltStick",
- "aluminiumStick",
- "alumiteStick",
- "oilsandsOre",
- "copperWire",
- "superconductorWire",
- "sulfuricAcid",
- "conveyorBelt",
- "ironWire",
- "aluminumWire",
- "aluminiumWire",
- "silverWire",
- "tinWire",
- "dustSiliconSmall",
- "AluminumOre",
- "plateHeavyT2",
- "blockWool",
- "alloyPlateEnergizedHardened",
- "gasWood",
- "alloyPlateEnergized",
- "SilverOre",
- "LeadOre",
- "TinOre",
- "CopperOre",
- "silverOre",
- "leadOre",
- "tinOre",
- "copperOre",
- "bauxiteOre",
- "HSLivingmetalIngot",
- "oilMoving",
- "oilStill",
- "oilBucket",
- "petroleumOre",
- "dieselFuel",
- "diamondNugget",
- "planks",
- "wood",
- "stick",
- "sticks",
- "naquadah",
- "obsidianRod",
- "stoneRod",
- "thaumiumRod",
- "steelRod",
- "netherrackRod",
- "woodRod",
- "ironRod",
- "cactusRod",
- "flintRod",
- "copperRod",
- "cobaltRod",
- "alumiteRod",
- "blueslimeRod",
- "arditeRod",
- "manyullynRod",
- "bronzeRod",
- "boneRod",
- "slimeRod",
- "redalloyBundled",
- "bluestoneBundled",
- "infusedteslatiteInsulated",
- "redalloyInsulated",
- "infusedteslatiteBundled"));
+ private final Collection<String> mIgnoredItems = new HashSet<>(
+ Arrays.asList(
+ "itemGhastTear",
+ "itemFlint",
+ "itemClay",
+ "itemBucketSaltWater",
+ "itemBucketFreshWater",
+ "itemBucketWater",
+ "itemRock",
+ "itemReed",
+ "itemArrow",
+ "itemSaw",
+ "itemKnife",
+ "itemHammer",
+ "itemChisel",
+ "itemRubber",
+ "itemEssence",
+ "itemIlluminatedPanel",
+ "itemSkull",
+ "itemRawRubber",
+ "itemBacon",
+ "itemJetpackAccelerator",
+ "itemLazurite",
+ "itemIridium",
+ "itemTear",
+ "itemClaw",
+ "itemFertilizer",
+ "itemTar",
+ "itemSlimeball",
+ "itemCoke",
+ "itemBeeswax",
+ "itemBeeQueen",
+ "itemForcicium",
+ "itemForcillium",
+ "itemRoyalJelly",
+ "itemHoneydew",
+ "itemHoney",
+ "itemPollen",
+ "itemReedTypha",
+ "itemSulfuricAcid",
+ "itemPotash",
+ "itemCompressedCarbon",
+ "itemBitumen",
+ "itemBioFuel",
+ "itemCokeSugar",
+ "itemCokeCactus",
+ "itemCharcoalSugar",
+ "itemCharcoalCactus",
+ "itemSludge",
+ "itemEnrichedAlloy",
+ "itemQuicksilver",
+ "itemMercury",
+ "itemOsmium",
+ "itemUltimateCircuit",
+ "itemEnergizedStar",
+ "itemAntimatterMolecule",
+ "itemAntimatterGlob",
+ "itemCoal",
+ "itemBoat",
+ "itemHerbalMedicineCake",
+ "itemCakeSponge",
+ "itemFishandPumpkinCakeSponge",
+ "itemSoulCleaver",
+ "itemInstantCake",
+ "itemWhippingCream",
+ "itemGlisteningWhippingCream",
+ "itemCleaver",
+ "itemHerbalMedicineWhippingCream",
+ "itemStrangeWhippingCream",
+ "itemBlazeCleaver",
+ "itemBakedCakeSponge",
+ "itemMagmaCake",
+ "itemGlisteningCake",
+ "itemOgreCleaver",
+ "itemFishandPumpkinCake",
+ "itemMagmaWhippingCream",
+ "itemMultimeter",
+ "itemSuperconductor"));
+ private final Collection<String> mIgnoredNames = new HashSet<>(
+ Arrays.asList(
+ "grubBee",
+ "chainLink",
+ "candyCane",
+ "bRedString",
+ "bVial",
+ "bFlask",
+ "anorthositeSmooth",
+ "migmatiteSmooth",
+ "slateSmooth",
+ "travertineSmooth",
+ "limestoneSmooth",
+ "orthogneissSmooth",
+ "marbleSmooth",
+ "honeyDrop",
+ "lumpClay",
+ "honeyEqualssugar",
+ "flourEqualswheat",
+ "bluestoneInsulated",
+ "blockWaterstone",
+ "blockSand",
+ "blockTorch",
+ "blockPumpkin",
+ "blockClothRock",
+ "blockStainedHardenedClay",
+ "blockQuartzPillar",
+ "blockQuartzChiselled",
+ "blockSpawner",
+ "blockCloth",
+ "mobHead",
+ "mobEgg",
+ "enderFlower",
+ "enderChest",
+ "clayHardened",
+ "dayGemMaterial",
+ "nightGemMaterial",
+ "snowLayer",
+ "bPlaceholder",
+ "hardenedClay",
+ "eternalLifeEssence",
+ "sandstone",
+ "wheatRice",
+ "transdimBlock",
+ "bambooBasket",
+ "lexicaBotania",
+ "livingwoodTwig",
+ "redstoneCrystal",
+ "pestleAndMortar",
+ "glowstone",
+ "whiteStone",
+ "stoneSlab",
+ "transdimBlock",
+ "clayBowl",
+ "clayPlate",
+ "ceramicBowl",
+ "ceramicPlate",
+ "ovenRack",
+ "clayCup",
+ "ceramicCup",
+ "batteryBox",
+ "transmutationStone",
+ "torchRedstoneActive",
+ "coal",
+ "charcoal",
+ "cloth",
+ "cobblestoneSlab",
+ "stoneBrickSlab",
+ "cobblestoneWall",
+ "stoneBrickWall",
+ "cobblestoneStair",
+ "stoneBrickStair",
+ "blockCloud",
+ "blockDirt",
+ "blockTyrian",
+ "blockCarpet",
+ "blockFft",
+ "blockLavastone",
+ "blockHolystone",
+ "blockConcrete",
+ "sunnariumPart",
+ "brSmallMachineCyaniteProcessor",
+ "meteoriteCoal",
+ "blockCobble",
+ "pressOreProcessor",
+ "crusherOreProcessor",
+ "grinderOreProcessor",
+ "blockRubber",
+ "blockHoney",
+ "blockHoneydew",
+ "blockPeat",
+ "blockRadioactive",
+ "blockSlime",
+ "blockCocoa",
+ "blockSugarCane",
+ "blockLeather",
+ "blockClayBrick",
+ "solarPanelHV",
+ "cableRedNet",
+ "stoneBowl",
+ "crafterWood",
+ "taintedSoil",
+ "brickXyEngineering",
+ "breederUranium",
+ "wireMill",
+ "chunkLazurite",
+ "aluminumNatural",
+ "aluminiumNatural",
+ "naturalAluminum",
+ "naturalAluminium",
+ "antimatterMilligram",
+ "antimatterGram",
+ "strangeMatter",
+ "coalGenerator",
+ "electricFurnace",
+ "unfinishedTank",
+ "valvePart",
+ "aquaRegia",
+ "leatherSeal",
+ "leatherSlimeSeal",
+ "hambone",
+ "slimeball",
+ "clay",
+ "enrichedUranium",
+ "camoPaste",
+ "antiBlock",
+ "burntQuartz",
+ "salmonRaw",
+ "blockHopper",
+ "blockEnderObsidian",
+ "blockIcestone",
+ "blockMagicWood",
+ "blockEnderCore",
+ "blockHeeEndium",
+ "oreHeeEndPowder",
+ "oreHeeStardust",
+ "oreHeeIgneousRock",
+ "oreHeeInstabilityOrb",
+ "crystalPureFluix",
+ "shardNether",
+ "gemFluorite",
+ "stickObsidian",
+ "caveCrystal",
+ "shardCrystal",
+ "dyeCrystal",
+ "shardFire",
+ "shardWater",
+ "shardAir",
+ "shardEarth",
+ "ingotRefinedIron",
+ "blockMarble",
+ "ingotUnstable"));
+ private final Collection<String> mInvalidNames = new HashSet<>(
+ Arrays.asList(
+ "diamondShard",
+ "redstoneRoot",
+ "obsidianStick",
+ "bloodstoneOre",
+ "universalCable",
+ "bronzeTube",
+ "ironTube",
+ "netherTube",
+ "obbyTube",
+ "infiniteBattery",
+ "eliteBattery",
+ "advancedBattery",
+ "10kEUStore",
+ "blueDye",
+ "MonazitOre",
+ "quartzCrystal",
+ "whiteLuminiteCrystal",
+ "darkStoneIngot",
+ "invisiumIngot",
+ "demoniteOrb",
+ "enderGem",
+ "starconiumGem",
+ "osmoniumIngot",
+ "tapaziteGem",
+ "zectiumIngot",
+ "foolsRubyGem",
+ "rubyGem",
+ "meteoriteGem",
+ "adamiteShard",
+ "sapphireGem",
+ "copperIngot",
+ "ironStick",
+ "goldStick",
+ "diamondStick",
+ "reinforcedStick",
+ "draconicStick",
+ "emeraldStick",
+ "copperStick",
+ "tinStick",
+ "silverStick",
+ "bronzeStick",
+ "steelStick",
+ "leadStick",
+ "manyullynStick",
+ "arditeStick",
+ "cobaltStick",
+ "aluminiumStick",
+ "alumiteStick",
+ "oilsandsOre",
+ "copperWire",
+ "superconductorWire",
+ "sulfuricAcid",
+ "conveyorBelt",
+ "ironWire",
+ "aluminumWire",
+ "aluminiumWire",
+ "silverWire",
+ "tinWire",
+ "dustSiliconSmall",
+ "AluminumOre",
+ "plateHeavyT2",
+ "blockWool",
+ "alloyPlateEnergizedHardened",
+ "gasWood",
+ "alloyPlateEnergized",
+ "SilverOre",
+ "LeadOre",
+ "TinOre",
+ "CopperOre",
+ "silverOre",
+ "leadOre",
+ "tinOre",
+ "copperOre",
+ "bauxiteOre",
+ "HSLivingmetalIngot",
+ "oilMoving",
+ "oilStill",
+ "oilBucket",
+ "petroleumOre",
+ "dieselFuel",
+ "diamondNugget",
+ "planks",
+ "wood",
+ "stick",
+ "sticks",
+ "naquadah",
+ "obsidianRod",
+ "stoneRod",
+ "thaumiumRod",
+ "steelRod",
+ "netherrackRod",
+ "woodRod",
+ "ironRod",
+ "cactusRod",
+ "flintRod",
+ "copperRod",
+ "cobaltRod",
+ "alumiteRod",
+ "blueslimeRod",
+ "arditeRod",
+ "manyullynRod",
+ "bronzeRod",
+ "boneRod",
+ "slimeRod",
+ "redalloyBundled",
+ "bluestoneBundled",
+ "infusedteslatiteInsulated",
+ "redalloyInsulated",
+ "infusedteslatiteBundled"));
private final DateFormat mDateFormat = DateFormat.getInstance();
public ArrayList<String> mBufferedPlayerActivity = new ArrayList<>();
public final GT_BlockMap<Boolean> mCTMBlockCache = new GT_BlockMap<>();
@@ -562,9 +568,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
public int mPollutionHighPressureLavaBoilerPerSecond = 20;
public int mPollutionHighPressureCoalBoilerPerSecond = 30;
public int mPollutionBaseDieselGeneratorPerSecond = 200;
- public double[] mPollutionDieselGeneratorReleasedByTier = new double[] {0.1, 1.0, 0.9, 0.8};
+ public double[] mPollutionDieselGeneratorReleasedByTier = new double[] { 0.1, 1.0, 0.9, 0.8 };
public int mPollutionBaseGasTurbinePerSecond = 200;
- public double[] mPollutionGasTurbineReleasedByTier = new double[] {0.1, 1.0, 0.9, 0.8, 0.7, 0.6};
+ public double[] mPollutionGasTurbineReleasedByTier = new double[] { 0.1, 1.0, 0.9, 0.8, 0.7, 0.6 };
public final GT_UO_DimensionList mUndergroundOil = new GT_UO_DimensionList();
public int mTicksUntilNextCraftSound = 0;
public double mMagneticraftBonusOutputPercent = 0d;
@@ -594,7 +600,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
public boolean costlyCableConnection = false;
/**
- * This enables ambient-occlusion smooth lighting on tiles
+ * This enables ambient-occlusion smooth lighting on tiles
*/
public boolean mRenderTileAmbientOcclusion = true;
@@ -745,18 +751,17 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
MinecraftForge.EVENT_BUS.register(this);
MinecraftForge.ORE_GEN_BUS.register(this);
FMLCommonHandler.instance().bus().register(this);
- GregTech_API.sThaumcraftCompat = (IThaumcraftCompat)
- GT_Utility.callConstructor("gregtech.common.GT_ThaumcraftCompat", 0, null, GT_Values.D1, new Object[0]);
- for (FluidContainerRegistry.FluidContainerData tData :
- FluidContainerRegistry.getRegisteredFluidContainerData()) {
+ GregTech_API.sThaumcraftCompat = (IThaumcraftCompat) GT_Utility
+ .callConstructor("gregtech.common.GT_ThaumcraftCompat", 0, null, GT_Values.D1, new Object[0]);
+ for (FluidContainerRegistry.FluidContainerData tData : FluidContainerRegistry
+ .getRegisteredFluidContainerData()) {
onFluidContainerRegistration(new FluidContainerRegistry.FluidContainerRegisterEvent(tData));
}
try {
for (String tOreName : OreDictionary.getOreNames()) {
ItemStack tOreStack;
- for (Iterator i$ = OreDictionary.getOres(tOreName).iterator();
- i$.hasNext();
- registerOre(new OreDictionary.OreRegisterEvent(tOreName, tOreStack))) {
+ for (Iterator i$ = OreDictionary.getOres(tOreName).iterator(); i$
+ .hasNext(); registerOre(new OreDictionary.OreRegisterEvent(tOreName, tOreStack))) {
tOreStack = (ItemStack) i$.next();
}
}
@@ -773,8 +778,8 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
this.mIgnoreTcon = GregTech_API.sOPStuff.get(ConfigCategories.general, "ignoreTConstruct", true);
this.mWireHeatingTicks = GregTech_API.sOPStuff.get(ConfigCategories.general, "WireHeatingTicks", 4);
NetworkRegistry.INSTANCE.registerGuiHandler(GT_Values.GT, this);
- for (FluidContainerRegistry.FluidContainerData tData :
- FluidContainerRegistry.getRegisteredFluidContainerData()) {
+ for (FluidContainerRegistry.FluidContainerData tData : FluidContainerRegistry
+ .getRegisteredFluidContainerData()) {
if ((tData.filledContainer.getItem() == Items.potionitem) && (tData.filledContainer.getItemDamage() == 0)) {
tData.fluid.amount = 0;
break;
@@ -822,8 +827,12 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
ItemList.FR_Bee_Drone.set(GT_ModHandler.getModItem(aTextForestry, "beeDroneGE", 1L));
ItemList.FR_Bee_Princess.set(GT_ModHandler.getModItem(aTextForestry, "beePrincessGE", 1L));
ItemList.FR_Bee_Queen.set(GT_ModHandler.getModItem(aTextForestry, "beeQueenGE", 1L));
- ItemList.FR_Tree_Sapling.set(GT_ModHandler.getModItem(
- aTextForestry, "sapling", 1L, GT_ModHandler.getModItem(aTextForestry, "saplingGE", 1L)));
+ ItemList.FR_Tree_Sapling.set(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "sapling",
+ 1L,
+ GT_ModHandler.getModItem(aTextForestry, "saplingGE", 1L)));
ItemList.FR_Butterfly.set(GT_ModHandler.getModItem(aTextForestry, "butterflyGE", 1L));
ItemList.FR_Larvae.set(GT_ModHandler.getModItem(aTextForestry, "beeLarvaeGE", 1L));
ItemList.FR_Serum.set(GT_ModHandler.getModItem(aTextForestry, "serumGE", 1L));
@@ -837,12 +846,18 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
ItemList.Bottle_Empty.set(new ItemStack(Items.glass_bottle, 1));
ItemList.Cell_Universal_Fluid.set(GT_ModHandler.getIC2Item("FluidCell", 1L));
- ItemList.Cell_Empty.set(GT_ModHandler.getIC2Item(
- "cell", 1L, GT_ModHandler.getIC2Item("cellEmpty", 1L, GT_ModHandler.getIC2Item("emptyCell", 1L))));
+ ItemList.Cell_Empty.set(
+ GT_ModHandler.getIC2Item(
+ "cell",
+ 1L,
+ GT_ModHandler.getIC2Item("cellEmpty", 1L, GT_ModHandler.getIC2Item("emptyCell", 1L))));
ItemList.Cell_Water.set(GT_ModHandler.getIC2Item("waterCell", 1L, GT_ModHandler.getIC2Item("cellWater", 1L)));
ItemList.Cell_Lava.set(GT_ModHandler.getIC2Item("lavaCell", 1L, GT_ModHandler.getIC2Item("cellLava", 1L)));
- ItemList.Cell_Air.set(GT_ModHandler.getIC2Item(
- "airCell", 1L, GT_ModHandler.getIC2Item("cellAir", 1L, GT_ModHandler.getIC2Item("cellOxygen", 1L))));
+ ItemList.Cell_Air.set(
+ GT_ModHandler.getIC2Item(
+ "airCell",
+ 1L,
+ GT_ModHandler.getIC2Item("cellAir", 1L, GT_ModHandler.getIC2Item("cellOxygen", 1L))));
ItemList.IC2_Item_Casing_Iron.set(GT_ModHandler.getIC2Item("casingiron", 1L));
ItemList.IC2_Item_Casing_Gold.set(GT_ModHandler.getIC2Item("casinggold", 1L));
@@ -859,8 +874,8 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
ItemList.IC2_Hops.set(GT_ModHandler.getIC2Item("hops", 1L));
ItemList.IC2_Resin.set(GT_ModHandler.getIC2Item("resin", 1L));
ItemList.IC2_Plantball.set(GT_ModHandler.getIC2Item("plantBall", 1L));
- ItemList.IC2_PlantballCompressed.set(
- GT_ModHandler.getIC2Item("compressedPlantBall", 1L, ItemList.IC2_Plantball.get(1L)));
+ ItemList.IC2_PlantballCompressed
+ .set(GT_ModHandler.getIC2Item("compressedPlantBall", 1L, ItemList.IC2_Plantball.get(1L)));
ItemList.IC2_Crop_Seeds.set(GT_ModHandler.getIC2Item("cropSeed", 1L));
ItemList.IC2_Grin_Powder.set(GT_ModHandler.getIC2Item("grinPowder", 1L));
ItemList.IC2_Energium_Dust.set(GT_ModHandler.getIC2Item("energiumDust", 1L));
@@ -870,8 +885,8 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
ItemList.IC2_Food_Can_Empty.set(GT_ModHandler.getIC2Item("tinCan", 1L));
ItemList.IC2_Food_Can_Filled.set(GT_ModHandler.getIC2Item("filledTinCan", 1L, 0));
ItemList.IC2_Food_Can_Spoiled.set(GT_ModHandler.getIC2Item("filledTinCan", 1L, 1));
- ItemList.IC2_Industrial_Diamond.set(
- GT_ModHandler.getIC2Item("industrialDiamond", 1L, new ItemStack(Items.diamond, 1)));
+ ItemList.IC2_Industrial_Diamond
+ .set(GT_ModHandler.getIC2Item("industrialDiamond", 1L, new ItemStack(Items.diamond, 1)));
ItemList.IC2_Compressed_Coal_Ball.set(GT_ModHandler.getIC2Item("compressedCoalBall", 1L));
ItemList.IC2_Compressed_Coal_Chunk.set(GT_ModHandler.getIC2Item("coalChunk", 1L));
ItemList.IC2_ShaftIron.set(GT_ModHandler.getIC2Item("ironshaft", 1L));
@@ -963,10 +978,10 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(MOD_ID_TF, "item.yetiPlate", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(MOD_ID_TF, "item.yetiLegs", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(MOD_ID_TF, "item.yetiBoots", 1L, 32767));
- GT_ModHandler.sNonReplaceableItems.add(
- GT_ModHandler.getModItem("appliedenergistics2", "item.ToolCertusQuartzCuttingKnife", 1L, 32767));
- GT_ModHandler.sNonReplaceableItems.add(
- GT_ModHandler.getModItem("appliedenergistics2", "item.ToolNetherQuartzCuttingKnife", 1L, 32767));
+ GT_ModHandler.sNonReplaceableItems
+ .add(GT_ModHandler.getModItem("appliedenergistics2", "item.ToolCertusQuartzCuttingKnife", 1L, 32767));
+ GT_ModHandler.sNonReplaceableItems
+ .add(GT_ModHandler.getModItem("appliedenergistics2", "item.ToolNetherQuartzCuttingKnife", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(aTextForestry, "apiaristHelmet", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(aTextForestry, "apiaristChest", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(aTextForestry, "apiaristLegs", 1L, 32767));
@@ -975,10 +990,10 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(aTextForestry, "frameImpregnated", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(aTextForestry, "frameProven", 1L, 32767));
GT_ModHandler.sNonReplaceableItems.add(GT_ModHandler.getModItem(aTextForestry, "waxCast", 1L, 32767));
- GT_ModHandler.sNonReplaceableItems.add(
- GT_ModHandler.getModItem("GalacticraftCore", "item.sensorGlasses", 1L, 32767));
- GT_ModHandler.sNonReplaceableItems.add(
- GT_ModHandler.getModItem("IC2NuclearControl", "ItemToolThermometer", 1L, 32767));
+ GT_ModHandler.sNonReplaceableItems
+ .add(GT_ModHandler.getModItem("GalacticraftCore", "item.sensorGlasses", 1L, 32767));
+ GT_ModHandler.sNonReplaceableItems
+ .add(GT_ModHandler.getModItem("IC2NuclearControl", "ItemToolThermometer", 1L, 32767));
RecipeSorter.register(
"gregtech:shaped",
@@ -999,17 +1014,18 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_Log.out.println("GT_Mod: Beginning Load-Phase.");
GT_Log.ore.println("GT_Mod: Beginning Load-Phase.");
GT_OreDictUnificator.registerOre(
- "cropChilipepper", GT_ModHandler.getModItem("magicalcrops", "magicalcrops_CropProduce", 1L, 2));
- GT_OreDictUnificator.registerOre(
- "cropTomato", GT_ModHandler.getModItem("magicalcrops", "magicalcrops_CropProduce", 1L, 8));
- GT_OreDictUnificator.registerOre(
- "cropGrape", GT_ModHandler.getModItem("magicalcrops", "magicalcrops_CropProduce", 1L, 4));
+ "cropChilipepper",
+ GT_ModHandler.getModItem("magicalcrops", "magicalcrops_CropProduce", 1L, 2));
+ GT_OreDictUnificator
+ .registerOre("cropTomato", GT_ModHandler.getModItem("magicalcrops", "magicalcrops_CropProduce", 1L, 8));
+ GT_OreDictUnificator
+ .registerOre("cropGrape", GT_ModHandler.getModItem("magicalcrops", "magicalcrops_CropProduce", 1L, 4));
GT_OreDictUnificator.registerOre("cropTea", GT_ModHandler.getModItem("ganyssurface", "teaLeaves", 1L, 0));
// Clay buckets, which don't get registered until Iguana Tweaks pre-init
if (Loader.isModLoaded("IguanaTweaksTConstruct")) {
- OrePrefixes.bucketClay.mContainerItem =
- GT_ModHandler.getModItem("IguanaTweaksTConstruct", "clayBucketFired", 1L, 0);
+ OrePrefixes.bucketClay.mContainerItem = GT_ModHandler
+ .getModItem("IguanaTweaksTConstruct", "clayBucketFired", 1L, 0);
GT_OreDictUnificator.set(
OrePrefixes.bucketClay,
Materials.Empty,
@@ -1027,10 +1043,11 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
Materials.Milk,
GT_ModHandler.getModItem("IguanaTweaksTConstruct", "clayBucketMilk", 1L, 0));
- FluidContainerRegistry.registerFluidContainer(new FluidContainerRegistry.FluidContainerData(
- Materials.Milk.getFluid(1000L),
- GT_OreDictUnificator.get(OrePrefixes.bucketClay, Materials.Milk, 1L),
- GT_OreDictUnificator.get(OrePrefixes.bucketClay, Materials.Empty, 1L)));
+ FluidContainerRegistry.registerFluidContainer(
+ new FluidContainerRegistry.FluidContainerData(
+ Materials.Milk.getFluid(1000L),
+ GT_OreDictUnificator.get(OrePrefixes.bucketClay, Materials.Milk, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.bucketClay, Materials.Empty, 1L)));
}
MinecraftForge.EVENT_BUS.register(new GlobalEnergyWorldSavedData(""));
@@ -1132,8 +1149,8 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
addFullHazmatToGeneralItem("EnderIO", "item.stellar_boots", 1L);
GregTech_API.sLoadStarted = true;
- for (FluidContainerRegistry.FluidContainerData tData :
- FluidContainerRegistry.getRegisteredFluidContainerData()) {
+ for (FluidContainerRegistry.FluidContainerData tData : FluidContainerRegistry
+ .getRegisteredFluidContainerData()) {
if ((tData.filledContainer.getItem() == Items.potionitem) && (tData.filledContainer.getItemDamage() == 0)) {
tData.fluid.amount = 0;
break;
@@ -1142,8 +1159,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_LanguageManager.writePlaceholderStrings();
}
- public static long tBits = GT_ModHandler.RecipeBits.DO_NOT_CHECK_FOR_COLLISIONS
- | GT_ModHandler.RecipeBits.BUFFERED
+ public static long tBits = GT_ModHandler.RecipeBits.DO_NOT_CHECK_FOR_COLLISIONS | GT_ModHandler.RecipeBits.BUFFERED
| GT_ModHandler.RecipeBits.ONLY_ADD_IF_RESULT_IS_NOT_NULL
| GT_ModHandler.RecipeBits.NOT_REMOVABLE;
@@ -1160,10 +1176,10 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_MetaGenerated_Item_98.init();
GT_OreDictUnificator.addItemData(new ItemStack(Items.iron_door, 1), new ItemData(Materials.Iron, 21772800L));
- GT_OreDictUnificator.addItemData(
- new ItemStack(Items.wooden_door, 1, 32767), new ItemData(Materials.Wood, 21772800L));
- for (FluidContainerRegistry.FluidContainerData tData :
- FluidContainerRegistry.getRegisteredFluidContainerData()) {
+ GT_OreDictUnificator
+ .addItemData(new ItemStack(Items.wooden_door, 1, 32767), new ItemData(Materials.Wood, 21772800L));
+ for (FluidContainerRegistry.FluidContainerData tData : FluidContainerRegistry
+ .getRegisteredFluidContainerData()) {
if ((tData.filledContainer.getItem() == Items.potionitem) && (tData.filledContainer.getItemDamage() == 0)) {
tData.fluid.amount = 0;
break;
@@ -1187,59 +1203,59 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.crushedCentrifuged.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.crushedCentrifuged.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.crystalline.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.crystalline.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.crystal.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.crystal.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustPure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.crushedPurified.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.crushedPurified.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustPure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.cleanGravel.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.cleanGravel.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustPure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.reduced.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.reduced.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.clump.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.clump.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.shard.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.shard.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.crushed.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.crushed.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustImpure, aMaterial.mMacerateInto, 1L),
tBits,
- new Object[] {"h", "X", 'X', OrePrefixes.dirtyGravel.get(aMaterial)});
+ new Object[] { "h", "X", 'X', OrePrefixes.dirtyGravel.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustSmall, aMaterial, 4L),
tBits,
- new Object[] {" X ", 'X', OrePrefixes.dust.get(aMaterial)});
+ new Object[] { " X ", 'X', OrePrefixes.dust.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dustTiny, aMaterial, 9L),
tBits,
- new Object[] {"X ", 'X', OrePrefixes.dust.get(aMaterial)});
+ new Object[] { "X ", 'X', OrePrefixes.dust.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, aMaterial, 1L),
tBits,
- new Object[] {"XX", "XX", 'X', OrePrefixes.dustSmall.get(aMaterial)});
+ new Object[] { "XX", "XX", 'X', OrePrefixes.dustSmall.get(aMaterial) });
GT_ModHandler.addCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, aMaterial, 1L),
tBits,
- new Object[] {"XXX", "XXX", "XXX", 'X', OrePrefixes.dustTiny.get(aMaterial)});
+ new Object[] { "XXX", "XXX", "XXX", 'X', OrePrefixes.dustTiny.get(aMaterial) });
}
}
}
@@ -1255,8 +1271,8 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
this.mUniverse = null;
this.isFirstServerWorldTick = true;
- for (FluidContainerRegistry.FluidContainerData tData :
- FluidContainerRegistry.getRegisteredFluidContainerData()) {
+ for (FluidContainerRegistry.FluidContainerData tData : FluidContainerRegistry
+ .getRegisteredFluidContainerData()) {
if ((tData.filledContainer.getItem() == Items.potionitem) && (tData.filledContainer.getItemDamage() == 0)) {
tData.fluid.amount = 0;
break;
@@ -1331,11 +1347,10 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
@SubscribeEvent
public void onArrowNockEvent(ArrowNockEvent aEvent) {
- if ((!aEvent.isCanceled())
- && (GT_Utility.isStackValid(aEvent.result))
+ if ((!aEvent.isCanceled()) && (GT_Utility.isStackValid(aEvent.result))
&& (GT_Utility.getProjectile(SubTag.PROJECTILE_ARROW, aEvent.entityPlayer.inventory) != null)) {
- aEvent.entityPlayer.setItemInUse(
- aEvent.result, aEvent.result.getItem().getMaxItemUseDuration(aEvent.result));
+ aEvent.entityPlayer
+ .setItemInUse(aEvent.result, aEvent.result.getItem().getMaxItemUseDuration(aEvent.result));
aEvent.setCanceled(true);
}
}
@@ -1343,8 +1358,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
@SubscribeEvent
public void onArrowLooseEvent(ArrowLooseEvent aEvent) {
ItemStack aArrow = GT_Utility.getProjectile(SubTag.PROJECTILE_ARROW, aEvent.entityPlayer.inventory);
- if ((!aEvent.isCanceled())
- && (GT_Utility.isStackValid(aEvent.bow))
+ if ((!aEvent.isCanceled()) && (GT_Utility.isStackValid(aEvent.bow))
&& (aArrow != null)
&& ((aEvent.bow.getItem() instanceof ItemBow))) {
float tSpeed = aEvent.charge / 20.0F;
@@ -1355,13 +1369,12 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
if (tSpeed > 1.0D) {
tSpeed = 1.0F;
}
- EntityArrow tArrowEntity = ((IProjectileItem) aArrow.getItem())
- .getProjectile(
- SubTag.PROJECTILE_ARROW,
- aArrow,
- aEvent.entityPlayer.worldObj,
- aEvent.entityPlayer,
- tSpeed * 2.0F);
+ EntityArrow tArrowEntity = ((IProjectileItem) aArrow.getItem()).getProjectile(
+ SubTag.PROJECTILE_ARROW,
+ aArrow,
+ aEvent.entityPlayer.worldObj,
+ aEvent.entityPlayer,
+ tSpeed * 2.0F);
if (tSpeed >= 1.0F) {
tArrowEntity.setIsCritical(true);
}
@@ -1380,13 +1393,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
aEvent.bow.damageItem(1, aEvent.entityPlayer);
aEvent.bow.getItem();
- new WorldSpawnedEventBuilder.SoundAtEntityEventBuilder()
- .setPitch(0.64893958288F + tSpeed * 0.5F)
- .setVolume(1f)
- .setIdentifier(SoundResource.RANDOM_BOW)
- .setEntity(aEvent.entityPlayer)
- .setWorld(aEvent.entityPlayer.worldObj)
- .run();
+ new WorldSpawnedEventBuilder.SoundAtEntityEventBuilder().setPitch(0.64893958288F + tSpeed * 0.5F)
+ .setVolume(1f).setIdentifier(SoundResource.RANDOM_BOW).setEntity(aEvent.entityPlayer)
+ .setWorld(aEvent.entityPlayer.worldObj).run();
tArrowEntity.canBePickedUp = 1;
if (!aEvent.entityPlayer.capabilities.isCreativeMode) {
@@ -1414,18 +1423,18 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
public void onEntitySpawningEvent(EntityJoinWorldEvent aEvent) {
if ((aEvent.entity != null) && (!aEvent.entity.worldObj.isRemote)) {
if ((aEvent.entity instanceof EntityItem)) {
- ((EntityItem) aEvent.entity)
- .setEntityItemStack(
- GT_OreDictUnificator.get(true, ((EntityItem) aEvent.entity).getEntityItem(), true));
+ ((EntityItem) aEvent.entity).setEntityItemStack(
+ GT_OreDictUnificator.get(true, ((EntityItem) aEvent.entity).getEntityItem(), true));
}
- if ((this.mSkeletonsShootGTArrows > 0)
- && (aEvent.entity.getClass() == EntityArrow.class)
+ if ((this.mSkeletonsShootGTArrows > 0) && (aEvent.entity.getClass() == EntityArrow.class)
&& (aEvent.entity.worldObj.rand.nextInt(this.mSkeletonsShootGTArrows) == 0)
&& ((((EntityArrow) aEvent.entity).shootingEntity instanceof EntitySkeleton))) {
- aEvent.entity.worldObj.spawnEntityInWorld(new GT_Entity_Arrow(
- (EntityArrow) aEvent.entity,
- OrePrefixes.arrowGtWood.mPrefixedItems.get(
- aEvent.entity.worldObj.rand.nextInt(OrePrefixes.arrowGtWood.mPrefixedItems.size()))));
+ aEvent.entity.worldObj.spawnEntityInWorld(
+ new GT_Entity_Arrow(
+ (EntityArrow) aEvent.entity,
+ OrePrefixes.arrowGtWood.mPrefixedItems.get(
+ aEvent.entity.worldObj.rand
+ .nextInt(OrePrefixes.arrowGtWood.mPrefixedItems.size()))));
aEvent.entity.setDead();
}
}
@@ -1433,8 +1442,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
@SubscribeEvent
public void onOreGenEvent(OreGenEvent.GenerateMinable aGenerator) {
- if ((this.mDisableVanillaOres)
- && ((aGenerator.generator instanceof WorldGenMinable))
+ if ((this.mDisableVanillaOres) && ((aGenerator.generator instanceof WorldGenMinable))
&& (PREVENTED_ORES.contains(aGenerator.type))) {
aGenerator.setResult(Result.DENY);
}
@@ -1446,27 +1454,37 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
@SubscribeEvent
public void onPlayerInteraction(PlayerInteractEvent aEvent) {
- if ((aEvent.entityPlayer == null)
- || (aEvent.entityPlayer.worldObj == null)
+ if ((aEvent.entityPlayer == null) || (aEvent.entityPlayer.worldObj == null)
|| (aEvent.action == null)
|| (aEvent.world.provider == null)) {
return;
}
- if ((!aEvent.entityPlayer.worldObj.isRemote)
- && (aEvent.action != PlayerInteractEvent.Action.RIGHT_CLICK_AIR)
+ if ((!aEvent.entityPlayer.worldObj.isRemote) && (aEvent.action != PlayerInteractEvent.Action.RIGHT_CLICK_AIR)
&& (GT_Log.pal != null)) {
this.mBufferedPlayerActivity.add(
- getDataAndTime() + ";" + aEvent.action.name() + ";" + aEvent.entityPlayer.getDisplayName() + ";DIM:"
- + aEvent.world.provider.dimensionId + ";" + aEvent.x + ";" + aEvent.y + ";" + aEvent.z
- + ";|;" + aEvent.x / 10 + ";" + aEvent.y / 10 + ";"
+ getDataAndTime() + ";"
+ + aEvent.action.name()
+ + ";"
+ + aEvent.entityPlayer.getDisplayName()
+ + ";DIM:"
+ + aEvent.world.provider.dimensionId
+ + ";"
+ + aEvent.x
+ + ";"
+ + aEvent.y
+ + ";"
+ + aEvent.z
+ + ";|;"
+ + aEvent.x / 10
+ + ";"
+ + aEvent.y / 10
+ + ";"
+ aEvent.z / 10);
}
ItemStack aStack = aEvent.entityPlayer.getCurrentEquippedItem();
- if ((aStack != null)
- && (aEvent.action == PlayerInteractEvent.Action.RIGHT_CLICK_BLOCK)
+ if ((aStack != null) && (aEvent.action == PlayerInteractEvent.Action.RIGHT_CLICK_BLOCK)
&& (aStack.getItem() == Items.flint_and_steel)) {
- if ((!aEvent.world.isRemote)
- && (!aEvent.entityPlayer.capabilities.isCreativeMode)
+ if ((!aEvent.world.isRemote) && (!aEvent.entityPlayer.capabilities.isCreativeMode)
&& (aEvent.world.rand.nextInt(100) >= this.mFlintChance)) {
aEvent.setCanceled(true);
aStack.damageItem(1, aEvent.entityPlayer);
@@ -1486,27 +1504,38 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
if (aEvent.harvester != null) {
if ((!aEvent.world.isRemote) && (GT_Log.pal != null)) {
this.mBufferedPlayerActivity.add(
- getDataAndTime() + ";HARVEST_BLOCK;" + aEvent.harvester.getDisplayName() + ";DIM:"
- + aEvent.world.provider.dimensionId + ";" + aEvent.x + ";" + aEvent.y + ";" + aEvent.z
- + ";|;" + aEvent.x / 10 + ";" + aEvent.y / 10
- + ";" + aEvent.z / 10);
+ getDataAndTime() + ";HARVEST_BLOCK;"
+ + aEvent.harvester.getDisplayName()
+ + ";DIM:"
+ + aEvent.world.provider.dimensionId
+ + ";"
+ + aEvent.x
+ + ";"
+ + aEvent.y
+ + ";"
+ + aEvent.z
+ + ";|;"
+ + aEvent.x / 10
+ + ";"
+ + aEvent.y / 10
+ + ";"
+ + aEvent.z / 10);
}
ItemStack aStack = aEvent.harvester.getCurrentEquippedItem();
if (aStack != null) {
if ((aStack.getItem() instanceof GT_MetaGenerated_Tool)) {
- ((GT_MetaGenerated_Tool) aStack.getItem())
- .onHarvestBlockEvent(
- aEvent.drops,
- aStack,
- aEvent.harvester,
- aEvent.block,
- aEvent.x,
- aEvent.y,
- aEvent.z,
- (byte) aEvent.blockMetadata,
- aEvent.fortuneLevel,
- aEvent.isSilkTouching,
- aEvent);
+ ((GT_MetaGenerated_Tool) aStack.getItem()).onHarvestBlockEvent(
+ aEvent.drops,
+ aStack,
+ aEvent.harvester,
+ aEvent.block,
+ aEvent.x,
+ aEvent.y,
+ aEvent.z,
+ (byte) aEvent.blockMetadata,
+ aEvent.fortuneLevel,
+ aEvent.isSilkTouching,
+ aEvent);
}
if (EnchantmentHelper.getEnchantmentLevel(Enchantment.fireAspect.effectId, aStack) > 2) {
try {
@@ -1536,8 +1565,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
} else if (aMod.equals("gregtech")) {
aMod = "UNKNOWN";
}
- if ((aEvent == null)
- || (aEvent.Ore == null)
+ if ((aEvent == null) || (aEvent.Ore == null)
|| (aEvent.Ore.getItem() == null)
|| (aEvent.Name == null)
|| (aEvent.Name.isEmpty())
@@ -1566,8 +1594,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
}
}
String tModToName = aMod + " -> " + aEvent.Name;
- if ((this.mOreDictActivated)
- || (GregTech_API.sPostloadStarted)
+ if ((this.mOreDictActivated) || (GregTech_API.sPostloadStarted)
|| ((this.mSortToTheEnd) && (GregTech_API.sLoadFinished))) {
tModToName = aOriginalMod + " --Late--> " + aEvent.Name;
}
@@ -1596,70 +1623,71 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
} else if (aEvent.Name.equals("cobblestone")) {
GT_OreDictUnificator.registerOre("stoneCobble", aEvent.Ore);
return;
- } else if ((aEvent.Name.contains("|"))
- || (aEvent.Name.contains("*"))
+ } else if ((aEvent.Name.contains("|")) || (aEvent.Name.contains("*"))
|| (aEvent.Name.contains(":"))
|| (aEvent.Name.contains("."))
|| (aEvent.Name.contains("$"))) {
- GT_Log.ore.println(tModToName + " is using a private Prefix and is therefor getting ignored properly.");
- return;
- } else if (aEvent.Name.equals("copperWire")) {
- GT_OreDictUnificator.registerOre(OreDictNames.craftingWireCopper, aEvent.Ore);
- } else if (aEvent.Name.equals("oreHeeEndrium")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.ore, Materials.HeeEndium, aEvent.Ore);
- } else if (aEvent.Name.equals("sheetPlastic")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.plate, Materials.Plastic, aEvent.Ore);
- } else if (aEvent.Name.startsWith("shard")) {
- if (aEvent.Name.equals("shardAir")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedAir, aEvent.Ore);
+ GT_Log.ore.println(
+ tModToName + " is using a private Prefix and is therefor getting ignored properly.");
+ return;
+ } else
+ if (aEvent.Name.equals("copperWire")) {
+ GT_OreDictUnificator.registerOre(OreDictNames.craftingWireCopper, aEvent.Ore);
+ } else if (aEvent.Name.equals("oreHeeEndrium")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.ore, Materials.HeeEndium, aEvent.Ore);
+ } else if (aEvent.Name.equals("sheetPlastic")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.plate, Materials.Plastic, aEvent.Ore);
+ } else if (aEvent.Name.startsWith("shard")) {
+ if (aEvent.Name.equals("shardAir")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedAir, aEvent.Ore);
+ return;
+ } else if (aEvent.Name.equals("shardWater")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedWater, aEvent.Ore);
+ return;
+ } else if (aEvent.Name.equals("shardFire")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedFire, aEvent.Ore);
+ return;
+ } else if (aEvent.Name.equals("shardEarth")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedEarth, aEvent.Ore);
+ return;
+ } else if (aEvent.Name.equals("shardOrder")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedOrder, aEvent.Ore);
+ return;
+ } else if (aEvent.Name.equals("shardEntropy")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedEntropy, aEvent.Ore);
+ return;
+ }
+ } else if (aEvent.Name.equals("fieryIngot")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.FierySteel, aEvent.Ore);
return;
- } else if (aEvent.Name.equals("shardWater")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedWater, aEvent.Ore);
+ } else if (aEvent.Name.equals("ironwood")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.IronWood, aEvent.Ore);
return;
- } else if (aEvent.Name.equals("shardFire")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedFire, aEvent.Ore);
+ } else if (aEvent.Name.equals("steeleaf")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.Steeleaf, aEvent.Ore);
return;
- } else if (aEvent.Name.equals("shardEarth")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedEarth, aEvent.Ore);
+ } else if (aEvent.Name.equals("knightmetal")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.Knightmetal, aEvent.Ore);
return;
- } else if (aEvent.Name.equals("shardOrder")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedOrder, aEvent.Ore);
+ } else if (aEvent.Name.equals("compressedAluminum")) {
+ GT_OreDictUnificator.registerOre(OrePrefixes.compressed, Materials.Aluminium, aEvent.Ore);
return;
- } else if (aEvent.Name.equals("shardEntropy")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.gem, Materials.InfusedEntropy, aEvent.Ore);
+ } else if (aEvent.Name.contains(" ")) {
+ GT_Log.ore.println(
+ tModToName
+ + " is getting re-registered because the OreDict Name containing invalid spaces.");
+ GT_OreDictUnificator
+ .registerOre(aEvent.Name.replaceAll(" ", ""), GT_Utility.copyAmount(1L, aEvent.Ore));
+ aEvent.Ore.setStackDisplayName("Invalid OreDictionary Tag");
return;
- }
- } else if (aEvent.Name.equals("fieryIngot")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.FierySteel, aEvent.Ore);
- return;
- } else if (aEvent.Name.equals("ironwood")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.IronWood, aEvent.Ore);
- return;
- } else if (aEvent.Name.equals("steeleaf")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.Steeleaf, aEvent.Ore);
- return;
- } else if (aEvent.Name.equals("knightmetal")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.ingot, Materials.Knightmetal, aEvent.Ore);
- return;
- } else if (aEvent.Name.equals("compressedAluminum")) {
- GT_OreDictUnificator.registerOre(OrePrefixes.compressed, Materials.Aluminium, aEvent.Ore);
- return;
- } else if (aEvent.Name.contains(" ")) {
- GT_Log.ore.println(
- tModToName + " is getting re-registered because the OreDict Name containing invalid spaces.");
- GT_OreDictUnificator.registerOre(
- aEvent.Name.replaceAll(" ", ""), GT_Utility.copyAmount(1L, aEvent.Ore));
- aEvent.Ore.setStackDisplayName("Invalid OreDictionary Tag");
- return;
- } else if (this.mInvalidNames.contains(aEvent.Name)) {
- GT_Log.ore.println(tModToName + " is wrongly registered and therefor getting ignored.");
+ } else if (this.mInvalidNames.contains(aEvent.Name)) {
+ GT_Log.ore.println(tModToName + " is wrongly registered and therefor getting ignored.");
- return;
- }
+ return;
+ }
OrePrefixes aPrefix = OrePrefixes.getOrePrefix(aEvent.Name);
Materials aMaterial = Materials._NULL;
- if ((aPrefix == OrePrefixes.nugget)
- && (aMod.equals("Thaumcraft"))
+ if ((aPrefix == OrePrefixes.nugget) && (aMod.equals("Thaumcraft"))
&& (aEvent.Ore.getItem().getUnlocalizedName().contains("ItemResource"))) {
return;
}
@@ -1689,8 +1717,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
String tName = aEvent.Name.replaceFirst(aPrefix.toString(), "");
if (tName.length() > 0) {
char firstChar = tName.charAt(0);
- if (Character.isUpperCase(firstChar)
- || Character.isLowerCase(firstChar)
+ if (Character.isUpperCase(firstChar) || Character.isLowerCase(firstChar)
|| firstChar == '_'
|| Character.isDigit(firstChar)) {
if (aPrefix.mIsMaterialBased) {
@@ -1709,15 +1736,14 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
}
if (aMaterial != Materials._NULL) {
Materials tReRegisteredMaterial;
- for (Iterator i$ = aMaterial.mOreReRegistrations.iterator();
- i$.hasNext();
- GT_OreDictUnificator.registerOre(aPrefix, tReRegisteredMaterial, aEvent.Ore)) {
+ for (Iterator i$ = aMaterial.mOreReRegistrations.iterator(); i$
+ .hasNext(); GT_OreDictUnificator
+ .registerOre(aPrefix, tReRegisteredMaterial, aEvent.Ore)) {
tReRegisteredMaterial = (Materials) i$.next();
}
aMaterial.add(GT_Utility.copyAmount(1L, aEvent.Ore));
- if (GregTech_API.sThaumcraftCompat != null
- && aPrefix.doGenerateItem(aMaterial)
+ if (GregTech_API.sThaumcraftCompat != null && aPrefix.doGenerateItem(aMaterial)
&& !aPrefix.isIgnored(aMaterial)) {
List<TC_AspectStack> tAspects = new ArrayList<>();
for (TC_AspectStack tAspect : aPrefix.mAspects) tAspect.addToAspectList(tAspects);
@@ -1725,7 +1751,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
for (TC_AspectStack tAspect : aMaterial.mAspects)
tAspect.addToAspectList(tAspects);
GregTech_API.sThaumcraftCompat.registerThaumcraftAspectsToItem(
- GT_Utility.copyAmount(1, aEvent.Ore), tAspects, aEvent.Name);
+ GT_Utility.copyAmount(1, aEvent.Ore),
+ tAspects,
+ aEvent.Name);
}
switch (aPrefix) {
@@ -1741,37 +1769,48 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_OreDictUnificator.registerOre(Dyes.dyeBlue, aEvent.Ore);
} else if (aMaterial == Materials.Lazurite) {
GT_OreDictUnificator.registerOre(Dyes.dyeCyan, aEvent.Ore);
- } else if (aMaterial == Materials.InfusedAir
- || aMaterial == Materials.InfusedWater
- || aMaterial == Materials.InfusedFire
- || aMaterial == Materials.InfusedEarth
- || aMaterial == Materials.InfusedOrder
- || aMaterial == Materials.InfusedEntropy) {
- GT_OreDictUnificator.registerOre(
- aMaterial.mName.replaceFirst("Infused", "shard"), aEvent.Ore);
- } else if (aMaterial == Materials.Chocolate) {
- GT_OreDictUnificator.registerOre(Dyes.dyeBrown, aEvent.Ore);
- } else if (aMaterial == Materials.CertusQuartz
- || aMaterial == Materials.NetherQuartz) {
- GT_OreDictUnificator.registerOre(
- OrePrefixes.item.get(aMaterial), aEvent.Ore);
- GT_OreDictUnificator.registerOre(
- OrePrefixes.crystal, aMaterial, aEvent.Ore);
- GT_OreDictUnificator.registerOre(OreDictNames.craftingQuartz, aEvent.Ore);
- } else if (aMaterial == Materials.Fluix
- || aMaterial == Materials.Quartz
- || aMaterial == Materials.Quartzite) {
- GT_OreDictUnificator.registerOre(
- OrePrefixes.crystal, aMaterial, aEvent.Ore);
- GT_OreDictUnificator.registerOre(OreDictNames.craftingQuartz, aEvent.Ore);
- }
+ } else
+ if (aMaterial == Materials.InfusedAir || aMaterial == Materials.InfusedWater
+ || aMaterial == Materials.InfusedFire
+ || aMaterial == Materials.InfusedEarth
+ || aMaterial == Materials.InfusedOrder
+ || aMaterial == Materials.InfusedEntropy) {
+ GT_OreDictUnificator.registerOre(
+ aMaterial.mName.replaceFirst("Infused", "shard"),
+ aEvent.Ore);
+ } else
+ if (aMaterial == Materials.Chocolate) {
+ GT_OreDictUnificator.registerOre(Dyes.dyeBrown, aEvent.Ore);
+ } else if (aMaterial == Materials.CertusQuartz
+ || aMaterial == Materials.NetherQuartz) {
+ GT_OreDictUnificator.registerOre(
+ OrePrefixes.item.get(aMaterial),
+ aEvent.Ore);
+ GT_OreDictUnificator.registerOre(
+ OrePrefixes.crystal,
+ aMaterial,
+ aEvent.Ore);
+ GT_OreDictUnificator.registerOre(
+ OreDictNames.craftingQuartz,
+ aEvent.Ore);
+ } else
+ if (aMaterial == Materials.Fluix || aMaterial == Materials.Quartz
+ || aMaterial == Materials.Quartzite) {
+ GT_OreDictUnificator.registerOre(
+ OrePrefixes.crystal,
+ aMaterial,
+ aEvent.Ore);
+ GT_OreDictUnificator.registerOre(
+ OreDictNames.craftingQuartz,
+ aEvent.Ore);
+ }
break;
case cableGt01:
if (aMaterial == Materials.Tin) {
GT_OreDictUnificator.registerOre(OreDictNames.craftingWireTin, aEvent.Ore);
} else if (aMaterial == Materials.AnyCopper) {
- GT_OreDictUnificator.registerOre(
- OreDictNames.craftingWireCopper, aEvent.Ore);
+ GT_OreDictUnificator
+ .registerOre(OreDictNames.craftingWireCopper, aEvent.Ore);
} else if (aMaterial == Materials.Gold) {
GT_OreDictUnificator.registerOre(OreDictNames.craftingWireGold, aEvent.Ore);
} else if (aMaterial == Materials.AnyIron) {
@@ -1783,10 +1822,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
&& (aMaterial.mColor != Dyes._NULL)) {
GT_OreDictUnificator.registerOre(
"craftingLens"
- + aMaterial
- .mColor
- .toString()
- .replaceFirst("dye", ""),
+ + aMaterial.mColor.toString().replaceFirst("dye", ""),
aEvent.Ore);
}
break;
@@ -1813,12 +1849,12 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_RecipeRegistrator.sRodMaterialList.add(aMaterial);
} else if (aMaterial == Materials.Wood) {
GT_OreDictUnificator.addToBlacklist(aEvent.Ore);
- } else if ((aMaterial == Materials.Tin)
- || (aMaterial == Materials.Lead)
+ } else if ((aMaterial == Materials.Tin) || (aMaterial == Materials.Lead)
|| (aMaterial == Materials.SolderingAlloy)) {
- GT_OreDictUnificator.registerOre(
- ToolDictNames.craftingToolSolderingMetal, aEvent.Ore);
- }
+ GT_OreDictUnificator.registerOre(
+ ToolDictNames.craftingToolSolderingMetal,
+ aEvent.Ore);
+ }
break;
case dust:
if (aMaterial == Materials.Salt) {
@@ -1855,45 +1891,41 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_OreDictUnificator.registerOre("steeleaf", aEvent.Ore);
} else if (aMaterial == Materials.Knightmetal) {
GT_OreDictUnificator.registerOre("knightmetal", aEvent.Ore);
- } else if ((aMaterial == Materials.Brass)
- && (aEvent.Ore.getItemDamage() == 2)
- && (aEvent.Ore
- .getUnlocalizedName()
- .equals("item.ingotBrass"))
- && (new ItemStack(aEvent.Ore.getItem(), 1, 0)
- .getUnlocalizedName()
+ } else if ((aMaterial == Materials.Brass) && (aEvent.Ore.getItemDamage() == 2)
+ && (aEvent.Ore.getUnlocalizedName().equals("item.ingotBrass"))
+ && (new ItemStack(aEvent.Ore.getItem(), 1, 0).getUnlocalizedName()
.contains("red"))) {
- GT_OreDictUnificator.set(
- OrePrefixes.ingot,
- Materials.RedAlloy,
- new ItemStack(aEvent.Ore.getItem(), 1, 0));
- GT_OreDictUnificator.set(
- OrePrefixes.ingot,
- Materials.BlueAlloy,
- new ItemStack(aEvent.Ore.getItem(), 1, 1));
- GT_OreDictUnificator.set(
- OrePrefixes.ingot,
- Materials.Brass,
- new ItemStack(aEvent.Ore.getItem(), 1, 2));
- if (!mDisableIC2Cables) {
- GT_Values.RA.addWiremillRecipe(
- GT_ModHandler.getIC2Item("copperCableItem", 3L),
- new ItemStack(aEvent.Ore.getItem(), 1, 8),
- 400,
- 1);
- GT_Values.RA.addWiremillRecipe(
- GT_ModHandler.getIC2Item("ironCableItem", 6L),
- new ItemStack(aEvent.Ore.getItem(), 1, 9),
- 400,
- 2);
- }
- GT_Values.RA.addCutterRecipe(
- new ItemStack(aEvent.Ore.getItem(), 1, 3),
- new ItemStack(aEvent.Ore.getItem(), 16, 4),
- null,
- 400,
- 8);
- }
+ GT_OreDictUnificator.set(
+ OrePrefixes.ingot,
+ Materials.RedAlloy,
+ new ItemStack(aEvent.Ore.getItem(), 1, 0));
+ GT_OreDictUnificator.set(
+ OrePrefixes.ingot,
+ Materials.BlueAlloy,
+ new ItemStack(aEvent.Ore.getItem(), 1, 1));
+ GT_OreDictUnificator.set(
+ OrePrefixes.ingot,
+ Materials.Brass,
+ new ItemStack(aEvent.Ore.getItem(), 1, 2));
+ if (!mDisableIC2Cables) {
+ GT_Values.RA.addWiremillRecipe(
+ GT_ModHandler.getIC2Item("copperCableItem", 3L),
+ new ItemStack(aEvent.Ore.getItem(), 1, 8),
+ 400,
+ 1);
+ GT_Values.RA.addWiremillRecipe(
+ GT_ModHandler.getIC2Item("ironCableItem", 6L),
+ new ItemStack(aEvent.Ore.getItem(), 1, 9),
+ 400,
+ 2);
+ }
+ GT_Values.RA.addCutterRecipe(
+ new ItemStack(aEvent.Ore.getItem(), 1, 3),
+ new ItemStack(aEvent.Ore.getItem(), 16, 4),
+ null,
+ 400,
+ 8);
+ }
break;
default:
break;
@@ -1911,11 +1943,11 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
return;
}
}
- // GT_FML_LOGGER.info("Material Name: "+aEvent.Name+ "
+ // GT_FML_LOGGER.info("Material Name: "+aEvent.Name+ "
// !!!Unknown Material detected!!! Please report to GregTech Intergalactical for
// additional compatiblity. This is not an Error, an Issue nor a Lag Source, it is just
// an Information, which you should pass to me.");
- // GT_Log.ore.println(tModToName + " uses an unknown
+ // GT_Log.ore.println(tModToName + " uses an unknown
// Material. Report this to GregTech.");
return;
}
@@ -1999,14 +2031,13 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
}
@SuppressWarnings("deprecated")
- public static void stepMaterialsVanilla(
- Collection<GT_Proxy.OreDictEventContainer> mEvents, ProgressManager.ProgressBar progressBar) {
+ public static void stepMaterialsVanilla(Collection<GT_Proxy.OreDictEventContainer> mEvents,
+ ProgressManager.ProgressBar progressBar) {
int size = 5;
int sizeStep = mEvents.size() / 20 - 1;
GT_Proxy.OreDictEventContainer tEvent;
- for (Iterator<GT_Proxy.OreDictEventContainer> i$ = mEvents.iterator();
- i$.hasNext();
- GT_Proxy.registerRecipes(tEvent)) {
+ for (Iterator<GT_Proxy.OreDictEventContainer> i$ = mEvents.iterator(); i$.hasNext(); GT_Proxy
+ .registerRecipes(tEvent)) {
tEvent = i$.next();
sizeStep--;
if (sizeStep == 0) {
@@ -2094,43 +2125,49 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
for (int i = 0; i < aEvent.world.loadedEntityList.size(); i++) {
if ((aEvent.world.loadedEntityList.get(i) instanceof Entity)) {
Entity tEntity = (Entity) aEvent.world.loadedEntityList.get(i);
- if (((tEntity instanceof EntityItem))
- && (this.mItemDespawnTime != 6000)
+ if (((tEntity instanceof EntityItem)) && (this.mItemDespawnTime != 6000)
&& (((EntityItem) tEntity).lifespan == 6000)) {
((EntityItem) tEntity).lifespan = this.mItemDespawnTime;
- } else if (((tEntity instanceof EntityLivingBase))
- && (this.mMaxEqualEntitiesAtOneSpot > 0)
+ } else if (((tEntity instanceof EntityLivingBase)) && (this.mMaxEqualEntitiesAtOneSpot > 0)
&& (!(tEntity instanceof EntityPlayer))
&& (tEntity.canBePushed())
&& (((EntityLivingBase) tEntity).getHealth() > 0.0F)) {
- List tList = tEntity.worldObj.getEntitiesWithinAABBExcludingEntity(
- tEntity,
- tEntity.boundingBox.expand(0.20000000298023224D, 0.0D, 0.20000000298023224D));
- Class tClass = tEntity.getClass();
- int tEntityCount = 1;
- if (tList != null) {
- for (Object o : tList) {
- if ((o != null) && (o.getClass() == tClass)) {
- tEntityCount++;
+ List tList = tEntity.worldObj.getEntitiesWithinAABBExcludingEntity(
+ tEntity,
+ tEntity.boundingBox
+ .expand(0.20000000298023224D, 0.0D, 0.20000000298023224D));
+ Class tClass = tEntity.getClass();
+ int tEntityCount = 1;
+ if (tList != null) {
+ for (Object o : tList) {
+ if ((o != null) && (o.getClass() == tClass)) {
+ tEntityCount++;
+ }
+ }
}
- }
- }
- if (tEntityCount > this.mMaxEqualEntitiesAtOneSpot) {
- if (debugEntityCramming) {
- // Cheeseball way of not receiving a bunch of spam caused by 1 location
- // obviously fails if there are crammed entities in more than one spot.
- if (tEntity.posX != oldX && tEntity.posY != oldY && tEntity.posZ != oldZ) {
- GT_Log.out.println("CRAM: Excess entities: " + tEntityCount + " at X "
- + tEntity.posX + " Y " + tEntity.posY + " Z " + tEntity.posZ);
- oldX = tEntity.posX;
- oldY = tEntity.posY;
- oldZ = tEntity.posZ;
+ if (tEntityCount > this.mMaxEqualEntitiesAtOneSpot) {
+ if (debugEntityCramming) {
+ // Cheeseball way of not receiving a bunch of spam caused by 1 location
+ // obviously fails if there are crammed entities in more than one spot.
+ if (tEntity.posX != oldX && tEntity.posY != oldY && tEntity.posZ != oldZ) {
+ GT_Log.out.println(
+ "CRAM: Excess entities: " + tEntityCount
+ + " at X "
+ + tEntity.posX
+ + " Y "
+ + tEntity.posY
+ + " Z "
+ + tEntity.posZ);
+ oldX = tEntity.posX;
+ oldY = tEntity.posY;
+ oldZ = tEntity.posZ;
+ }
+ }
+ tEntity.attackEntityFrom(
+ DamageSource.inWall,
+ tEntityCount - this.mMaxEqualEntitiesAtOneSpot);
}
}
- tEntity.attackEntityFrom(
- DamageSource.inWall, tEntityCount - this.mMaxEqualEntitiesAtOneSpot);
- }
- }
}
}
if (debugEntityCramming && (aEvent.world.loadedEntityList.size() != 0)) {
@@ -2159,7 +2196,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GT_Utility.copyAmount(1L, aOre.mEvent.Ore));
}
} else {
- // GT_FML_LOGGER.info("Thingy Name: "+ aOre.mEvent.Name+ " !!!Unknown 'Thingy' detected!!! This
+ // GT_FML_LOGGER.info("Thingy Name: "+ aOre.mEvent.Name+ " !!!Unknown 'Thingy' detected!!! This
// Object seems to probably not follow a valid OreDictionary Convention, or I missed a Convention. Please
// report to GregTech Intergalactical for additional compatiblity. This is not an Error, an Issue nor a Lag
// Source, it is just an Information, which you should pass to me.");
@@ -2169,8 +2206,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
@SubscribeEvent
public void onPlayerTickEventServer(TickEvent.PlayerTickEvent aEvent) {
if ((aEvent.side.isServer()) && (aEvent.phase == TickEvent.Phase.END) && (!aEvent.player.isDead)) {
- if ((aEvent.player.ticksExisted % 200 == 0)
- && (aEvent.player.capabilities.allowEdit)
+ if ((aEvent.player.ticksExisted % 200 == 0) && (aEvent.player.capabilities.allowEdit)
&& (!aEvent.player.capabilities.isCreativeMode)
&& (this.mSurvivalIntoAdventure)) {
aEvent.player.setGameType(GameType.ADVENTURE);
@@ -2182,13 +2218,18 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
"Interaction_DESCRIPTION_Index_097",
"It's dangerous to go alone! Take this.",
false));
- aEvent.player.worldObj.spawnEntityInWorld(new EntityItem(
- aEvent.player.worldObj,
- aEvent.player.posX,
- aEvent.player.posY,
- aEvent.player.posZ,
- GT_MetaGenerated_Tool_01.INSTANCE.getToolWithStats(
- GT_MetaGenerated_Tool_01.AXE, 1, Materials.Flint, Materials.Wood, null)));
+ aEvent.player.worldObj.spawnEntityInWorld(
+ new EntityItem(
+ aEvent.player.worldObj,
+ aEvent.player.posX,
+ aEvent.player.posY,
+ aEvent.player.posZ,
+ GT_MetaGenerated_Tool_01.INSTANCE.getToolWithStats(
+ GT_MetaGenerated_Tool_01.AXE,
+ 1,
+ Materials.Flint,
+ Materials.Wood,
+ null)));
}
}
final boolean tHungerEffect = (this.mHungerEffect) && (aEvent.player.ticksExisted % 2400 == 1200);
@@ -2199,7 +2240,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
if ((tStack = aEvent.player.inventory.getStackInSlot(i)) != null) {
if (!aEvent.player.capabilities.isCreativeMode) {
GT_Utility.applyRadioactivity(
- aEvent.player, GT_Utility.getRadioactivityLevel(tStack), tStack.stackSize);
+ aEvent.player,
+ GT_Utility.getRadioactivityLevel(tStack),
+ tStack.stackSize);
final float tHeat = GT_Utility.getHeatDamageFromItem(tStack);
if (tHeat != 0.0F) {
if (tHeat > 0.0F) {
@@ -2222,7 +2265,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
if ((tStack = aEvent.player.inventory.armorInventory[i]) != null) {
if (!aEvent.player.capabilities.isCreativeMode) {
GT_Utility.applyRadioactivity(
- aEvent.player, GT_Utility.getRadioactivityLevel(tStack), tStack.stackSize);
+ aEvent.player,
+ GT_Utility.getRadioactivityLevel(tStack),
+ tStack.stackSize);
final float tHeat = GT_Utility.getHeatDamageFromItem(tStack);
if (tHeat != 0.0F) {
if (tHeat > 0.0F) {
@@ -2303,8 +2348,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
}
private static List<String> getOreDictNames(ItemStack stack) {
- return Arrays.stream(OreDictionary.getOreIDs(stack))
- .mapToObj(OreDictionary::getOreName)
+ return Arrays.stream(OreDictionary.getOreIDs(stack)).mapToObj(OreDictionary::getOreName)
.collect(Collectors.toList());
}
@@ -2315,8 +2359,8 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
}
int rFuelValue = 0;
if ((aFuel.getItem() instanceof GT_MetaGenerated_Item)) {
- final Short tFuelValue =
- ((GT_MetaGenerated_Item) aFuel.getItem()).mBurnValues.get((short) aFuel.getItemDamage());
+ final Short tFuelValue = ((GT_MetaGenerated_Item) aFuel.getItem()).mBurnValues
+ .get((short) aFuel.getItemDamage());
if (tFuelValue != null) {
rFuelValue = Math.max(rFuelValue, tFuelValue);
}
@@ -2330,10 +2374,7 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
// If not check the ore dict
rFuelValue = Math.max(
rFuelValue,
- getOreDictNames(aFuel).stream()
- .mapToInt(f -> oreDictBurnTimes.getOrDefault(f, 0))
- .max()
- .orElse(0));
+ getOreDictNames(aFuel).stream().mapToInt(f -> oreDictBurnTimes.getOrDefault(f, 0)).max().orElse(0));
}
// If we have something from the GT MetaGenerated_Item, ItemFuelValue, or OreDict return
@@ -2356,18 +2397,16 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
// If the fluid is registered as custom inside the Material's constructor then to add custom fluid
// textures go to blocks/fluids and place the .png. File should be called fluid.fluid.{unlocalised_name}.png.
// All lower case.
- final String fluidTexture =
- aMaterial.mIconSet.is_custom ? "fluid." + aMaterial.mName.toLowerCase() : "autogenerated";
+ final String fluidTexture = aMaterial.mIconSet.is_custom ? "fluid." + aMaterial.mName.toLowerCase()
+ : "autogenerated";
return GT_FluidFactory.builder(aMaterial.mName.toLowerCase(Locale.ENGLISH))
- .withLocalizedName(aMaterial.mDefaultLocalName)
- .withTextureName(fluidTexture)
- .withColorRGBA(aMaterial.mRGBa)
- .withStateAndTemperature(LIQUID, aMaterial.getLiquidTemperature())
- .buildAndRegister()
- .configureMaterials(aMaterial)
+ .withLocalizedName(aMaterial.mDefaultLocalName).withTextureName(fluidTexture)
+ .withColorRGBA(aMaterial.mRGBa).withStateAndTemperature(LIQUID, aMaterial.getLiquidTemperature())
+ .buildAndRegister().configureMaterials(aMaterial)
.registerBContainers(
- GT_OreDictUnificator.get(OrePrefixes.cell, aMaterial, 1L), ItemList.Cell_Empty.get(1L))
+ GT_OreDictUnificator.get(OrePrefixes.cell, aMaterial, 1L),
+ ItemList.Cell_Empty.get(1L))
.asFluid();
}
@@ -2375,18 +2414,16 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
// If the fluid is registered as custom inside the Material's constructor then to add custom fluid
// textures go to blocks/fluids and place the .png. File should be called fluid.gas.{unlocalised_name}.png. All
// lower case.
- final String fluidTexture =
- aMaterial.mIconSet.is_custom ? ("gas." + aMaterial.mName.toLowerCase()) : "autogenerated";
+ final String fluidTexture = aMaterial.mIconSet.is_custom ? ("gas." + aMaterial.mName.toLowerCase())
+ : "autogenerated";
return GT_FluidFactory.builder(aMaterial.mName.toLowerCase(Locale.ENGLISH))
- .withLocalizedName(aMaterial.mDefaultLocalName)
- .withTextureName(fluidTexture)
- .withColorRGBA(aMaterial.mRGBa)
- .withStateAndTemperature(GAS, aMaterial.getGasTemperature())
- .buildAndRegister()
- .configureMaterials(aMaterial)
+ .withLocalizedName(aMaterial.mDefaultLocalName).withTextureName(fluidTexture)
+ .withColorRGBA(aMaterial.mRGBa).withStateAndTemperature(GAS, aMaterial.getGasTemperature())
+ .buildAndRegister().configureMaterials(aMaterial)
.registerBContainers(
- GT_OreDictUnificator.get(OrePrefixes.cell, aMaterial, 1L), ItemList.Cell_Empty.get(1L))
+ GT_OreDictUnificator.get(OrePrefixes.cell, aMaterial, 1L),
+ ItemList.Cell_Empty.get(1L))
.asFluid();
}
@@ -2394,15 +2431,12 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
// If the fluid is registered as custom inside the Material's constructor then to add custom fluid
// textures go to blocks/fluids and place the .png. File should be called fluid.plasma.{unlocalised_name}.png.
// All lower case.
- final String fluidTexture =
- aMaterial.mIconSet.is_custom ? ("plasma." + aMaterial.mName.toLowerCase()) : "plasma.autogenerated";
+ final String fluidTexture = aMaterial.mIconSet.is_custom ? ("plasma." + aMaterial.mName.toLowerCase())
+ : "plasma.autogenerated";
return GT_FluidFactory.builder("plasma." + aMaterial.mName.toLowerCase(Locale.ENGLISH))
- .withLocalizedName(aMaterial.mDefaultLocalName + " Plasma")
- .withTextureName(fluidTexture)
- .withColorRGBA(aMaterial.mMoltenRGBa)
- .withStateAndTemperature(PLASMA, 10000)
- .buildAndRegister()
+ .withLocalizedName(aMaterial.mDefaultLocalName + " Plasma").withTextureName(fluidTexture)
+ .withColorRGBA(aMaterial.mMoltenRGBa).withStateAndTemperature(PLASMA, 10000).buildAndRegister()
.configureMaterials(aMaterial)
.registerContainers(
GT_OreDictUnificator.get(OrePrefixes.cellPlasma, aMaterial, 1L),
@@ -2415,16 +2449,14 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
// If the fluid is registered as custom inside the Material's constructor then to add custom fluid
// textures go to blocks/fluids and place the .png. File should be called fluid.molten.{unlocalised_name}.png.
// All lower case.
- final String fluidTexture =
- aMaterial.mIconSet.is_custom ? ("molten." + aMaterial.mName.toLowerCase()) : "molten.autogenerated";
+ final String fluidTexture = aMaterial.mIconSet.is_custom ? ("molten." + aMaterial.mName.toLowerCase())
+ : "molten.autogenerated";
return GT_FluidFactory.builder("molten." + aMaterial.mName.toLowerCase(Locale.ENGLISH))
- .withLocalizedName("Molten " + aMaterial.mDefaultLocalName)
- .withTextureName(fluidTexture)
+ .withLocalizedName("Molten " + aMaterial.mDefaultLocalName).withTextureName(fluidTexture)
.withColorRGBA(aMaterial.mMoltenRGBa)
.withStateAndTemperature(MOLTEN, aMaterial.mMeltingPoint < 0 ? 1000 : aMaterial.mMeltingPoint)
- .buildAndRegister()
- .configureMaterials(aMaterial)
+ .buildAndRegister().configureMaterials(aMaterial)
.registerContainers(
GT_OreDictUnificator.get(OrePrefixes.cellMolten, aMaterial, 1L),
ItemList.Cell_Empty.get(1L),
@@ -2436,10 +2468,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
public void addAutoGeneratedHydroCrackedFluids(Materials aMaterial) {
Fluid[] crackedFluids = new Fluid[3];
- String[] namePrefixes = {"lightlyhydrocracked.", "moderatelyhydrocracked.", "severelyhydrocracked."};
- OrePrefixes[] orePrefixes = {
- OrePrefixes.cellHydroCracked1, OrePrefixes.cellHydroCracked2, OrePrefixes.cellHydroCracked3
- };
+ String[] namePrefixes = { "lightlyhydrocracked.", "moderatelyhydrocracked.", "severelyhydrocracked." };
+ OrePrefixes[] orePrefixes = { OrePrefixes.cellHydroCracked1, OrePrefixes.cellHydroCracked2,
+ OrePrefixes.cellHydroCracked3 };
final Fluid uncrackedFluid;
if (aMaterial.mFluid != null) {
uncrackedFluid = aMaterial.mFluid;
@@ -2450,11 +2481,10 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
crackedFluids[i] = GT_FluidFactory.builder(namePrefixes[i] + aMaterial.mName.toLowerCase(Locale.ENGLISH))
.withIconsFrom(uncrackedFluid)
.withLocalizedName(orePrefixes[i].mLocalizedMaterialPre + aMaterial.mDefaultLocalName)
- .withColorRGBA(aMaterial.mRGBa)
- .withStateAndTemperature(GAS, 775)
- .buildAndRegister()
+ .withColorRGBA(aMaterial.mRGBa).withStateAndTemperature(GAS, 775).buildAndRegister()
.registerBContainers(
- GT_OreDictUnificator.get(orePrefixes[i], aMaterial, 1L), ItemList.Cell_Empty.get(1L))
+ GT_OreDictUnificator.get(orePrefixes[i], aMaterial, 1L),
+ ItemList.Cell_Empty.get(1L))
.asFluid();
int hydrogenAmount = 2 * i + 2;
@@ -2487,10 +2517,9 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
public void addAutoGeneratedSteamCrackedFluids(Materials aMaterial) {
Fluid[] crackedFluids = new Fluid[3];
- String[] namePrefixes = {"lightlysteamcracked.", "moderatelysteamcracked.", "severelysteamcracked."};
- OrePrefixes[] orePrefixes = {
- OrePrefixes.cellSteamCracked1, OrePrefixes.cellSteamCracked2, OrePrefixes.cellSteamCracked3
- };
+ String[] namePrefixes = { "lightlysteamcracked.", "moderatelysteamcracked.", "severelysteamcracked." };
+ OrePrefixes[] orePrefixes = { OrePrefixes.cellSteamCracked1, OrePrefixes.cellSteamCracked2,
+ OrePrefixes.cellSteamCracked3 };
final Fluid uncrackedFluid;
if (aMaterial.mFluid != null) {
uncrackedFluid = aMaterial.mFluid;
@@ -2501,11 +2530,10 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
crackedFluids[i] = GT_FluidFactory.builder(namePrefixes[i] + aMaterial.mName.toLowerCase(Locale.ENGLISH))
.withIconsFrom(uncrackedFluid)
.withLocalizedName(orePrefixes[i].mLocalizedMaterialPre + aMaterial.mDefaultLocalName)
- .withColorRGBA(aMaterial.mRGBa)
- .withStateAndTemperature(GAS, 775)
- .buildAndRegister()
+ .withColorRGBA(aMaterial.mRGBa).withStateAndTemperature(GAS, 775).buildAndRegister()
.registerBContainers(
- GT_OreDictUnificator.get(orePrefixes[i], aMaterial, 1L), ItemList.Cell_Empty.get(1L))
+ GT_OreDictUnificator.get(orePrefixes[i], aMaterial, 1L),
+ ItemList.Cell_Empty.get(1L))
.asFluid();
GT_Values.RA.addCrackingRecipe(
@@ -2548,23 +2576,13 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
/**
* @deprecated use {@link GT_FluidFactory#builder}
*/
- @SuppressWarnings({"MethodWithTooManyParameters"}) // Deprecated method
+ @SuppressWarnings({ "MethodWithTooManyParameters" }) // Deprecated method
@Deprecated
- public Fluid addFluid(
- String aName,
- String aLocalized,
- Materials aMaterial,
- int aState,
- int aTemperatureK,
- ItemStack aFullContainer,
- ItemStack aEmptyContainer,
- int aFluidAmount) {
- return GT_FluidFactory.builder(aName)
- .withLocalizedName(aLocalized)
- .withStateAndTemperature(FluidState.fromValue(aState), aTemperatureK)
- .buildAndRegister()
- .configureMaterials(aMaterial)
- .registerContainers(aFullContainer, aEmptyContainer, aFluidAmount)
+ public Fluid addFluid(String aName, String aLocalized, Materials aMaterial, int aState, int aTemperatureK,
+ ItemStack aFullContainer, ItemStack aEmptyContainer, int aFluidAmount) {
+ return GT_FluidFactory.builder(aName).withLocalizedName(aLocalized)
+ .withStateAndTemperature(FluidState.fromValue(aState), aTemperatureK).buildAndRegister()
+ .configureMaterials(aMaterial).registerContainers(aFullContainer, aEmptyContainer, aFluidAmount)
.asFluid();
}
@@ -2572,27 +2590,14 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
* @deprecated use {@link GT_FluidFactory#builder}
*/
@Deprecated
- @SuppressWarnings({"MethodWithTooManyParameters"}) // Deprecated method
- public Fluid addFluid(
- String aName,
- String aTexture,
- String aLocalized,
- Materials aMaterial,
- short[] aRGBa,
- int aState,
- int aTemperatureK,
- ItemStack aFullContainer,
- ItemStack aEmptyContainer,
- int aFluidAmount) {
- return GT_FluidFactory.builder(aName)
- .withLocalizedName(aLocalized)
+ @SuppressWarnings({ "MethodWithTooManyParameters" }) // Deprecated method
+ public Fluid addFluid(String aName, String aTexture, String aLocalized, Materials aMaterial, short[] aRGBa,
+ int aState, int aTemperatureK, ItemStack aFullContainer, ItemStack aEmptyContainer, int aFluidAmount) {
+ return GT_FluidFactory.builder(aName).withLocalizedName(aLocalized)
.withStillIconResourceLocation(new ResourceLocation(MOD_ID, "fluids/fluid." + aTexture))
- .withColorRGBA(aRGBa)
- .withStateAndTemperature(FluidState.fromValue(aState), aTemperatureK)
- .buildAndRegister()
- .configureMaterials(aMaterial)
- .registerContainers(aFullContainer, aEmptyContainer, aFluidAmount)
- .asFluid();
+ .withColorRGBA(aRGBa).withStateAndTemperature(FluidState.fromValue(aState), aTemperatureK)
+ .buildAndRegister().configureMaterials(aMaterial)
+ .registerContainers(aFullContainer, aEmptyContainer, aFluidAmount).asFluid();
}
public File getSaveDirectory() {
@@ -2612,14 +2617,12 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
GregTech_API.sUnification.mConfig.load();
GT_OreDictUnificator.resetUnificationEntries();
for (OreDictEventContainer tOre : this.mEvents) {
- if ((!(tOre.mEvent.Ore.getItem() instanceof GT_MetaGenerated_Item))
- && (tOre.mPrefix != null)
+ if ((!(tOre.mEvent.Ore.getItem() instanceof GT_MetaGenerated_Item)) && (tOre.mPrefix != null)
&& (tOre.mPrefix.mIsUnificatable)
&& (tOre.mMaterial != null)) {
boolean chkmi = tOre.mModID != null;
if (chkmi) {
- if (tOre.mModID.equalsIgnoreCase("enderio")
- && tOre.mPrefix == OrePrefixes.ingot
+ if (tOre.mModID.equalsIgnoreCase("enderio") && tOre.mPrefix == OrePrefixes.ingot
&& tOre.mMaterial == Materials.DarkSteel) {
GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
GT_OreDictUnificator.set(
@@ -2627,196 +2630,212 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
tOre.mMaterial,
tOre.mEvent.Ore,
(GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
+ new StringBuilder().append(ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
tOre.mEvent.Name,
true)),
true);
continue;
- } else if (tOre.mModID.equalsIgnoreCase("thermalfoundation")
- && tOre.mPrefix == OrePrefixes.dust
+ } else if (tOre.mModID.equalsIgnoreCase("thermalfoundation") && tOre.mPrefix == OrePrefixes.dust
&& tOre.mMaterial == Materials.Blizz) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase("thermalfoundation")
- && tOre.mPrefix == OrePrefixes.dust
- && tOre.mMaterial == Materials.Pyrotheum) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
- && tOre.mPrefix == OrePrefixes.dust
- && tOre.mMaterial == Materials.Vinteum) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
- && tOre.mPrefix == OrePrefixes.gem
- && tOre.mMaterial == Materials.BlueTopaz) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
- && tOre.mPrefix == OrePrefixes.gem
- && tOre.mMaterial == Materials.Chimerite) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
- && tOre.mPrefix == OrePrefixes.gem
- && tOre.mMaterial == Materials.Moonstone) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
- && tOre.mPrefix == OrePrefixes.gem
- && tOre.mMaterial == Materials.Sunstone) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase("rotarycraft")
- && tOre.mPrefix == OrePrefixes.ingot
- && tOre.mMaterial == Materials.HSLA) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase("appliedenergistics2")
- && tOre.mPrefix == OrePrefixes.gem
- && tOre.mMaterial == Materials.CertusQuartz) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- } else if (tOre.mModID.equalsIgnoreCase("appliedenergistics2")
- && tOre.mPrefix == OrePrefixes.dust
- && tOre.mMaterial == Materials.CertusQuartz) {
- GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
- GT_OreDictUnificator.set(
- tOre.mPrefix,
- tOre.mMaterial,
- tOre.mEvent.Ore,
- (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- true)),
- true);
- continue;
- }
+ GT_OreDictUnificator
+ .addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase("thermalfoundation") && tOre.mPrefix == OrePrefixes.dust
+ && tOre.mMaterial == Materials.Pyrotheum) {
+ GT_OreDictUnificator
+ .addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder()
+ .append(ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2) && tOre.mPrefix == OrePrefixes.dust
+ && tOre.mMaterial == Materials.Vinteum) {
+ GT_OreDictUnificator
+ .addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder()
+ .append(ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2) && tOre.mPrefix == OrePrefixes.gem
+ && tOre.mMaterial == Materials.BlueTopaz) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder()
+ .append(ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2) && tOre.mPrefix == OrePrefixes.gem
+ && tOre.mMaterial == Materials.Chimerite) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(
+ ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
+ && tOre.mPrefix == OrePrefixes.gem
+ && tOre.mMaterial == Materials.Moonstone) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(
+ ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase(aTextArsmagica2)
+ && tOre.mPrefix == OrePrefixes.gem
+ && tOre.mMaterial == Materials.Sunstone) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(
+ ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID)
+ .toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase("rotarycraft")
+ && tOre.mPrefix == OrePrefixes.ingot
+ && tOre.mMaterial == Materials.HSLA) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(
+ ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID)
+ .toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase("appliedenergistics2")
+ && tOre.mPrefix == OrePrefixes.gem
+ && tOre.mMaterial == Materials.CertusQuartz) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(
+ ConfigCategories.specialunificationtargets)
+ .append(".").append(tOre.mModID)
+ .toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ } else
+ if (tOre.mModID.equalsIgnoreCase("appliedenergistics2")
+ && tOre.mPrefix == OrePrefixes.dust
+ && tOre.mMaterial == Materials.CertusQuartz) {
+ GT_OreDictUnificator.addAssociation(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ false);
+ GT_OreDictUnificator.set(
+ tOre.mPrefix,
+ tOre.mMaterial,
+ tOre.mEvent.Ore,
+ (GregTech_API.sUnification.get(
+ new StringBuilder().append(
+ ConfigCategories.specialunificationtargets)
+ .append(".")
+ .append(tOre.mModID)
+ .toString(),
+ tOre.mEvent.Name,
+ true)),
+ true);
+ continue;
+ }
}
if (GT_OreDictUnificator.isBlacklisted(tOre.mEvent.Ore)) {
GT_OreDictUnificator.addAssociation(tOre.mPrefix, tOre.mMaterial, tOre.mEvent.Ore, true);
@@ -2826,22 +2845,17 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
tOre.mPrefix,
tOre.mMaterial,
tOre.mEvent.Ore,
- (chkmi)
- && (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID)
- .toString(),
- tOre.mEvent.Name,
- false)),
+ (chkmi) && (GregTech_API.sUnification.get(
+ new StringBuilder().append(ConfigCategories.specialunificationtargets).append(".")
+ .append(tOre.mModID).toString(),
+ tOre.mEvent.Name,
+ false)),
true);
}
}
}
for (OreDictEventContainer tOre : this.mEvents) {
- if (((tOre.mEvent.Ore.getItem() instanceof GT_MetaGenerated_Item))
- && (tOre.mPrefix != null)
+ if (((tOre.mEvent.Ore.getItem() instanceof GT_MetaGenerated_Item)) && (tOre.mPrefix != null)
&& (tOre.mPrefix.mIsUnificatable)
&& (tOre.mMaterial != null)) {
if (GT_OreDictUnificator.isBlacklisted(tOre.mEvent.Ore)) {
@@ -2852,14 +2866,11 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
tOre.mPrefix,
tOre.mMaterial,
tOre.mEvent.Ore,
- (tOre.mModID != null)
- && (GregTech_API.sUnification.get(
- new StringBuilder()
- .append(ConfigCategories.specialunificationtargets)
- .append(".")
- .append(tOre.mModID),
- tOre.mEvent.Name,
- false)),
+ (tOre.mModID != null) && (GregTech_API.sUnification.get(
+ new StringBuilder().append(ConfigCategories.specialunificationtargets).append(".")
+ .append(tOre.mModID),
+ tOre.mEvent.Name,
+ false)),
true);
}
}
@@ -2885,27 +2896,27 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
}
@Deprecated
- public static final HashMap<Integer, HashMap<ChunkCoordIntPair, int[]>> dimensionWiseChunkData =
- new HashMap<>(16); // stores chunk data that is loaded/saved
-
- public static final HashMap<Integer, GT_Pollution> dimensionWisePollution =
- new HashMap<>(16); // stores GT_Polluttors objects
- public static final byte GTOIL = 3,
- GTOILFLUID = 2,
- GTPOLLUTION = 1,
- GTMETADATA = 0,
- NOT_LOADED = 0,
- LOADED = 1; // consts
+ public static final HashMap<Integer, HashMap<ChunkCoordIntPair, int[]>> dimensionWiseChunkData = new HashMap<>(16); // stores
+ // chunk
+ // data
+ // that
+ // is
+ // loaded/saved
+
+ public static final HashMap<Integer, GT_Pollution> dimensionWisePollution = new HashMap<>(16); // stores
+ // GT_Polluttors
+ // objects
+ public static final byte GTOIL = 3, GTOILFLUID = 2, GTPOLLUTION = 1, GTMETADATA = 0, NOT_LOADED = 0, LOADED = 1; // consts
// TO get default's fast
@Deprecated
public static int[] getDefaultChunkDataOnCreation() {
- return new int[] {NOT_LOADED, 0, -1, -1};
+ return new int[] { NOT_LOADED, 0, -1, -1 };
}
@Deprecated
public static int[] getDefaultChunkDataOnLoad() {
- return new int[] {LOADED, 0, -1, -1};
+ return new int[] { LOADED, 0, -1, -1 };
}
@SubscribeEvent
@@ -2920,30 +2931,30 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler, IG
if (aEvent.entityPlayer != null) {
ItemStack aStack = aEvent.entityPlayer.getCurrentEquippedItem();
if ((aStack != null) && ((aStack.getItem() instanceof GT_MetaGenerated_Tool))) {
- aEvent.newSpeed = ((GT_MetaGenerated_Tool) aStack.getItem())
- .onBlockBreakSpeedEvent(
- aEvent.newSpeed,
- aStack,
- aEvent.entityPlayer,
- aEvent.block,
- aEvent.x,
- aEvent.y,
- aEvent.z,
- (byte) aEvent.metadata,
- aEvent);
+ aEvent.newSpeed = ((GT_MetaGenerated_Tool) aStack.getItem()).onBlockBreakSpeedEvent(
+ aEvent.newSpeed,
+ aStack,
+ aEvent.entityPlayer,
+ aEvent.block,
+ aEvent.x,
+ aEvent.y,
+ aEvent.z,
+ (byte) aEvent.metadata,
+ aEvent);
}
}
}
}
public static class OreDictEventContainer {
+
public final OreDictionary.OreRegisterEvent mEvent;
public final OrePrefixes mPrefix;
public final Materials mMaterial;
public final String mModID;
- public OreDictEventContainer(
- OreDictionary.OreRegisterEvent aEvent, OrePrefixes aPrefix, Materials aMaterial, String aModID) {
+ public OreDictEventContainer(OreDictionary.OreRegisterEvent aEvent, OrePrefixes aPrefix, Materials aMaterial,
+ String aModID) {
this.mEvent = aEvent;
this.mPrefix = aPrefix;
this.mMaterial = aMaterial;
diff --git a/src/main/java/gregtech/common/GT_RecipeAdder.java b/src/main/java/gregtech/common/GT_RecipeAdder.java
index 1d0b4795fe..06734de49e 100644
--- a/src/main/java/gregtech/common/GT_RecipeAdder.java
+++ b/src/main/java/gregtech/common/GT_RecipeAdder.java
@@ -3,6 +3,22 @@ package gregtech.common;
import static gregtech.GT_Mod.GT_FML_LOGGER;
import static gregtech.api.enums.GT_Values.MOD_ID_GTPP;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Comparator;
+import java.util.List;
+import java.util.Objects;
+
+import mods.railcraft.common.blocks.aesthetics.cube.EnumCube;
+import mods.railcraft.common.items.RailcraftToolItems;
+
+import net.minecraft.init.Blocks;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.oredict.OreDictionary;
+
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.registry.GameRegistry;
import gregtech.GT_Mod;
@@ -19,52 +35,38 @@ import gregtech.api.util.GT_Recipe.GT_Recipe_AssemblyLine;
import gregtech.common.items.GT_IntegratedCircuit_Item;
import ic2.core.init.MainConfig;
import ic2.core.util.ConfigUtil;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.List;
-import java.util.Objects;
-import mods.railcraft.common.blocks.aesthetics.cube.EnumCube;
-import mods.railcraft.common.items.RailcraftToolItems;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.oredict.OreDictionary;
public class GT_RecipeAdder implements IGT_RecipeAdder {
@Override
@Deprecated
- public boolean addFusionReactorRecipe(
- ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, int aEUt, int aStartEU) {
+ public boolean addFusionReactorRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration,
+ int aEUt, int aStartEU) {
return false;
}
@Override // Really?
- public boolean addFusionReactorRecipe(
- FluidStack aInput1, FluidStack aInput2, FluidStack aOutput1, int aDuration, int aEUt, int aStartEU) {
+ public boolean addFusionReactorRecipe(FluidStack aInput1, FluidStack aInput2, FluidStack aOutput1, int aDuration,
+ int aEUt, int aStartEU) {
if (aInput1 == null || aInput2 == null || aOutput1 == null || aDuration < 1 || aEUt < 1 || aStartEU < 1) {
return false;
}
- if ((aDuration = GregTech_API.sRecipeFile.get(
- "fusion", aOutput1.getFluid().getName(), aDuration))
- <= 0) {
+ if ((aDuration = GregTech_API.sRecipeFile.get("fusion", aOutput1.getFluid().getName(), aDuration)) <= 0) {
return false;
}
GT_Recipe.GT_Recipe_Map.sFusionRecipes.addRecipe(
- null, new FluidStack[] {aInput1, aInput2}, new FluidStack[] {aOutput1}, aDuration, aEUt, aStartEU);
+ null,
+ new FluidStack[] { aInput1, aInput2 },
+ new FluidStack[] { aOutput1 },
+ aDuration,
+ aEUt,
+ aStartEU);
return true;
}
@Override
- public boolean addFusionReactorRecipe(
- FluidStack[] FluidInputArray,
- FluidStack[] FluidOutputArray,
- int aFusionDurationInTicks,
- int aFusionEnergyPerTick,
- int aEnergyNeededForStartingFusion) {
+ public boolean addFusionReactorRecipe(FluidStack[] FluidInputArray, FluidStack[] FluidOutputArray,
+ int aFusionDurationInTicks, int aFusionEnergyPerTick, int aEnergyNeededForStartingFusion) {
if (FluidInputArray.length == 0) return false;
if (FluidOutputArray.length == 0) return false;
@@ -93,16 +95,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCentrifugeRecipe(
- ItemStack aInput1,
- int aInput2,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- ItemStack aOutput5,
- ItemStack aOutput6,
- int aDuration) {
+ public boolean addCentrifugeRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, ItemStack aOutput4, ItemStack aOutput5, ItemStack aOutput6, int aDuration) {
return addCentrifugeRecipe(
aInput1,
aInput2 < 0 ? null : aInput2 > 0 ? ItemList.Cell_Empty.get(aInput2) : null,
@@ -120,17 +114,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCentrifugeRecipe(
- ItemStack aInput1,
- int aInput2,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- ItemStack aOutput5,
- ItemStack aOutput6,
- int aDuration,
- int aEUt) {
+ public boolean addCentrifugeRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, ItemStack aOutput4, ItemStack aOutput5, ItemStack aOutput6, int aDuration, int aEUt) {
return addCentrifugeRecipe(
aInput1,
aInput2 < 0 ? null : aInput2 > 0 ? ItemList.Cell_Empty.get(aInput2) : null,
@@ -148,20 +133,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCentrifugeRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- ItemStack aOutput5,
- ItemStack aOutput6,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addCentrifugeRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, ItemStack aOutput4,
+ ItemStack aOutput5, ItemStack aOutput6, int[] aChances, int aDuration, int aEUt) {
return addCentrifugeRecipe(
aInput1,
aInput2,
@@ -180,31 +154,17 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCentrifugeRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- ItemStack aOutput5,
- ItemStack aOutput6,
- int[] aChances,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addCentrifugeRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, ItemStack aOutput4,
+ ItemStack aOutput5, ItemStack aOutput6, int[] aChances, int aDuration, int aEUt, boolean aCleanroom) {
if (((aInput1 == null) && (aFluidInput == null)) || ((aOutput1 == null) && (aFluidOutput == null))) {
return false;
}
if ((aInput1 != null) && ((aDuration = GregTech_API.sRecipeFile.get("centrifuge", aInput1, aDuration)) <= 0)) {
return false;
}
- if ((aFluidInput != null)
- && ((aDuration = GregTech_API.sRecipeFile.get(
- "centrifuge", aFluidInput.getFluid().getName(), aDuration))
- <= 0)) {
+ if ((aFluidInput != null) && ((aDuration = GregTech_API.sRecipeFile
+ .get("centrifuge", aFluidInput.getFluid().getName(), aDuration)) <= 0)) {
return false;
}
if (!GT_Mod.gregtechproxy.mEnableCleanroom) {
@@ -212,21 +172,19 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sCentrifugeRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2},
- new ItemStack[] {
- aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6,
- },
+ new ItemStack[] { aInput1, aInput2 },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6, },
null,
aChances,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
aCleanroom ? -100 : 0);
- ItemStack[] itemInputs = {aInput1, aInput2};
- ItemStack[] itemOutputs = {aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6};
- FluidStack[] fluidInputs = {aFluidInput, null, null};
- FluidStack[] fluidOutputs = {aFluidOutput, null, null, null, null, null, null};
+ ItemStack[] itemInputs = { aInput1, aInput2 };
+ ItemStack[] itemOutputs = { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6 };
+ FluidStack[] fluidInputs = { aFluidInput, null, null };
+ FluidStack[] fluidOutputs = { aFluidOutput, null, null, null, null, null, null };
byte iNumber = 0;
byte oNumber = 0;
@@ -274,22 +232,21 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe.GT_Recipe_Map.sCompressorRecipes.addRecipe(
- true, new ItemStack[] {aInput1}, new ItemStack[] {aOutput1}, null, null, null, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aInput1 },
+ new ItemStack[] { aOutput1 },
+ null,
+ null,
+ null,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@Override
- public boolean addElectrolyzerRecipe(
- ItemStack aInput1,
- int aInput2,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- ItemStack aOutput5,
- ItemStack aOutput6,
- int aDuration,
- int aEUt) {
+ public boolean addElectrolyzerRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, ItemStack aOutput4, ItemStack aOutput5, ItemStack aOutput6, int aDuration, int aEUt) {
return addElectrolyzerRecipe(
aInput1,
aInput2 < 0 ? null : aInput2 > 0 ? ItemList.Cell_Empty.get(aInput2) : null,
@@ -307,20 +264,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addElectrolyzerRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- ItemStack aOutput5,
- ItemStack aOutput6,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addElectrolyzerRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, ItemStack aOutput4,
+ ItemStack aOutput5, ItemStack aOutput6, int[] aChances, int aDuration, int aEUt) {
if (((aInput1 == null) && (aFluidInput == null)) || ((aOutput1 == null) && (aFluidOutput == null))) {
return false;
}
@@ -328,35 +274,32 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
&& ((aDuration = GregTech_API.sRecipeFile.get("electrolyzer", aInput1, aDuration)) <= 0)) {
return false;
}
- if ((aFluidInput != null)
- && ((aDuration = GregTech_API.sRecipeFile.get(
- "electrolyzer", aFluidInput.getFluid().getName(), aDuration))
- <= 0)) {
+ if ((aFluidInput != null) && ((aDuration = GregTech_API.sRecipeFile
+ .get("electrolyzer", aFluidInput.getFluid().getName(), aDuration)) <= 0)) {
return false;
}
GT_Recipe.GT_Recipe_Map.sElectrolyzerRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2},
- new ItemStack[] {aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6},
+ new ItemStack[] { aInput1, aInput2 },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6 },
null,
aChances,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
0);
- ItemStack[] itemInputs = {aInput1, aInput2};
- ItemStack[] itemOutputs = {aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6};
- FluidStack[] fluidInputs = {aFluidInput, null, null};
- FluidStack[] fluidOutputs = {aFluidOutput, null, null, null, null, null, null};
+ ItemStack[] itemInputs = { aInput1, aInput2 };
+ ItemStack[] itemOutputs = { aOutput1, aOutput2, aOutput3, aOutput4, aOutput5, aOutput6 };
+ FluidStack[] fluidInputs = { aFluidInput, null, null };
+ FluidStack[] fluidOutputs = { aFluidOutput, null, null, null, null, null, null };
byte iNumber = 0;
byte oNumber = 0;
for (ItemStack item : itemInputs) {
if (item != null) {
- if (GT_Utility.getFluidForFilledItem(aInput1, true) != null
- || GT_Utility.isCellEmpty(item)
+ if (GT_Utility.getFluidForFilledItem(aInput1, true) != null || GT_Utility.isCellEmpty(item)
|| GT_Utility.checkIfSameIntegratedCircuit(item)) {
fluidInputs[iNumber + 1] = GT_Utility.convertCellToFluid(item);
itemInputs[iNumber] = null;
@@ -376,7 +319,16 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sMultiblockElectrolyzerRecipes.addRecipe(
- false, itemInputs, itemOutputs, null, aChances, fluidInputs, fluidOutputs, aDuration, aEUt, 0);
+ false,
+ itemInputs,
+ itemOutputs,
+ null,
+ aChances,
+ fluidInputs,
+ fluidOutputs,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@@ -391,65 +343,49 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addChemicalRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- int aDuration) {
+ public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput, int aDuration) {
return addChemicalRecipe(aInput1, aInput2, aFluidInput, aFluidOutput, aOutput, aDuration, 30);
}
@Override
- public boolean addChemicalRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- ItemStack aOutput2,
- int aDuration) {
+ public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration) {
return addChemicalRecipe(aInput1, aInput2, aFluidInput, aFluidOutput, aOutput, aOutput2, aDuration, 30);
}
@Override
- public boolean addChemicalRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- int aDuration,
- int aEUTick) {
+ public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput, int aDuration, int aEUTick) {
return addChemicalRecipe(
- aInput1, aInput2, aFluidInput, aFluidOutput, aOutput, GT_Values.NI, aDuration, aEUTick);
+ aInput1,
+ aInput2,
+ aFluidInput,
+ aFluidOutput,
+ aOutput,
+ GT_Values.NI,
+ aDuration,
+ aEUTick);
}
@Override
- public boolean addChemicalRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- ItemStack aOutput2,
- int aDuration,
- int aEUtick) {
+ public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration, int aEUtick) {
return addChemicalRecipe(
- aInput1, aInput2, aFluidInput, aFluidOutput, aOutput, aOutput2, aDuration, aEUtick, false);
+ aInput1,
+ aInput2,
+ aFluidInput,
+ aFluidOutput,
+ aOutput,
+ aOutput2,
+ aDuration,
+ aEUtick,
+ false);
}
@Override
- public boolean addChemicalRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- ItemStack aOutput2,
- int aDuration,
- int aEUtick,
+ public boolean addChemicalRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration, int aEUtick,
boolean aCleanroom) {
if (((aInput1 == null) && (aFluidInput == null))
|| ((aOutput == null) && (aOutput2 == null) && (aFluidOutput == null))) {
@@ -459,10 +395,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
&& ((aDuration = GregTech_API.sRecipeFile.get("chemicalreactor", aOutput, aDuration)) <= 0)) {
return false;
}
- if ((aFluidOutput != null)
- && ((aDuration = GregTech_API.sRecipeFile.get(
- "chemicalreactor", aFluidOutput.getFluid().getName(), aDuration))
- <= 0)) {
+ if ((aFluidOutput != null) && ((aDuration = GregTech_API.sRecipeFile
+ .get("chemicalreactor", aFluidOutput.getFluid().getName(), aDuration)) <= 0)) {
return false;
}
if (aEUtick <= 0) {
@@ -473,29 +407,27 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sChemicalRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2},
- new ItemStack[] {aOutput, aOutput2},
+ new ItemStack[] { aInput1, aInput2 },
+ new ItemStack[] { aOutput, aOutput2 },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUtick,
aCleanroom ? -200 : 0);
- if (!(aInput1 != null
- && aInput1.getItem() instanceof GT_IntegratedCircuit_Item
- && aInput1.getItemDamage() >= 10)
- && !(aInput2 != null
- && aInput2.getItem() instanceof GT_IntegratedCircuit_Item
+ if (!(aInput1 != null && aInput1.getItem() instanceof GT_IntegratedCircuit_Item
+ && aInput1.getItemDamage() >= 10)
+ && !(aInput2 != null && aInput2.getItem() instanceof GT_IntegratedCircuit_Item
&& aInput2.getItemDamage() >= 10)) {
GT_Recipe.GT_Recipe_Map.sMultiblockChemicalRecipes.addRecipe(
false,
- new ItemStack[] {aInput1, aInput2},
- new ItemStack[] {aOutput, aOutput2},
+ new ItemStack[] { aInput1, aInput2 },
+ new ItemStack[] { aOutput, aOutput2 },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUtick,
0);
@@ -504,34 +436,22 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addMultiblockChemicalRecipe(
- ItemStack[] aInputs,
- FluidStack[] aFluidInputs,
- FluidStack[] aFluidOutputs,
- ItemStack[] aOutputs,
- int aDuration,
- int aEUtick) {
+ public boolean addMultiblockChemicalRecipe(ItemStack[] aInputs, FluidStack[] aFluidInputs,
+ FluidStack[] aFluidOutputs, ItemStack[] aOutputs, int aDuration, int aEUtick) {
if (areItemsAndFluidsBothNull(aInputs, aFluidInputs) || areItemsAndFluidsBothNull(aOutputs, aFluidOutputs)) {
return false;
}
if (aEUtick <= 0) {
return false;
}
- GT_Recipe.GT_Recipe_Map.sMultiblockChemicalRecipes.addRecipe(
- false, aInputs, aOutputs, null, null, aFluidInputs, aFluidOutputs, aDuration, aEUtick, 0);
+ GT_Recipe.GT_Recipe_Map.sMultiblockChemicalRecipes
+ .addRecipe(false, aInputs, aOutputs, null, null, aFluidInputs, aFluidOutputs, aDuration, aEUtick, 0);
return true;
}
@Override
- public boolean addChemicalRecipeForBasicMachineOnly(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- ItemStack aOutput2,
- int aDuration,
- int aEUtick) {
+ public boolean addChemicalRecipeForBasicMachineOnly(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput,
+ FluidStack aFluidOutput, ItemStack aOutput, ItemStack aOutput2, int aDuration, int aEUtick) {
if (((aInput1 == null) && (aFluidInput == null))
|| ((aOutput == null) && (aOutput2 == null) && (aFluidOutput == null))) {
return false;
@@ -540,10 +460,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
&& ((aDuration = GregTech_API.sRecipeFile.get("chemicalreactor", aOutput, aDuration)) <= 0)) {
return false;
}
- if ((aFluidOutput != null)
- && ((aDuration = GregTech_API.sRecipeFile.get(
- "chemicalreactor", aFluidOutput.getFluid().getName(), aDuration))
- <= 0)) {
+ if ((aFluidOutput != null) && ((aDuration = GregTech_API.sRecipeFile
+ .get("chemicalreactor", aFluidOutput.getFluid().getName(), aDuration)) <= 0)) {
return false;
}
if (aEUtick <= 0) {
@@ -551,12 +469,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sChemicalRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2},
- new ItemStack[] {aOutput, aOutput2},
+ new ItemStack[] { aInput1, aInput2 },
+ new ItemStack[] { aOutput, aOutput2 },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUtick,
0);
@@ -595,52 +513,32 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
Materials.Empty.getCells(1),
1120);
addMultiblockChemicalRecipe(
- new ItemStack[] {GT_Utility.getIntegratedCircuit(2)},
- new FluidStack[] {
- new GT_FluidStack(aBasicMaterial, 2160),
- Materials.Air.getGas(7500),
- Materials.Titaniumtetrachloride.getFluid(100)
- },
- new FluidStack[] {new GT_FluidStack(aPolymer, 3240)},
+ new ItemStack[] { GT_Utility.getIntegratedCircuit(2) },
+ new FluidStack[] { new GT_FluidStack(aBasicMaterial, 2160), Materials.Air.getGas(7500),
+ Materials.Titaniumtetrachloride.getFluid(100) },
+ new FluidStack[] { new GT_FluidStack(aPolymer, 3240) },
null,
800,
30);
addMultiblockChemicalRecipe(
- new ItemStack[] {GT_Utility.getIntegratedCircuit(2)},
- new FluidStack[] {
- new GT_FluidStack(aBasicMaterial, 2160),
- Materials.Oxygen.getGas(7500),
- Materials.Titaniumtetrachloride.getFluid(100)
- },
- new FluidStack[] {new GT_FluidStack(aPolymer, 4320)},
+ new ItemStack[] { GT_Utility.getIntegratedCircuit(2) },
+ new FluidStack[] { new GT_FluidStack(aBasicMaterial, 2160), Materials.Oxygen.getGas(7500),
+ Materials.Titaniumtetrachloride.getFluid(100) },
+ new FluidStack[] { new GT_FluidStack(aPolymer, 4320) },
null,
800,
30);
}
@Override
- public boolean addBlastRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aOutput1,
- ItemStack aOutput2,
- int aDuration,
- int aEUt,
- int aLevel) {
+ public boolean addBlastRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt, int aLevel) {
return addBlastRecipe(aInput1, aInput2, null, null, aOutput1, aOutput2, aDuration, aEUt, aLevel);
}
@Override
- public boolean addBlastRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- int aDuration,
- int aEUt,
- int aLevel) {
+ public boolean addBlastRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, FluidStack aFluidOutput,
+ ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt, int aLevel) {
if ((aInput1 == null) || (aOutput1 == null)) {
return false;
}
@@ -649,32 +547,21 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput1, aInput2 },
+ new ItemStack[] { aOutput1, aOutput2 },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
aLevel);
return true;
}
- public boolean addBlastRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aInput3,
- ItemStack aInput4,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- int aDuration,
- int aEUt,
- int aLevel) {
+ public boolean addBlastRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aInput3, ItemStack aInput4,
+ FluidStack aFluidInput, FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3,
+ ItemStack aOutput4, int aDuration, int aEUt, int aLevel) {
if ((aInput1 == null) || (aOutput1 == null)) {
return false;
}
@@ -683,12 +570,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, aInput3, aInput4},
- new ItemStack[] {aOutput1, aOutput2, aOutput3, aOutput4},
+ new ItemStack[] { aInput1, aInput2, aInput3, aInput4 },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4 },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
aLevel);
@@ -696,14 +583,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addPlasmaForgeRecipe(
- ItemStack[] ItemInputArray,
- FluidStack[] FluidInputArray,
- ItemStack[] OutputItemArray,
- FluidStack[] FluidOutputArray,
- int aDuration,
- int aEUt,
- int coil_heat_level) {
+ public boolean addPlasmaForgeRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray,
+ ItemStack[] OutputItemArray, FluidStack[] FluidOutputArray, int aDuration, int aEUt, int coil_heat_level) {
GT_Recipe.GT_Recipe_Map.sPlasmaForgeRecipes.addRecipe(
false,
ItemInputArray,
@@ -719,13 +600,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addPrimitiveBlastRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- int aCoalAmount,
- ItemStack aOutput1,
- ItemStack aOutput2,
- int aDuration) {
+ public boolean addPrimitiveBlastRecipe(ItemStack aInput1, ItemStack aInput2, int aCoalAmount, ItemStack aOutput1,
+ ItemStack aOutput2, int aDuration) {
if ((aInput1 == null && aInput2 == null) || (aOutput1 == null && aOutput2 == null)) {
return false;
}
@@ -735,12 +611,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if ((aDuration = GregTech_API.sRecipeFile.get("primitiveblastfurnace", aInput1, aDuration)) <= 0) {
return false;
}
- Materials[] coals = new Materials[] {Materials.Coal, Materials.Charcoal};
+ Materials[] coals = new Materials[] { Materials.Coal, Materials.Charcoal };
for (Materials coal : coals) {
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, coal.getGems(aCoalAmount)},
- new ItemStack[] {aOutput1, aOutput2, Materials.DarkAsh.getDustTiny(aCoalAmount)},
+ new ItemStack[] { aInput1, aInput2, coal.getGems(aCoalAmount) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDustTiny(aCoalAmount) },
null,
null,
null,
@@ -750,8 +626,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
0);
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, coal.getDust(aCoalAmount)},
- new ItemStack[] {aOutput1, aOutput2, Materials.DarkAsh.getDustTiny(aCoalAmount)},
+ new ItemStack[] { aInput1, aInput2, coal.getDust(aCoalAmount) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDustTiny(aCoalAmount) },
null,
null,
null,
@@ -763,8 +639,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if (Loader.isModLoaded("Railcraft")) {
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, RailcraftToolItems.getCoalCoke(aCoalAmount / 2)},
- new ItemStack[] {aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount / 2)},
+ new ItemStack[] { aInput1, aInput2, RailcraftToolItems.getCoalCoke(aCoalAmount / 2) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount / 2) },
null,
null,
null,
@@ -776,10 +652,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if (Loader.isModLoaded(MOD_ID_GTPP)) {
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {
- aInput1, aInput2, GT_ModHandler.getModItem(MOD_ID_GTPP, "itemCactusCoke", (aCoalAmount * 2L))
- },
- new ItemStack[] {aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount * 2)},
+ new ItemStack[] { aInput1, aInput2,
+ GT_ModHandler.getModItem(MOD_ID_GTPP, "itemCactusCoke", (aCoalAmount * 2L)) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount * 2) },
null,
null,
null,
@@ -789,10 +664,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
0);
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {
- aInput1, aInput2, GT_ModHandler.getModItem(MOD_ID_GTPP, "itemSugarCoke", (aCoalAmount * 2L))
- },
- new ItemStack[] {aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount * 2)},
+ new ItemStack[] { aInput1, aInput2,
+ GT_ModHandler.getModItem(MOD_ID_GTPP, "itemSugarCoke", (aCoalAmount * 2L)) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDustTiny(aCoalAmount * 2) },
null,
null,
null,
@@ -801,8 +675,7 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
0,
0);
}
- if ((aInput1 == null || aInput1.stackSize <= 6)
- && (aInput2 == null || aInput2.stackSize <= 6)
+ if ((aInput1 == null || aInput1.stackSize <= 6) && (aInput2 == null || aInput2.stackSize <= 6)
&& (aOutput1 == null || aOutput1.stackSize <= 6)
&& (aOutput2 == null || aOutput2.stackSize <= 6)) {
aInput1 = aInput1 == null ? null : GT_Utility.copyAmount(aInput1.stackSize * 10L, aInput1);
@@ -812,8 +685,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
for (Materials coal : coals) {
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, coal.getBlocks(aCoalAmount)},
- new ItemStack[] {aOutput1, aOutput2, Materials.DarkAsh.getDust(aCoalAmount)},
+ new ItemStack[] { aInput1, aInput2, coal.getBlocks(aCoalAmount) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDust(aCoalAmount) },
null,
null,
null,
@@ -823,8 +696,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
0);
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, coal.getBlocks(aCoalAmount)},
- new ItemStack[] {aOutput1, aOutput2, Materials.DarkAsh.getDust(aCoalAmount)},
+ new ItemStack[] { aInput1, aInput2, coal.getBlocks(aCoalAmount) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.DarkAsh.getDust(aCoalAmount) },
null,
null,
null,
@@ -836,8 +709,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if (Loader.isModLoaded("Railcraft")) {
GT_Recipe.GT_Recipe_Map.sPrimitiveBlastRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, EnumCube.COKE_BLOCK.getItem(aCoalAmount / 2)},
- new ItemStack[] {aOutput1, aOutput2, Materials.Ash.getDust(aCoalAmount / 2)},
+ new ItemStack[] { aInput1, aInput2, EnumCube.COKE_BLOCK.getItem(aCoalAmount / 2) },
+ new ItemStack[] { aOutput1, aOutput2, Materials.Ash.getDust(aCoalAmount / 2) },
null,
null,
null,
@@ -851,8 +724,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCannerRecipe(
- ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt) {
+ public boolean addCannerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt) {
if ((aInput1 == null) || (aOutput1 == null)) {
return false;
}
@@ -864,21 +737,19 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAlloySmelterRecipe(
- ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, int aEUt) {
+ public boolean addAlloySmelterRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration,
+ int aEUt) {
return addAlloySmelterRecipe(aInput1, aInput2, aOutput1, aDuration, aEUt, false);
}
@Override
- public boolean addAlloySmelterRecipe(
- ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, int aEUt, boolean hidden) {
+ public boolean addAlloySmelterRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration,
+ int aEUt, boolean hidden) {
if ((aInput1 == null) || (aOutput1 == null || Materials.Graphite.contains(aInput1))) {
return false;
}
- if ((aInput2 == null)
- && ((OrePrefixes.ingot.contains(aInput1))
- || (OrePrefixes.dust.contains(aInput1))
- || (OrePrefixes.gem.contains(aInput1)))) {
+ if ((aInput2 == null) && ((OrePrefixes.ingot.contains(aInput1)) || (OrePrefixes.dust.contains(aInput1))
+ || (OrePrefixes.gem.contains(aInput1)))) {
return false;
}
if ((aDuration = GregTech_API.sRecipeFile.get("alloysmelting", aInput2 == null ? aInput1 : aOutput1, aDuration))
@@ -914,8 +785,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCutterRecipe(
- ItemStack aInput, FluidStack aLubricant, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt) {
+ public boolean addCutterRecipe(ItemStack aInput, FluidStack aLubricant, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt) {
if ((aInput == null) || (aLubricant == null) || (aOutput1 == null)) {
return false;
}
@@ -924,10 +795,10 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sCutterRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2 },
null,
- new FluidStack[] {aLubricant},
+ new FluidStack[] { aLubricant },
null,
aDuration,
aEUt,
@@ -936,26 +807,26 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCutterRecipe(
- ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt, boolean aCleanroom) {
+ public boolean addCutterRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt,
+ boolean aCleanroom) {
return addCutterRecipe(aInput, null, aOutput1, aOutput2, aDuration, aEUt, aCleanroom);
}
- public boolean addCutterRecipe(
- ItemStack aInput, int aCircuit, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt) {
+ public boolean addCutterRecipe(ItemStack aInput, int aCircuit, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt) {
return addCutterRecipe(aInput, aCircuit, aOutput1, aOutput2, aDuration, aEUt, false);
}
- public boolean addCutterRecipe(
- ItemStack aInput,
- int aCircuit,
- ItemStack aOutput1,
- ItemStack aOutput2,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addCutterRecipe(ItemStack aInput, int aCircuit, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt, boolean aCleanroom) {
return addCutterRecipe(
- aInput, GT_Utility.getIntegratedCircuit(aCircuit), aOutput1, aOutput2, aDuration, aEUt, aCleanroom);
+ aInput,
+ GT_Utility.getIntegratedCircuit(aCircuit),
+ aOutput1,
+ aOutput2,
+ aDuration,
+ aEUt,
+ aCleanroom);
}
@Override
@@ -964,30 +835,24 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCutterRecipe(
- ItemStack aInput, ItemStack aCircuit, ItemStack aOutput1, ItemStack aOutput2, int aDuration, int aEUt) {
+ public boolean addCutterRecipe(ItemStack aInput, ItemStack aCircuit, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt) {
return addCutterRecipe(aInput, aCircuit, aOutput1, aOutput2, aDuration, aEUt, false);
}
@Override
- public boolean addCutterRecipe(
- ItemStack aInput,
- ItemStack aCircuit,
- ItemStack aOutput1,
- ItemStack aOutput2,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addCutterRecipe(ItemStack aInput, ItemStack aCircuit, ItemStack aOutput1, ItemStack aOutput2,
+ int aDuration, int aEUt, boolean aCleanroom) {
return addCutterRecipe(
- new ItemStack[] {aInput, aCircuit},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput, aCircuit },
+ new ItemStack[] { aOutput1, aOutput2 },
aDuration,
aEUt,
aCleanroom ? -200 : 0);
}
- public boolean addCutterRecipe(
- ItemStack[] aInputs, ItemStack[] aOutputs, int aDuration, int aEUt, boolean aCleanroom) {
+ public boolean addCutterRecipe(ItemStack[] aInputs, ItemStack[] aOutputs, int aDuration, int aEUt,
+ boolean aCleanroom) {
return addCutterRecipe(aInputs, aOutputs, aDuration, aEUt, aCleanroom ? -200 : 0);
}
@@ -1010,7 +875,7 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
aInputs,
aOutputs,
null,
- new FluidStack[] {Materials.Water.getFluid(Math.max(4, Math.min(1000, aDuration * aEUt / 320)))},
+ new FluidStack[] { Materials.Water.getFluid(Math.max(4, Math.min(1000, aDuration * aEUt / 320))) },
null,
aDuration * 2,
aEUt,
@@ -1020,7 +885,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
aInputs,
aOutputs,
null,
- new FluidStack[] {GT_ModHandler.getDistilledWater(Math.max(3, Math.min(750, aDuration * aEUt / 426)))},
+ new FluidStack[] {
+ GT_ModHandler.getDistilledWater(Math.max(3, Math.min(750, aDuration * aEUt / 426))) },
null,
aDuration * 2,
aEUt,
@@ -1030,7 +896,7 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
aInputs,
aOutputs,
null,
- new FluidStack[] {Materials.Lubricant.getFluid(Math.max(1, Math.min(250, aDuration * aEUt / 1280)))},
+ new FluidStack[] { Materials.Lubricant.getFluid(Math.max(1, Math.min(250, aDuration * aEUt / 1280))) },
null,
aDuration,
aEUt,
@@ -1039,31 +905,23 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack aInput1,
- Object aOreDict,
- int aAmount,
- FluidStack aFluidInput,
- ItemStack aOutput1,
- int aDuration,
- int aEUt) {
+ public boolean addAssemblerRecipe(ItemStack aInput1, Object aOreDict, int aAmount, FluidStack aFluidInput,
+ ItemStack aOutput1, int aDuration, int aEUt) {
for (ItemStack tStack : GT_OreDictUnificator.getOresImmutable(aOreDict)) {
- if (GT_Utility.isStackValid(tStack))
- addAssemblerRecipe(
- aInput1, GT_Utility.copyAmount(aAmount, tStack), aFluidInput, aOutput1, aDuration, aEUt);
+ if (GT_Utility.isStackValid(tStack)) addAssemblerRecipe(
+ aInput1,
+ GT_Utility.copyAmount(aAmount, tStack),
+ aFluidInput,
+ aOutput1,
+ aDuration,
+ aEUt);
}
return true;
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack[] aInputs,
- Object aOreDict,
- int aAmount,
- FluidStack aFluidInput,
- ItemStack aOutput1,
- int aDuration,
- int aEUt) {
+ public boolean addAssemblerRecipe(ItemStack[] aInputs, Object aOreDict, int aAmount, FluidStack aFluidInput,
+ ItemStack aOutput1, int aDuration, int aEUt) {
for (ItemStack tStack : GT_OreDictUnificator.getOresImmutable(aOreDict)) {
if (GT_Utility.isStackValid(tStack)) {
ItemStack[] extendedInputs = new ItemStack[aInputs.length + 1];
@@ -1076,49 +934,48 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration, int aEUt) {
+ public boolean addAssemblerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, int aDuration,
+ int aEUt) {
return addAssemblerRecipe(
- new ItemStack[] {aInput1, aInput2 == null ? aInput1 : aInput2}, null, aOutput1, aDuration, aEUt, false);
+ new ItemStack[] { aInput1, aInput2 == null ? aInput1 : aInput2 },
+ null,
+ aOutput1,
+ aDuration,
+ aEUt,
+ false);
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, ItemStack aOutput1, int aDuration, int aEUt) {
- return addAssemblerRecipe(new ItemStack[] {aInput1, aInput2}, aFluidInput, aOutput1, aDuration, aEUt);
+ public boolean addAssemblerRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, ItemStack aOutput1,
+ int aDuration, int aEUt) {
+ return addAssemblerRecipe(new ItemStack[] { aInput1, aInput2 }, aFluidInput, aOutput1, aDuration, aEUt);
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1, int aDuration, int aEUt) {
+ public boolean addAssemblerRecipe(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1, int aDuration,
+ int aEUt) {
return addAssemblerRecipe(aInputs, aFluidInput, aOutput1, aDuration, aEUt, false);
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- FluidStack aFluidInput,
- ItemStack aOutput1,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAssemblerRecipe(ItemStack aInput1, ItemStack aInput2, FluidStack aFluidInput, ItemStack aOutput1,
+ int aDuration, int aEUt, boolean aCleanroom) {
if (aInput2 == null)
- return addAssemblerRecipe(new ItemStack[] {aInput1}, aFluidInput, aOutput1, aDuration, aEUt, aCleanroom);
+ return addAssemblerRecipe(new ItemStack[] { aInput1 }, aFluidInput, aOutput1, aDuration, aEUt, aCleanroom);
return addAssemblerRecipe(
- new ItemStack[] {aInput1, aInput2}, aFluidInput, aOutput1, aDuration, aEUt, aCleanroom);
+ new ItemStack[] { aInput1, aInput2 },
+ aFluidInput,
+ aOutput1,
+ aDuration,
+ aEUt,
+ aCleanroom);
}
@Override
- public boolean addAssemblerRecipe(
- ItemStack[] aInputs,
- FluidStack aFluidInput,
- ItemStack aOutput1,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAssemblerRecipe(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1, int aDuration,
+ int aEUt, boolean aCleanroom) {
- if (areItemsAndFluidsBothNull(aInputs, new FluidStack[] {aFluidInput})) {
+ if (areItemsAndFluidsBothNull(aInputs, new FluidStack[] { aFluidInput })) {
return false;
}
@@ -1149,9 +1006,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sAssemblerRecipes.addRecipe(
true,
aInputs,
- new ItemStack[] {aOutput1},
+ new ItemStack[] { aOutput1 },
null,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
aEUt,
@@ -1160,14 +1017,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return true;
}
- public boolean addAssemblerRecipeNonOD(
- ItemStack[] aInputs,
- FluidStack aFluidInput,
- ItemStack aOutput1,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
- if (areItemsAndFluidsBothNull(aInputs, new FluidStack[] {aFluidInput})) {
+ public boolean addAssemblerRecipeNonOD(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput1,
+ int aDuration, int aEUt, boolean aCleanroom) {
+ if (areItemsAndFluidsBothNull(aInputs, new FluidStack[] { aFluidInput })) {
return false;
}
@@ -1186,9 +1038,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sAssemblerRecipes.addRecipe(
true,
aInputs,
- new ItemStack[] {aOutput1},
+ new ItemStack[] { aOutput1 },
null,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
aEUt,
@@ -1205,7 +1057,15 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe.GT_Recipe_Map.sWiremillRecipes.addRecipe(
- true, new ItemStack[] {aInput}, new ItemStack[] {aOutput}, null, null, null, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput },
+ null,
+ null,
+ null,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@@ -1219,8 +1079,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sWiremillRecipes.addRecipe(
true,
- new ItemStack[] {aInput, aCircuit},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput, aCircuit },
+ new ItemStack[] { aOutput },
null,
null,
null,
@@ -1239,7 +1099,15 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe.GT_Recipe_Map.sPolarizerRecipes.addRecipe(
- true, new ItemStack[] {aInput}, new ItemStack[] {aOutput}, null, null, null, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput },
+ null,
+ null,
+ null,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@@ -1264,8 +1132,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe tRecipe = new GT_Recipe(
- new ItemStack[] {aInput1, aCircuit},
- new ItemStack[] {aOutput1},
+ new ItemStack[] { aInput1, aCircuit },
+ new ItemStack[] { aOutput1 },
null,
null,
null,
@@ -1287,8 +1155,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sExtruderRecipes.addRecipe(
true,
- new ItemStack[] {aInput, aShape},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput, aShape },
+ new ItemStack[] { aOutput },
null,
null,
null,
@@ -1308,8 +1176,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sSlicerRecipes.addRecipe(
true,
- new ItemStack[] {aInput, aShape},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput, aShape },
+ new ItemStack[] { aOutput },
null,
null,
null,
@@ -1320,16 +1188,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addOreWasherRecipe(
- ItemStack aInput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- FluidStack aFluidInput,
- int aDuration,
- int aEUt) {
- if ((aInput == null)
- || (aFluidInput == null)
+ public boolean addOreWasherRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3,
+ FluidStack aFluidInput, int aDuration, int aEUt) {
+ if ((aInput == null) || (aFluidInput == null)
|| ((aOutput1 == null) || (aOutput2 == null) || (aOutput3 == null))) {
return false;
}
@@ -1338,10 +1199,10 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sOreWasherRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
aEUt,
@@ -1350,17 +1211,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addOreWasherRecipe(
- ItemStack aInput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- FluidStack aFluidInput,
- int[] aChances,
- int aDuration,
- int aEUt) {
- if ((aInput == null)
- || (aFluidInput == null)
+ public boolean addOreWasherRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3,
+ FluidStack aFluidInput, int[] aChances, int aDuration, int aEUt) {
+ if ((aInput == null) || (aFluidInput == null)
|| ((aOutput1 == null) || (aOutput2 == null) || (aOutput3 == null))) {
return false;
}
@@ -1369,11 +1222,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sOreWasherRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
aChances,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
aEUt,
@@ -1398,8 +1251,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if (tGunpowder < 65) {
GT_Recipe.GT_Recipe_Map.sImplosionRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, ItemList.Block_Powderbarrel.get(tGunpowder, new Object[0])},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput1, ItemList.Block_Powderbarrel.get(tGunpowder, new Object[0]) },
+ new ItemStack[] { aOutput1, aOutput2 },
null,
null,
null,
@@ -1411,8 +1264,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if (tDynamite < 17) {
GT_Recipe.GT_Recipe_Map.sImplosionRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, GT_ModHandler.getIC2Item("dynamite", tDynamite, null)},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput1, GT_ModHandler.getIC2Item("dynamite", tDynamite, null) },
+ new ItemStack[] { aOutput1, aOutput2 },
null,
null,
null,
@@ -1423,8 +1276,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sImplosionRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, new ItemStack(Blocks.tnt, tTNT)},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput1, new ItemStack(Blocks.tnt, tTNT) },
+ new ItemStack[] { aOutput1, aOutput2 },
null,
null,
null,
@@ -1434,8 +1287,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
0);
GT_Recipe.GT_Recipe_Map.sImplosionRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, GT_ModHandler.getIC2Item("industrialTnt", tITNT, null)},
- new ItemStack[] {aOutput1, aOutput2},
+ new ItemStack[] { aInput1, GT_ModHandler.getIC2Item("industrialTnt", tITNT, null) },
+ new ItemStack[] { aOutput1, aOutput2 },
null,
null,
null,
@@ -1449,21 +1302,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
@Override
@Deprecated
- public boolean addDistillationRecipe(
- ItemStack aInput1,
- int aInput2,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- int aDuration,
- int aEUt) {
+ public boolean addDistillationRecipe(ItemStack aInput1, int aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, ItemStack aOutput4, int aDuration, int aEUt) {
return false;
}
@Override
- public boolean addUniversalDistillationRecipe(
- FluidStack aInput, FluidStack[] aOutputs, ItemStack aOutput2, int aDuration, int aEUt) {
+ public boolean addUniversalDistillationRecipe(FluidStack aInput, FluidStack[] aOutputs, ItemStack aOutput2,
+ int aDuration, int aEUt) {
for (int i = 0; i < Math.min(aOutputs.length, 11); i++) {
addDistilleryRecipe(i + 1, aInput, aOutputs[i], aOutput2, aDuration * 2, aEUt / 4, false);
}
@@ -1472,8 +1318,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addDistillationTowerRecipe(
- FluidStack aInput, FluidStack[] aOutputs, ItemStack aOutput2, int aDuration, int aEUt) {
+ public boolean addDistillationTowerRecipe(FluidStack aInput, FluidStack[] aOutputs, ItemStack aOutput2,
+ int aDuration, int aEUt) {
if (aInput == null || aOutputs == null || aOutputs.length < 1 || aOutputs.length > 11) {
return false;
}
@@ -1483,9 +1329,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sDistillationRecipes.addRecipe(
false,
null,
- new ItemStack[] {aOutput2},
+ new ItemStack[] { aOutput2 },
null,
- new FluidStack[] {aInput},
+ new FluidStack[] { aInput },
aOutputs,
aDuration,
Math.max(1, aEUt),
@@ -1494,13 +1340,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addDistillationTowerRecipe(
- FluidStack aInput,
- ItemStack[] aCircuit,
- FluidStack[] aOutputs,
- ItemStack aOutput2,
- int aDuration,
- int aEUt) {
+ public boolean addDistillationTowerRecipe(FluidStack aInput, ItemStack[] aCircuit, FluidStack[] aOutputs,
+ ItemStack aOutput2, int aDuration, int aEUt) {
if (aInput == null || aOutputs == null || aOutputs.length < 1 || aOutputs.length > 11) {
return false;
}
@@ -1510,9 +1351,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sDistillationRecipes.addRecipe(
false,
aCircuit,
- new ItemStack[] {aOutput2},
+ new ItemStack[] { aOutput2 },
null,
- new FluidStack[] {aInput},
+ new FluidStack[] { aInput },
aOutputs,
aDuration,
Math.max(1, aEUt),
@@ -1521,13 +1362,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addUniversalDistillationRecipewithCircuit(
- FluidStack aInput,
- ItemStack[] aCircuit,
- FluidStack[] aOutputs,
- ItemStack aOutput2,
- int aDuration,
- int aEUt) {
+ public boolean addUniversalDistillationRecipewithCircuit(FluidStack aInput, ItemStack[] aCircuit,
+ FluidStack[] aOutputs, ItemStack aOutput2, int aDuration, int aEUt) {
for (int i = 0; i < Math.min(aOutputs.length, 11); i++) {
addDistilleryRecipe(i + 1, aInput, aOutputs[i], aOutput2, aDuration * 2, aEUt / 4, false);
}
@@ -1579,13 +1415,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addVacuumFreezerRecipe(
- ItemStack[] aItemInput,
- FluidStack[] aFluidInput,
- ItemStack[] aItemOutput,
- FluidStack[] aFluidOutput,
- int aDuration,
- int aEUt) {
+ public boolean addVacuumFreezerRecipe(ItemStack[] aItemInput, FluidStack[] aFluidInput, ItemStack[] aItemOutput,
+ FluidStack[] aFluidOutput, int aDuration, int aEUt) {
GT_Recipe.GT_Recipe_Map.sVacuumRecipes.addRecipe(
false,
aItemInput,
@@ -1601,13 +1432,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
@Override
@Deprecated
- public boolean addGrinderRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4) {
+ public boolean addGrinderRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, ItemStack aOutput4) {
return false;
}
@@ -1636,16 +1462,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addChemicalBathRecipe(
- ItemStack aInput,
- FluidStack aBathingFluid,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- FluidStack aFluidOutput,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addChemicalBathRecipe(ItemStack aInput, FluidStack aBathingFluid, ItemStack aOutput1,
+ ItemStack aOutput2, ItemStack aOutput3, FluidStack aFluidOutput, int[] aChances, int aDuration, int aEUt) {
return false;
}
@@ -1658,27 +1476,38 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe.GT_Recipe_Map.sHammerRecipes.addRecipe(
- true, new ItemStack[] {aInput1}, new ItemStack[] {aOutput1}, null, null, null, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aInput1 },
+ new ItemStack[] { aOutput1 },
+ null,
+ null,
+ null,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@Override
- public boolean addForgeHammerRecipe(
- ItemStack[] ItemInputArray,
- FluidStack[] FluidInputArray,
- ItemStack[] ItemOutputArray,
- FluidStack[] FluidOutputArray,
- int aDuration,
- int aEUt) {
+ public boolean addForgeHammerRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray,
+ ItemStack[] ItemOutputArray, FluidStack[] FluidOutputArray, int aDuration, int aEUt) {
GT_Recipe.GT_Recipe_Map.sHammerRecipes.addRecipe(
- true, ItemInputArray, ItemOutputArray, null, FluidInputArray, FluidOutputArray, aDuration, aEUt, 0);
+ true,
+ ItemInputArray,
+ ItemOutputArray,
+ null,
+ FluidInputArray,
+ FluidOutputArray,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@Override
- public boolean addBoxingRecipe(
- ItemStack aContainedItem, ItemStack aEmptyBox, ItemStack aFullBox, int aDuration, int aEUt) {
+ public boolean addBoxingRecipe(ItemStack aContainedItem, ItemStack aEmptyBox, ItemStack aFullBox, int aDuration,
+ int aEUt) {
if ((aContainedItem == null) || (aFullBox == null)) {
return false;
}
@@ -1687,8 +1516,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sBoxinatorRecipes.addRecipe(
true,
- new ItemStack[] {aContainedItem, aEmptyBox},
- new ItemStack[] {aFullBox},
+ new ItemStack[] { aContainedItem, aEmptyBox },
+ new ItemStack[] { aFullBox },
null,
null,
null,
@@ -1699,8 +1528,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addUnboxingRecipe(
- ItemStack aFullBox, ItemStack aContainedItem, ItemStack aEmptyBox, int aDuration, int aEUt) {
+ public boolean addUnboxingRecipe(ItemStack aFullBox, ItemStack aContainedItem, ItemStack aEmptyBox, int aDuration,
+ int aEUt) {
if ((aFullBox == null) || (aContainedItem == null)) {
return false;
}
@@ -1709,8 +1538,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sUnboxinatorRecipes.addRecipe(
true,
- new ItemStack[] {aFullBox},
- new ItemStack[] {aContainedItem, aEmptyBox},
+ new ItemStack[] { aFullBox },
+ new ItemStack[] { aContainedItem, aEmptyBox },
null,
null,
null,
@@ -1721,8 +1550,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addThermalCentrifugeRecipe(
- ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, int aDuration, int aEUt) {
+ public boolean addThermalCentrifugeRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, int aDuration, int aEUt) {
if ((aInput == null) || (aOutput1 == null)) {
return false;
}
@@ -1731,8 +1560,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sThermalCentrifugeRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
null,
null,
@@ -1743,14 +1572,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addThermalCentrifugeRecipe(
- ItemStack aInput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addThermalCentrifugeRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aOutput1 == null)) {
return false;
}
@@ -1759,8 +1582,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sThermalCentrifugeRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
aChances,
null,
@@ -1781,11 +1604,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sAmplifiers.addRecipe(
true,
- new ItemStack[] {aAmplifierItem},
+ new ItemStack[] { aAmplifierItem },
null,
null,
null,
- new FluidStack[] {Materials.UUAmplifier.getFluid(aAmplifierAmountOutputted)},
+ new FluidStack[] { Materials.UUAmplifier.getFluid(aAmplifierAmountOutputted) },
aDuration,
30,
0);
@@ -1793,8 +1616,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addBrewingRecipe(
- ItemStack aIngredient, Fluid aInput, Fluid aOutput, int aDuration, int aEUt, boolean aHidden) {
+ public boolean addBrewingRecipe(ItemStack aIngredient, Fluid aInput, Fluid aOutput, int aDuration, int aEUt,
+ boolean aHidden) {
if ((aIngredient == null) || (aInput == null) || (aOutput == null)) {
return false;
}
@@ -1803,11 +1626,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sBrewingRecipes.addRecipe(
false,
- new ItemStack[] {aIngredient},
+ new ItemStack[] { aIngredient },
null,
null,
- new FluidStack[] {new FluidStack(aInput, 750)},
- new FluidStack[] {new FluidStack(aOutput, 750)},
+ new FluidStack[] { new FluidStack(aInput, 750) },
+ new FluidStack[] { new FluidStack(aOutput, 750) },
aDuration,
aEUt,
0);
@@ -1823,8 +1646,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addBrewingRecipeCustom(
- ItemStack aIngredient, FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt, boolean aHidden) {
+ public boolean addBrewingRecipeCustom(ItemStack aIngredient, FluidStack aInput, FluidStack aOutput, int aDuration,
+ int aEUt, boolean aHidden) {
if ((aInput == null) || (aOutput == null)) {
return false;
}
@@ -1833,11 +1656,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sBrewingRecipes.addRecipe(
false,
- new ItemStack[] {aIngredient},
+ new ItemStack[] { aIngredient },
null,
null,
- new FluidStack[] {aInput},
- new FluidStack[] {aOutput},
+ new FluidStack[] { aInput },
+ new FluidStack[] { aOutput },
aDuration,
aEUt,
0);
@@ -1848,18 +1671,25 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFermentingRecipe(
- FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt, boolean aHidden) {
+ public boolean addFermentingRecipe(FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt,
+ boolean aHidden) {
if ((aInput == null) || (aOutput == null)) {
return false;
}
- if ((aDuration = GregTech_API.sRecipeFile.get(
- "fermenting", aOutput.getFluid().getUnlocalizedName(), aDuration))
+ if ((aDuration = GregTech_API.sRecipeFile.get("fermenting", aOutput.getFluid().getUnlocalizedName(), aDuration))
<= 0) {
return false;
}
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sFermentingRecipes.addRecipe(
- false, null, null, null, new FluidStack[] {aInput}, new FluidStack[] {aOutput}, aDuration, aEUt, 0);
+ false,
+ null,
+ null,
+ null,
+ new FluidStack[] { aInput },
+ new FluidStack[] { aOutput },
+ aDuration,
+ aEUt,
+ 0);
if ((aHidden) && (tRecipe != null)) {
tRecipe.mHidden = true;
}
@@ -1872,19 +1702,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addDistilleryRecipe(
- ItemStack aCircuit,
- FluidStack aInput,
- FluidStack aOutput,
- ItemStack aSolidOutput,
- int aDuration,
- int aEUt,
- boolean aHidden) {
+ public boolean addDistilleryRecipe(ItemStack aCircuit, FluidStack aInput, FluidStack aOutput,
+ ItemStack aSolidOutput, int aDuration, int aEUt, boolean aHidden) {
if ((aInput == null) || (aOutput == null)) {
return false;
}
- if ((aDuration = GregTech_API.sRecipeFile.get(
- "distillery", aOutput.getFluid().getUnlocalizedName(), aDuration))
+ if ((aDuration = GregTech_API.sRecipeFile.get("distillery", aOutput.getFluid().getUnlocalizedName(), aDuration))
<= 0) {
return false;
}
@@ -1909,11 +1732,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
aOutput = new FluidStack(aOutput.getFluid(), aOutput.amount / tScale);
if (aSolidOutput != null) {
ItemData tData = GT_OreDictUnificator.getItemData(aSolidOutput);
- if (tData != null
- && (tData.mPrefix == OrePrefixes.dust
- || OrePrefixes.dust.mFamiliarPrefixes.contains(tData.mPrefix))) {
+ if (tData != null && (tData.mPrefix == OrePrefixes.dust
+ || OrePrefixes.dust.mFamiliarPrefixes.contains(tData.mPrefix))) {
aSolidOutput = GT_OreDictUnificator.getDust(
- tData.mMaterial.mMaterial, tData.mMaterial.mAmount * aSolidOutput.stackSize / tScale);
+ tData.mMaterial.mMaterial,
+ tData.mMaterial.mAmount * aSolidOutput.stackSize / tScale);
} else {
if (aSolidOutput.stackSize / tScale == 0) aSolidOutput = GT_Values.NI;
else aSolidOutput = new ItemStack(aSolidOutput.getItem(), aSolidOutput.stackSize / tScale);
@@ -1924,11 +1747,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sDistilleryRecipes.addRecipe(
true,
- new ItemStack[] {aCircuit},
- new ItemStack[] {aSolidOutput},
+ new ItemStack[] { aCircuit },
+ new ItemStack[] { aSolidOutput },
null,
- new FluidStack[] {aInput},
- new FluidStack[] {aOutput},
+ new FluidStack[] { aInput },
+ new FluidStack[] { aOutput },
aDuration,
aEUt,
0);
@@ -1939,20 +1762,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addDistilleryRecipe(
- ItemStack aCircuit, FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt, boolean aHidden) {
+ public boolean addDistilleryRecipe(ItemStack aCircuit, FluidStack aInput, FluidStack aOutput, int aDuration,
+ int aEUt, boolean aHidden) {
return addDistilleryRecipe(aCircuit, aInput, aOutput, null, aDuration, aEUt, aHidden);
}
@Override
- public boolean addDistilleryRecipe(
- int circuitConfig,
- FluidStack aInput,
- FluidStack aOutput,
- ItemStack aSolidOutput,
- int aDuration,
- int aEUt,
- boolean aHidden) {
+ public boolean addDistilleryRecipe(int circuitConfig, FluidStack aInput, FluidStack aOutput, ItemStack aSolidOutput,
+ int aDuration, int aEUt, boolean aHidden) {
return addDistilleryRecipe(
GT_Utility.getIntegratedCircuit(circuitConfig),
aInput,
@@ -1964,15 +1781,20 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addDistilleryRecipe(
- int circuitConfig, FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt, boolean aHidden) {
+ public boolean addDistilleryRecipe(int circuitConfig, FluidStack aInput, FluidStack aOutput, int aDuration,
+ int aEUt, boolean aHidden) {
return addDistilleryRecipe(
- GT_Utility.getIntegratedCircuit(circuitConfig), aInput, aOutput, aDuration, aEUt, aHidden);
+ GT_Utility.getIntegratedCircuit(circuitConfig),
+ aInput,
+ aOutput,
+ aDuration,
+ aEUt,
+ aHidden);
}
@Override
- public boolean addFluidSolidifierRecipe(
- ItemStack aMold, FluidStack aInput, ItemStack aOutput, int aDuration, int aEUt) {
+ public boolean addFluidSolidifierRecipe(ItemStack aMold, FluidStack aInput, ItemStack aOutput, int aDuration,
+ int aEUt) {
if ((aMold == null) || (aInput == null) || (aOutput == null)) {
return false;
}
@@ -1987,10 +1809,10 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sFluidSolidficationRecipes.addRecipe(
true,
- new ItemStack[] {aMold},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aMold },
+ new ItemStack[] { aOutput },
null,
- new FluidStack[] {aInput},
+ new FluidStack[] { aInput },
null,
aDuration,
aEUt,
@@ -1999,20 +1821,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFluidSmelterRecipe(
- ItemStack aInput, ItemStack aRemains, FluidStack aOutput, int aChance, int aDuration, int aEUt) {
+ public boolean addFluidSmelterRecipe(ItemStack aInput, ItemStack aRemains, FluidStack aOutput, int aChance,
+ int aDuration, int aEUt) {
return addFluidSmelterRecipe(aInput, aRemains, aOutput, aChance, aDuration, aEUt, false);
}
@Override
- public boolean addFluidSmelterRecipe(
- ItemStack aInput,
- ItemStack aRemains,
- FluidStack aOutput,
- int aChance,
- int aDuration,
- int aEUt,
- boolean hidden) {
+ public boolean addFluidSmelterRecipe(ItemStack aInput, ItemStack aRemains, FluidStack aOutput, int aChance,
+ int aDuration, int aEUt, boolean hidden) {
if ((aInput == null) || (aOutput == null)) {
return false;
}
@@ -2027,12 +1843,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sFluidExtractionRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aRemains},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aRemains },
null,
- new int[] {aChance},
+ new int[] { aChance },
null,
- new FluidStack[] {aOutput},
+ new FluidStack[] { aOutput },
aDuration,
aEUt,
0);
@@ -2043,8 +1859,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFluidExtractionRecipe(
- ItemStack aInput, ItemStack aRemains, FluidStack aOutput, int aChance, int aDuration, int aEUt) {
+ public boolean addFluidExtractionRecipe(ItemStack aInput, ItemStack aRemains, FluidStack aOutput, int aChance,
+ int aDuration, int aEUt) {
if ((aInput == null) || (aOutput == null)) {
return false;
}
@@ -2059,12 +1875,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sFluidExtractionRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aRemains},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aRemains },
null,
- new int[] {aChance},
+ new int[] { aChance },
null,
- new FluidStack[] {aOutput},
+ new FluidStack[] { aOutput },
aDuration,
aEUt,
0);
@@ -2072,8 +1888,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFluidCannerRecipe(
- ItemStack aInput, ItemStack aOutput, FluidStack aFluidInput, FluidStack aFluidOutput) {
+ public boolean addFluidCannerRecipe(ItemStack aInput, ItemStack aOutput, FluidStack aFluidInput,
+ FluidStack aFluidOutput) {
int aDuration = aFluidOutput == null ? aFluidInput.amount / 62 : aFluidOutput.amount / 62;
if (aInput == null || aOutput == null) {
@@ -2087,11 +1903,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sFluidCannerRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput },
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
1,
0);
@@ -2099,13 +1915,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFluidCannerRecipe(
- ItemStack aInput,
- ItemStack aOutput,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- int aDuration,
- int aEUt) {
+ public boolean addFluidCannerRecipe(ItemStack aInput, ItemStack aOutput, FluidStack aFluidInput,
+ FluidStack aFluidOutput, int aDuration, int aEUt) {
if (aInput == null || aOutput == null) {
return false;
}
@@ -2117,11 +1928,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sFluidCannerRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput },
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
0);
@@ -2129,15 +1940,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addChemicalBathRecipe(
- ItemStack aInput,
- FluidStack aBathingFluid,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addChemicalBathRecipe(ItemStack aInput, FluidStack aBathingFluid, ItemStack aOutput1,
+ ItemStack aOutput2, ItemStack aOutput3, int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aBathingFluid == null) || (aOutput1 == null)) {
return false;
}
@@ -2146,11 +1950,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sChemicalBathRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
aChances,
- new FluidStack[] {aBathingFluid},
+ new FluidStack[] { aBathingFluid },
null,
aDuration,
aEUt,
@@ -2159,16 +1963,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addChemicalBathRecipe(
- ItemStack aInput,
- FluidStack aBathingFluid,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addChemicalBathRecipe(ItemStack aInput, FluidStack aBathingFluid, FluidStack aFluidOutput,
+ ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3, int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aBathingFluid == null) || (aOutput1 == null)) {
return false;
}
@@ -2177,12 +1973,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sChemicalBathRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
aChances,
- new FluidStack[] {aBathingFluid},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aBathingFluid },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
0);
@@ -2190,14 +1986,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addElectromagneticSeparatorRecipe(
- ItemStack aInput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addElectromagneticSeparatorRecipe(ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2,
+ ItemStack aOutput3, int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aOutput1 == null)) {
return false;
}
@@ -2206,8 +1996,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sElectroMagneticSeparatorRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput1, aOutput2, aOutput3},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3 },
null,
aChances,
null,
@@ -2227,13 +2017,21 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe.GT_Recipe_Map.sExtractorRecipes.addRecipe(
- true, new ItemStack[] {aInput}, new ItemStack[] {aOutput}, null, null, null, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput },
+ null,
+ null,
+ null,
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@Override
- public boolean addPrinterRecipe(
- ItemStack aInput, FluidStack aFluid, ItemStack aSpecialSlot, ItemStack aOutput, int aDuration, int aEUt) {
+ public boolean addPrinterRecipe(ItemStack aInput, FluidStack aFluid, ItemStack aSpecialSlot, ItemStack aOutput,
+ int aDuration, int aEUt) {
if ((aInput == null) || (aFluid == null) || (aOutput == null)) {
return false;
}
@@ -2242,11 +2040,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sPrinterRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput },
+ new ItemStack[] { aOutput },
aSpecialSlot,
null,
- new FluidStack[] {aFluid},
+ new FluidStack[] { aFluid },
null,
aDuration,
aEUt,
@@ -2255,58 +2053,31 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAutoclaveRecipe(
- ItemStack aInput,
- FluidStack aFluid,
- ItemStack aOutput,
- int aChance,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAutoclaveRecipe(ItemStack aInput, FluidStack aFluid, ItemStack aOutput, int aChance,
+ int aDuration, int aEUt, boolean aCleanroom) {
return addAutoclaveRecipe(aInput, aFluid, aOutput, aChance, aDuration, aEUt);
}
@Override
- public boolean addAutoclaveRecipe(
- ItemStack aInput, FluidStack aFluid, ItemStack aOutput, int aChance, int aDuration, int aEUt) {
+ public boolean addAutoclaveRecipe(ItemStack aInput, FluidStack aFluid, ItemStack aOutput, int aChance,
+ int aDuration, int aEUt) {
return addAutoclaveRecipe(aInput, null, aFluid, aOutput, aChance, aDuration, aEUt, false);
}
- public boolean addAutoclaveRecipe(
- ItemStack aInput,
- ItemStack aCircuit,
- FluidStack aFluid,
- ItemStack aOutput,
- int aChance,
- int aDuration,
- int aEUt) {
+ public boolean addAutoclaveRecipe(ItemStack aInput, ItemStack aCircuit, FluidStack aFluid, ItemStack aOutput,
+ int aChance, int aDuration, int aEUt) {
return addAutoclaveRecipe(aInput, aCircuit, aFluid, aOutput, aChance, aDuration, aEUt, false);
}
@Override
- public boolean addAutoclaveRecipe(
- ItemStack aInput,
- ItemStack aCircuit,
- FluidStack aFluidIn,
- ItemStack aOutput,
- int aChance,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAutoclaveRecipe(ItemStack aInput, ItemStack aCircuit, FluidStack aFluidIn, ItemStack aOutput,
+ int aChance, int aDuration, int aEUt, boolean aCleanroom) {
return addAutoclaveRecipe(aInput, aCircuit, aFluidIn, null, aOutput, aChance, aDuration, aEUt, aCleanroom);
}
@Override
- public boolean addAutoclaveRecipe(
- ItemStack aInput,
- ItemStack aCircuit,
- FluidStack aFluidIn,
- FluidStack aFluidOut,
- ItemStack aOutput,
- int aChance,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAutoclaveRecipe(ItemStack aInput, ItemStack aCircuit, FluidStack aFluidIn, FluidStack aFluidOut,
+ ItemStack aOutput, int aChance, int aDuration, int aEUt, boolean aCleanroom) {
if ((aInput == null) || (aFluidIn == null) || (aOutput == null)) {
return false;
}
@@ -2318,12 +2089,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sAutoclaveRecipes.addRecipe(
true,
- new ItemStack[] {aInput, aCircuit},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput, aCircuit },
+ new ItemStack[] { aOutput },
null,
- new int[] {aChance},
- new FluidStack[] {aFluidIn},
- new FluidStack[] {aFluidOut},
+ new int[] { aChance },
+ new FluidStack[] { aFluidIn },
+ new FluidStack[] { aFluidOut },
aDuration,
aEUt,
aCleanroom ? -200 : 0);
@@ -2331,27 +2102,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAutoclaveSpaceRecipe(
- ItemStack aInput,
- FluidStack aFluid,
- ItemStack aOutput,
- int aChance,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAutoclaveSpaceRecipe(ItemStack aInput, FluidStack aFluid, ItemStack aOutput, int aChance,
+ int aDuration, int aEUt, boolean aCleanroom) {
return addAutoclaveRecipe(aInput, aFluid, aOutput, aChance, aDuration, aEUt, aCleanroom);
}
@Override
- public boolean addAutoclaveSpaceRecipe(
- ItemStack aInput,
- ItemStack aCircuit,
- FluidStack aFluid,
- ItemStack aOutput,
- int aChance,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAutoclaveSpaceRecipe(ItemStack aInput, ItemStack aCircuit, FluidStack aFluid, ItemStack aOutput,
+ int aChance, int aDuration, int aEUt, boolean aCleanroom) {
if ((aInput == null) || (aFluid == null) || (aOutput == null)) {
return false;
}
@@ -2363,11 +2121,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sAutoclaveRecipes.addRecipe(
true,
- new ItemStack[] {aInput, aCircuit},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput, aCircuit },
+ new ItemStack[] { aOutput },
null,
- new int[] {aChance},
- new FluidStack[] {aFluid},
+ new int[] { aChance },
+ new FluidStack[] { aFluid },
null,
aDuration,
aEUt,
@@ -2376,16 +2134,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAutoclave4Recipe(
- ItemStack aInput,
- ItemStack aCircuit,
- FluidStack aFluidIn,
- FluidStack aFluidOut,
- ItemStack[] aOutputs,
- int[] aChances,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addAutoclave4Recipe(ItemStack aInput, ItemStack aCircuit, FluidStack aFluidIn, FluidStack aFluidOut,
+ ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt, boolean aCleanroom) {
if ((aInput == null) || (aFluidIn == null) || (aOutputs == null)) {
return false;
}
@@ -2397,12 +2147,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sAutoclaveRecipes.addRecipe(
true,
- new ItemStack[] {aInput, aCircuit},
+ new ItemStack[] { aInput, aCircuit },
aOutputs,
null,
aChances,
- new FluidStack[] {aFluidIn},
- new FluidStack[] {aFluidOut},
+ new FluidStack[] { aFluidIn },
+ new FluidStack[] { aFluidOut },
aDuration,
aEUt,
aCleanroom ? -200 : 0);
@@ -2411,16 +2161,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
@Deprecated
@Override
- public boolean addMixerRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aInput3,
- ItemStack aInput4,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- int aDuration,
- int aEUt) {
+ public boolean addMixerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aInput3, ItemStack aInput4,
+ FluidStack aFluidInput, FluidStack aFluidOutput, ItemStack aOutput, int aDuration, int aEUt) {
return addMixerRecipe(
aInput1,
aInput2,
@@ -2440,18 +2182,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
@Deprecated
@Override
- public boolean addMixerRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aInput3,
- ItemStack aInput4,
- ItemStack aInput5,
- ItemStack aInput6,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- int aDuration,
- int aEUt) {
+ public boolean addMixerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aInput3, ItemStack aInput4,
+ ItemStack aInput5, ItemStack aInput6, FluidStack aFluidInput, FluidStack aFluidOutput, ItemStack aOutput,
+ int aDuration, int aEUt) {
return addMixerRecipe(
aInput1,
aInput2,
@@ -2471,21 +2204,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
@Deprecated
@Override
- public boolean addMixerRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aInput3,
- ItemStack aInput4,
- ItemStack aInput5,
- ItemStack aInput6,
- ItemStack aInput7,
- ItemStack aInput8,
- ItemStack aInput9,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput,
- int aDuration,
- int aEUt) {
+ public boolean addMixerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aInput3, ItemStack aInput4,
+ ItemStack aInput5, ItemStack aInput6, ItemStack aInput7, ItemStack aInput8, ItemStack aInput9,
+ FluidStack aFluidInput, FluidStack aFluidOutput, ItemStack aOutput, int aDuration, int aEUt) {
if (((aInput1 == null) && (aFluidInput == null)) || ((aOutput == null) && (aFluidOutput == null))) {
return false;
}
@@ -2493,26 +2214,25 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
if ((aFluidOutput != null)
- && ((aDuration = GregTech_API.sRecipeFile.get(
- "mixer", aFluidOutput.getFluid().getName(), aDuration))
+ && ((aDuration = GregTech_API.sRecipeFile.get("mixer", aFluidOutput.getFluid().getName(), aDuration))
<= 0)) {
return false;
}
GT_Recipe.GT_Recipe_Map.sMixerRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9 },
+ new ItemStack[] { aOutput },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
0);
- ItemStack[] itemInputs = {aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9};
- ItemStack[] itemOutputs = {aOutput};
- FluidStack[] fluidInputs = {aFluidInput, null, null, null, null, null, null, null, null, null};
- FluidStack[] fluidOutputs = {aFluidOutput, null};
+ ItemStack[] itemInputs = { aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9 };
+ ItemStack[] itemOutputs = { aOutput };
+ FluidStack[] fluidInputs = { aFluidInput, null, null, null, null, null, null, null, null, null };
+ FluidStack[] fluidOutputs = { aFluidOutput, null };
byte iNumber = 0;
byte oNumber = 0;
@@ -2537,19 +2257,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
oNumber++;
}
- GT_Recipe.GT_Recipe_Map.sMultiblockMixerRecipes.addRecipe(
- false, itemInputs, itemOutputs, null, null, fluidInputs, fluidOutputs, aDuration, aEUt, 0);
+ GT_Recipe.GT_Recipe_Map.sMultiblockMixerRecipes
+ .addRecipe(false, itemInputs, itemOutputs, null, null, fluidInputs, fluidOutputs, aDuration, aEUt, 0);
return true;
}
@Override
- public boolean addMixerRecipe(
- ItemStack[] ItemInputArray,
- FluidStack[] FluidInputArray,
- ItemStack[] ItemOutputArray,
- FluidStack[] FluidOutputArray,
- int aDuration,
- int aEUt) {
+ public boolean addMixerRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray, ItemStack[] ItemOutputArray,
+ FluidStack[] FluidOutputArray, int aDuration, int aEUt) {
GT_Recipe.GT_Recipe_Map.sMixerRecipes.addRecipe(
false,
ItemInputArray,
@@ -2590,8 +2305,7 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
List<FluidStack> tFluidOutputList;
if (FluidOutputArray != null) {
- tFluidOutputList = new ArrayList<>(Arrays.asList(FluidOutputArray));
- ;
+ tFluidOutputList = new ArrayList<>(Arrays.asList(FluidOutputArray));;
} else {
tFluidOutputList = new ArrayList<>(1);
}
@@ -2633,24 +2347,10 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
@Deprecated
@Override
- public boolean addMixerRecipe(
- ItemStack aInput1,
- ItemStack aInput2,
- ItemStack aInput3,
- ItemStack aInput4,
- ItemStack aInput5,
- ItemStack aInput6,
- ItemStack aInput7,
- ItemStack aInput8,
- ItemStack aInput9,
- FluidStack aFluidInput,
- FluidStack aFluidOutput,
- ItemStack aOutput1,
- ItemStack aOutput2,
- ItemStack aOutput3,
- ItemStack aOutput4,
- int aDuration,
- int aEUt) {
+ public boolean addMixerRecipe(ItemStack aInput1, ItemStack aInput2, ItemStack aInput3, ItemStack aInput4,
+ ItemStack aInput5, ItemStack aInput6, ItemStack aInput7, ItemStack aInput8, ItemStack aInput9,
+ FluidStack aFluidInput, FluidStack aFluidOutput, ItemStack aOutput1, ItemStack aOutput2, ItemStack aOutput3,
+ ItemStack aOutput4, int aDuration, int aEUt) {
if (((aInput1 == null) && (aFluidInput == null)) || ((aOutput1 == null) && (aFluidOutput == null))) {
return false;
}
@@ -2658,26 +2358,25 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
if ((aFluidOutput != null)
- && ((aDuration = GregTech_API.sRecipeFile.get(
- "mixer", aFluidOutput.getFluid().getName(), aDuration))
+ && ((aDuration = GregTech_API.sRecipeFile.get("mixer", aFluidOutput.getFluid().getName(), aDuration))
<= 0)) {
return false;
}
GT_Recipe.GT_Recipe_Map.sMixerRecipes.addRecipe(
true,
- new ItemStack[] {aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9},
- new ItemStack[] {aOutput1, aOutput2, aOutput3, aOutput4},
+ new ItemStack[] { aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9 },
+ new ItemStack[] { aOutput1, aOutput2, aOutput3, aOutput4 },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
0);
- ItemStack[] itemInputs = {aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9};
- ItemStack[] itemOutputs = {aOutput1, aOutput2, aOutput3, aOutput4};
- FluidStack[] fluidInputs = {aFluidInput, null, null, null, null, null, null, null, null, null};
- FluidStack[] fluidOutputs = {aFluidOutput, null, null, null, null};
+ ItemStack[] itemInputs = { aInput1, aInput2, aInput3, aInput4, aInput5, aInput6, aInput7, aInput8, aInput9 };
+ ItemStack[] itemOutputs = { aOutput1, aOutput2, aOutput3, aOutput4 };
+ FluidStack[] fluidInputs = { aFluidInput, null, null, null, null, null, null, null, null, null };
+ FluidStack[] fluidOutputs = { aFluidOutput, null, null, null, null };
byte iNumber = 0;
byte oNumber = 0;
@@ -2702,27 +2401,22 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
oNumber++;
}
- GT_Recipe.GT_Recipe_Map.sMultiblockMixerRecipes.addRecipe(
- false, itemInputs, itemOutputs, null, null, fluidInputs, fluidOutputs, aDuration, aEUt, 0);
+ GT_Recipe.GT_Recipe_Map.sMultiblockMixerRecipes
+ .addRecipe(false, itemInputs, itemOutputs, null, null, fluidInputs, fluidOutputs, aDuration, aEUt, 0);
return true;
}
@Deprecated
@Override
- public boolean addLaserEngraverRecipe(
- ItemStack aItemToEngrave, ItemStack aLens, ItemStack aEngravedItem, int aDuration, int aEUt) {
+ public boolean addLaserEngraverRecipe(ItemStack aItemToEngrave, ItemStack aLens, ItemStack aEngravedItem,
+ int aDuration, int aEUt) {
return addLaserEngraverRecipe(aItemToEngrave, aLens, aEngravedItem, aDuration, aEUt, false);
}
@Deprecated
@Override
- public boolean addLaserEngraverRecipe(
- ItemStack aItemToEngrave,
- ItemStack aLens,
- ItemStack aEngravedItem,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addLaserEngraverRecipe(ItemStack aItemToEngrave, ItemStack aLens, ItemStack aEngravedItem,
+ int aDuration, int aEUt, boolean aCleanroom) {
if ((aItemToEngrave == null) || (aLens == null) || (aEngravedItem == null)) {
return false;
}
@@ -2734,8 +2428,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sLaserEngraverRecipes.addRecipe(
true,
- new ItemStack[] {aItemToEngrave, aLens},
- new ItemStack[] {aEngravedItem},
+ new ItemStack[] { aItemToEngrave, aLens },
+ new ItemStack[] { aEngravedItem },
null,
null,
null,
@@ -2746,14 +2440,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addLaserEngraverRecipe(
- ItemStack[] ItemInputArray,
- FluidStack[] FluidInputArray,
- ItemStack[] OutputItemArray,
- FluidStack[] FluidOutputArray,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addLaserEngraverRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray,
+ ItemStack[] OutputItemArray, FluidStack[] FluidOutputArray, int aDuration, int aEUt, boolean aCleanroom) {
GT_Recipe.GT_Recipe_Map.sLaserEngraverRecipes.addRecipe(
false,
ItemInputArray,
@@ -2769,8 +2457,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFormingPressRecipe(
- ItemStack aItemToImprint, ItemStack aForm, ItemStack aImprintedItem, int aDuration, int aEUt) {
+ public boolean addFormingPressRecipe(ItemStack aItemToImprint, ItemStack aForm, ItemStack aImprintedItem,
+ int aDuration, int aEUt) {
if ((aItemToImprint == null) || (aForm == null) || (aImprintedItem == null)) {
return false;
}
@@ -2779,8 +2467,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sPressRecipes.addRecipe(
true,
- new ItemStack[] {aItemToImprint, aForm},
- new ItemStack[] {aImprintedItem},
+ new ItemStack[] { aItemToImprint, aForm },
+ new ItemStack[] { aImprintedItem },
null,
null,
null,
@@ -2791,13 +2479,13 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addFormingPressRecipe(
- ItemStack[] ItemInputArray, ItemStack[] OutputItemArray, int aDuration, int aEUt) {
+ public boolean addFormingPressRecipe(ItemStack[] ItemInputArray, ItemStack[] OutputItemArray, int aDuration,
+ int aEUt) {
if ((ItemInputArray == null) || (OutputItemArray == null)) {
return false;
}
- GT_Recipe.GT_Recipe_Map.sPressRecipes.addRecipe(
- true, ItemInputArray, OutputItemArray, null, null, null, aDuration, aEUt, 0);
+ GT_Recipe.GT_Recipe_Map.sPressRecipes
+ .addRecipe(true, ItemInputArray, OutputItemArray, null, null, null, aDuration, aEUt, 0);
return true;
}
@@ -2806,34 +2494,40 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if ((aItem == null) || (aOutput == null)) {
return false;
}
- if ((aDuration = GregTech_API.sRecipeFile.get(
- "fluidheater", aOutput.getFluid().getUnlocalizedName(), aDuration))
- <= 0) {
+ if ((aDuration = GregTech_API.sRecipeFile
+ .get("fluidheater", aOutput.getFluid().getUnlocalizedName(), aDuration)) <= 0) {
return false;
}
GT_Recipe.GT_Recipe_Map.sFluidHeaterRecipes.addRecipe(
- true, new ItemStack[] {aItem}, null, null, null, new FluidStack[] {aOutput}, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aItem },
+ null,
+ null,
+ null,
+ new FluidStack[] { aOutput },
+ aDuration,
+ aEUt,
+ 0);
return true;
}
@Override
- public boolean addFluidHeaterRecipe(
- ItemStack aCircuit, FluidStack aInput, FluidStack aOutput, int aDuration, int aEUt) {
+ public boolean addFluidHeaterRecipe(ItemStack aCircuit, FluidStack aInput, FluidStack aOutput, int aDuration,
+ int aEUt) {
if ((aInput == null) || (aOutput == null)) {
return false;
}
- if ((aDuration = GregTech_API.sRecipeFile.get(
- "fluidheater", aOutput.getFluid().getUnlocalizedName(), aDuration))
- <= 0) {
+ if ((aDuration = GregTech_API.sRecipeFile
+ .get("fluidheater", aOutput.getFluid().getUnlocalizedName(), aDuration)) <= 0) {
return false;
}
GT_Recipe.GT_Recipe_Map.sFluidHeaterRecipes.addRecipe(
true,
- new ItemStack[] {aCircuit},
+ new ItemStack[] { aCircuit },
null,
null,
- new FluidStack[] {aInput},
- new FluidStack[] {aOutput},
+ new FluidStack[] { aInput },
+ new FluidStack[] { aOutput },
aDuration,
aEUt,
0);
@@ -2841,8 +2535,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addSifterRecipe(
- ItemStack aItemToSift, ItemStack[] aSiftedItems, int[] aChances, int aDuration, int aEUt) {
+ public boolean addSifterRecipe(ItemStack aItemToSift, ItemStack[] aSiftedItems, int[] aChances, int aDuration,
+ int aEUt) {
if ((aItemToSift == null) || (aSiftedItems == null)) {
return false;
}
@@ -2853,7 +2547,7 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sSifterRecipes.addRecipe(
true,
- new ItemStack[] {aItemToSift},
+ new ItemStack[] { aItemToSift },
aSiftedItems,
null,
aChances,
@@ -2869,14 +2563,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addSifterRecipe(
- ItemStack[] ItemInputArray,
- FluidStack[] FluidInputArray,
- ItemStack[] OutputItemArray,
- FluidStack[] FluidOutputArray,
- int[] aChances,
- int aDuration,
- int aEUt,
+ public boolean addSifterRecipe(ItemStack[] ItemInputArray, FluidStack[] FluidInputArray,
+ ItemStack[] OutputItemArray, FluidStack[] FluidOutputArray, int[] aChances, int aDuration, int aEUt,
boolean aCleanroom) {
GT_Recipe.GT_Recipe_Map.sSifterRecipes.addRecipe(
false,
@@ -2893,14 +2581,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addArcFurnaceRecipe(
- ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt) {
+ public boolean addArcFurnaceRecipe(ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration,
+ int aEUt) {
return addArcFurnaceRecipe(aInput, aOutputs, aChances, aDuration, aEUt, false);
}
@Override
- public boolean addArcFurnaceRecipe(
- ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt, boolean hidden) {
+ public boolean addArcFurnaceRecipe(ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt,
+ boolean hidden) {
if ((aInput == null) || (aOutputs == null)) {
return false;
}
@@ -2911,11 +2599,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe sRecipe = GT_Recipe.GT_Recipe_Map.sArcFurnaceRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
+ new ItemStack[] { aInput },
aOutputs,
null,
aChances,
- new FluidStack[] {Materials.Oxygen.getGas(aDuration)},
+ new FluidStack[] { Materials.Oxygen.getGas(aDuration) },
null,
aDuration,
Math.max(1, aEUt),
@@ -2923,17 +2611,17 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if ((hidden) && (sRecipe != null)) {
sRecipe.mHidden = true;
}
- for (Materials tMaterial : new Materials[] {Materials.Argon, Materials.Nitrogen}) {
+ for (Materials tMaterial : new Materials[] { Materials.Argon, Materials.Nitrogen }) {
if (tMaterial.mPlasma != null) {
int tPlasmaAmount = (int) Math.max(1L, aDuration / (tMaterial.getMass() * 16L));
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sPlasmaArcFurnaceRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
+ new ItemStack[] { aInput },
aOutputs,
null,
aChances,
- new FluidStack[] {tMaterial.getPlasma(tPlasmaAmount)},
- new FluidStack[] {tMaterial.getGas(tPlasmaAmount)},
+ new FluidStack[] { tMaterial.getPlasma(tPlasmaAmount) },
+ new FluidStack[] { tMaterial.getGas(tPlasmaAmount) },
Math.max(1, aDuration / 16),
Math.max(1, aEUt / 3),
0);
@@ -2949,8 +2637,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addSimpleArcFurnaceRecipe(
- ItemStack aInput, FluidStack aFluidInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt) {
+ public boolean addSimpleArcFurnaceRecipe(ItemStack aInput, FluidStack aFluidInput, ItemStack[] aOutputs,
+ int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aOutputs == null) || aFluidInput == null) {
return false;
}
@@ -2961,11 +2649,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sArcFurnaceRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
+ new ItemStack[] { aInput },
aOutputs,
null,
aChances,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
Math.max(1, aEUt),
@@ -2977,8 +2665,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addPlasmaArcFurnaceRecipe(
- ItemStack aInput, FluidStack aFluidInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt) {
+ public boolean addPlasmaArcFurnaceRecipe(ItemStack aInput, FluidStack aFluidInput, ItemStack[] aOutputs,
+ int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aOutputs == null) || aFluidInput == null) {
return false;
}
@@ -2989,11 +2677,11 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sPlasmaArcFurnaceRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
+ new ItemStack[] { aInput },
aOutputs,
null,
aChances,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
Math.max(1, aEUt),
@@ -3005,14 +2693,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addPlasmaArcFurnaceRecipe(
- ItemStack aInput,
- FluidStack aFluidInput,
- ItemStack[] aOutputs,
- FluidStack aFluidOutput,
- int[] aChances,
- int aDuration,
- int aEUt) {
+ public boolean addPlasmaArcFurnaceRecipe(ItemStack aInput, FluidStack aFluidInput, ItemStack[] aOutputs,
+ FluidStack aFluidOutput, int[] aChances, int aDuration, int aEUt) {
if ((aInput == null) || (aOutputs == null) || aFluidInput == null) {
return false;
}
@@ -3023,12 +2705,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sPlasmaArcFurnaceRecipes.addRecipe(
true,
- new ItemStack[] {aInput},
+ new ItemStack[] { aInput },
aOutputs,
null,
aChances,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
Math.max(1, aEUt),
0);
@@ -3039,14 +2721,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addPulveriserRecipe(
- ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt) {
+ public boolean addPulveriserRecipe(ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration,
+ int aEUt) {
return addPulveriserRecipe(aInput, aOutputs, aChances, aDuration, aEUt, false);
}
@Override
- public boolean addPulveriserRecipe(
- ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt, boolean hidden) {
+ public boolean addPulveriserRecipe(ItemStack aInput, ItemStack[] aOutputs, int[] aChances, int aDuration, int aEUt,
+ boolean hidden) {
if ((aInput == null) || (aOutputs == null)) {
return false;
}
@@ -3056,7 +2738,16 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sMaceratorRecipes.addRecipe(
- true, new ItemStack[] {aInput}, aOutputs, null, aChances, null, null, aDuration, aEUt, 0);
+ true,
+ new ItemStack[] { aInput },
+ aOutputs,
+ null,
+ aChances,
+ null,
+ null,
+ aDuration,
+ aEUt,
+ 0);
if ((hidden) && (tRecipe != null)) {
tRecipe.mHidden = true;
}
@@ -3067,14 +2758,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addPyrolyseRecipe(
- ItemStack aInput,
- FluidStack aFluidInput,
- int intCircuit,
- ItemStack aOutput,
- FluidStack aFluidOutput,
- int aDuration,
- int aEUt) {
+ public boolean addPyrolyseRecipe(ItemStack aInput, FluidStack aFluidInput, int intCircuit, ItemStack aOutput,
+ FluidStack aFluidOutput, int aDuration, int aEUt) {
if (aInput == null) {
return false;
}
@@ -3083,12 +2768,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sPyrolyseRecipes.addRecipe(
false,
- new ItemStack[] {aInput, ItemList.Circuit_Integrated.getWithDamage(0L, intCircuit, new Object[0])},
- new ItemStack[] {aOutput},
+ new ItemStack[] { aInput, ItemList.Circuit_Integrated.getWithDamage(0L, intCircuit, new Object[0]) },
+ new ItemStack[] { aOutput },
null,
null,
- new FluidStack[] {aFluidInput},
- new FluidStack[] {aFluidOutput},
+ new FluidStack[] { aFluidInput },
+ new FluidStack[] { aFluidOutput },
aDuration,
aEUt,
0);
@@ -3102,8 +2787,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCrackingRecipe(
- int circuitConfig, FluidStack aInput, FluidStack aInput2, FluidStack aOutput, int aDuration, int aEUt) {
+ public boolean addCrackingRecipe(int circuitConfig, FluidStack aInput, FluidStack aInput2, FluidStack aOutput,
+ int aDuration, int aEUt) {
if ((aInput == null && aInput2 == null) || (aOutput == null)) {
return false;
}
@@ -3112,12 +2797,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
GT_Recipe.GT_Recipe_Map.sCrakingRecipes.addRecipe(
false,
- new ItemStack[] {GT_Utility.getIntegratedCircuit(circuitConfig)},
+ new ItemStack[] { GT_Utility.getIntegratedCircuit(circuitConfig) },
null,
null,
null,
- new FluidStack[] {aInput, aInput2},
- new FluidStack[] {aOutput},
+ new FluidStack[] { aInput, aInput2 },
+ new FluidStack[] { aOutput },
aDuration,
aEUt,
0);
@@ -3125,16 +2810,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addAssemblylineRecipe(
- ItemStack aResearchItem,
- int aResearchTime,
- ItemStack[] aInputs,
- FluidStack[] aFluidInputs,
- ItemStack aOutput,
- int aDuration,
- int aEUt) {
- if ((aResearchItem == null)
- || (aResearchTime <= 0)
+ public boolean addAssemblylineRecipe(ItemStack aResearchItem, int aResearchTime, ItemStack[] aInputs,
+ FluidStack[] aFluidInputs, ItemStack aOutput, int aDuration, int aEUt) {
+ if ((aResearchItem == null) || (aResearchTime <= 0)
|| (aInputs == null)
|| (aOutput == null)
|| aInputs.length > 15
@@ -3146,15 +2824,18 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
for (ItemStack tItem : aInputs) {
if (tItem == null) {
- GT_FML_LOGGER.info("addAssemblingLineRecipe " + aResearchItem.getDisplayName() + " --> "
- + aOutput.getUnlocalizedName() + " there is some null item in that recipe");
+ GT_FML_LOGGER.info(
+ "addAssemblingLineRecipe " + aResearchItem.getDisplayName()
+ + " --> "
+ + aOutput.getUnlocalizedName()
+ + " there is some null item in that recipe");
}
}
GT_Recipe.GT_Recipe_Map.sScannerFakeRecipes.addFakeRecipe(
false,
- new ItemStack[] {aResearchItem},
- new ItemStack[] {aOutput},
- new ItemStack[] {ItemList.Tool_DataStick.getWithName(1L, "Writes Research result", new Object[0])},
+ new ItemStack[] { aResearchItem },
+ new ItemStack[] { aOutput },
+ new ItemStack[] { ItemList.Tool_DataStick.getWithName(1L, "Writes Research result", new Object[0]) },
null,
null,
aResearchTime,
@@ -3163,8 +2844,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sAssemblylineVisualRecipes.addFakeRecipe(
false,
aInputs,
- new ItemStack[] {aOutput},
- new ItemStack[] {ItemList.Tool_DataStick.getWithName(1L, "Reads Research result", new Object[0])},
+ new ItemStack[] { aOutput },
+ new ItemStack[] { ItemList.Tool_DataStick.getWithName(1L, "Reads Research result", new Object[0]) },
aFluidInputs,
null,
aDuration,
@@ -3172,23 +2853,22 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
0,
false);
GT_Recipe_AssemblyLine tRecipe = new GT_Recipe_AssemblyLine(
- aResearchItem, aResearchTime, aInputs, aFluidInputs, aOutput, aDuration, aEUt);
+ aResearchItem,
+ aResearchTime,
+ aInputs,
+ aFluidInputs,
+ aOutput,
+ aDuration,
+ aEUt);
GT_Recipe.GT_Recipe_AssemblyLine.sAssemblylineRecipes.add(tRecipe);
GT_AssemblyLineUtils.addRecipeToCache(tRecipe);
return true;
}
@Override
- public boolean addAssemblylineRecipe(
- ItemStack aResearchItem,
- int aResearchTime,
- Object[] aInputs,
- FluidStack[] aFluidInputs,
- ItemStack aOutput,
- int aDuration,
- int aEUt) {
- if ((aResearchItem == null)
- || (aResearchTime <= 0)
+ public boolean addAssemblylineRecipe(ItemStack aResearchItem, int aResearchTime, Object[] aInputs,
+ FluidStack[] aFluidInputs, ItemStack aOutput, int aDuration, int aEUt) {
+ if ((aResearchItem == null) || (aResearchTime <= 0)
|| (aInputs == null)
|| (aOutput == null)
|| aInputs.length > 15
@@ -3225,11 +2905,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
if (objs.length >= 2 && !(tList = GT_OreDictUnificator.getOres(objs[0])).isEmpty()) {
try {
// sort the output, so the hash code is stable across launches
- tList.sort(Comparator.<ItemStack, String>comparing(
- s -> GameRegistry.findUniqueIdentifierFor(s.getItem()).modId)
- .thenComparing(s -> GameRegistry.findUniqueIdentifierFor(s.getItem()).modId)
- .thenComparingInt(Items.feather::getDamage)
- .thenComparingInt(s -> s.stackSize));
+ tList.sort(
+ Comparator
+ .<ItemStack, String>comparing(
+ s -> GameRegistry.findUniqueIdentifierFor(s.getItem()).modId)
+ .thenComparing(s -> GameRegistry.findUniqueIdentifierFor(s.getItem()).modId)
+ .thenComparingInt(Items.feather::getDamage).thenComparingInt(s -> s.stackSize));
int tAmount = ((Number) objs[1]).intValue();
List<ItemStack> uList = new ArrayList<>();
for (ItemStack tStack : tList) {
@@ -3243,12 +2924,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
tPersistentHash = tPersistentHash * 31 + (objs[0] == null ? "" : objs[0].toString()).hashCode();
tPersistentHash = tPersistentHash * 31 + tAmount;
continue;
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
}
- GT_FML_LOGGER.info("addAssemblingLineRecipe " + aResearchItem.getDisplayName() + " --> "
- + aOutput.getUnlocalizedName() + " there is some null item in that recipe");
+ GT_FML_LOGGER.info(
+ "addAssemblingLineRecipe " + aResearchItem.getDisplayName()
+ + " --> "
+ + aOutput.getUnlocalizedName()
+ + " there is some null item in that recipe");
}
tPersistentHash = tPersistentHash * 31 + GT_Utility.persistentHash(aResearchItem, true, false);
tPersistentHash = tPersistentHash * 31 + GT_Utility.persistentHash(aOutput, true, false);
@@ -3261,9 +2944,9 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
tPersistentHash = tPersistentHash * 31 + aEUt;
GT_Recipe.GT_Recipe_Map.sScannerFakeRecipes.addFakeRecipe(
false,
- new ItemStack[] {aResearchItem},
- new ItemStack[] {aOutput},
- new ItemStack[] {ItemList.Tool_DataStick.getWithName(1L, "Writes Research result", new Object[0])},
+ new ItemStack[] { aResearchItem },
+ new ItemStack[] { aOutput },
+ new ItemStack[] { ItemList.Tool_DataStick.getWithName(1L, "Writes Research result", new Object[0]) },
null,
null,
aResearchTime,
@@ -3272,8 +2955,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sAssemblylineVisualRecipes.addFakeRecipe(
false,
tInputs,
- new ItemStack[] {aOutput},
- new ItemStack[] {ItemList.Tool_DataStick.getWithName(1L, "Reads Research result", new Object[0])},
+ new ItemStack[] { aOutput },
+ new ItemStack[] { ItemList.Tool_DataStick.getWithName(1L, "Reads Research result", new Object[0]) },
aFluidInputs,
null,
aDuration,
@@ -3282,7 +2965,14 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
tAlts,
false);
GT_Recipe_AssemblyLine tRecipe = new GT_Recipe_AssemblyLine(
- aResearchItem, aResearchTime, tInputs, aFluidInputs, aOutput, aDuration, aEUt, tAlts);
+ aResearchItem,
+ aResearchTime,
+ tInputs,
+ aFluidInputs,
+ aOutput,
+ aDuration,
+ aEUt,
+ tAlts);
tRecipe.setPersistentHash(tPersistentHash);
GT_Recipe.GT_Recipe_AssemblyLine.sAssemblylineRecipes.add(tRecipe);
GT_AssemblyLineUtils.addRecipeToCache(tRecipe);
@@ -3290,21 +2980,16 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addCircuitAssemblerRecipe(
- ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput, int aDuration, int aEUt) {
+ public boolean addCircuitAssemblerRecipe(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput,
+ int aDuration, int aEUt) {
return addCircuitAssemblerRecipe(aInputs, aFluidInput, aOutput, aDuration, aEUt, false);
}
@Override
- public boolean addCircuitAssemblerRecipe(
- ItemStack[] aInputs,
- FluidStack aFluidInput,
- ItemStack aOutput,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addCircuitAssemblerRecipe(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput,
+ int aDuration, int aEUt, boolean aCleanroom) {
- if (this.areItemsAndFluidsBothNull(aInputs, new FluidStack[] {aFluidInput})) {
+ if (this.areItemsAndFluidsBothNull(aInputs, new FluidStack[] { aFluidInput })) {
return false;
}
@@ -3323,16 +3008,21 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
for (int oreID : OreDictionary.getOreIDs(aOutput)) {
if (OreDictionary.getOreName(oreID).startsWith("circuit")) {
return this.addCircuitAssemblerRecipeNonOredicted(
- aInputs, aFluidInput, aOutput, aDuration, aEUt, aCleanroom);
+ aInputs,
+ aFluidInput,
+ aOutput,
+ aDuration,
+ aEUt,
+ aCleanroom);
}
}
GT_Recipe.GT_Recipe_Map.sCircuitAssemblerRecipes.addRecipe(
true,
aInputs,
- new ItemStack[] {aOutput},
+ new ItemStack[] { aOutput },
null,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
aEUt,
@@ -3340,13 +3030,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return true;
}
- public boolean addCircuitAssemblerRecipeNonOredicted(
- ItemStack[] aInputs,
- FluidStack aFluidInput,
- ItemStack aOutput,
- int aDuration,
- int aEUt,
- boolean aCleanroom) {
+ public boolean addCircuitAssemblerRecipeNonOredicted(ItemStack[] aInputs, FluidStack aFluidInput, ItemStack aOutput,
+ int aDuration, int aEUt, boolean aCleanroom) {
if ((aInputs == null) || (aOutput == null) || aInputs.length > 6 || aInputs.length < 1) {
return false;
}
@@ -3359,10 +3044,10 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
GT_Recipe.GT_Recipe_Map.sCircuitAssemblerRecipes.addRecipe(
true,
aInputs,
- new ItemStack[] {aOutput},
+ new ItemStack[] { aOutput },
null,
null,
- new FluidStack[] {aFluidInput},
+ new FluidStack[] { aFluidInput },
null,
aDuration,
aEUt,
@@ -3371,30 +3056,28 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public boolean addNanoForgeRecipe(
- ItemStack[] aInputs,
- FluidStack[] aFluidInputs,
- ItemStack[] aOutputs,
- FluidStack[] aFluidOutputs,
- int[] aChances,
- int aDuration,
- int aEUt,
- int aSpecialValue) {
+ public boolean addNanoForgeRecipe(ItemStack[] aInputs, FluidStack[] aFluidInputs, ItemStack[] aOutputs,
+ FluidStack[] aFluidOutputs, int[] aChances, int aDuration, int aEUt, int aSpecialValue) {
if (aInputs == null || aOutputs == null || aSpecialValue == 0) return false;
- GT_Recipe.GT_Recipe_Map.sNanoForge.addRecipe(new GT_Recipe(
- false, aInputs, aOutputs, null, aChances, aFluidInputs, aFluidOutputs, aDuration, aEUt, aSpecialValue));
+ GT_Recipe.GT_Recipe_Map.sNanoForge.addRecipe(
+ new GT_Recipe(
+ false,
+ aInputs,
+ aOutputs,
+ null,
+ aChances,
+ aFluidInputs,
+ aFluidOutputs,
+ aDuration,
+ aEUt,
+ aSpecialValue));
return true;
}
@Override
- public boolean addPCBFactoryRecipe(
- ItemStack[] aInputs,
- FluidStack[] aFluidInputs,
- ItemStack[] aOutputs,
- int aDuration,
- int aEUt,
- int aSpecialValue) {
+ public boolean addPCBFactoryRecipe(ItemStack[] aInputs, FluidStack[] aFluidInputs, ItemStack[] aOutputs,
+ int aDuration, int aEUt, int aSpecialValue) {
if (aInputs == null || aFluidInputs == null || aOutputs == null) {
return false;
@@ -3404,20 +3087,25 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
return false;
}
- GT_Recipe.GT_Recipe_Map.sPCBFactory.addRecipe(new GT_Recipe(
- false, aInputs, aOutputs, null, null, aFluidInputs, null, aDuration, aEUt, aSpecialValue));
+ GT_Recipe.GT_Recipe_Map.sPCBFactory.addRecipe(
+ new GT_Recipe(
+ false,
+ aInputs,
+ aOutputs,
+ null,
+ null,
+ aFluidInputs,
+ null,
+ aDuration,
+ aEUt,
+ aSpecialValue));
return true;
}
@Override
- public GT_Recipe addIC2ReactorBreederCell(
- ItemStack input,
- ItemStack output,
- boolean reflector,
- int heatStep,
- int heatMultiplier,
- int requiredPulses) {
+ public GT_Recipe addIC2ReactorBreederCell(ItemStack input, ItemStack output, boolean reflector, int heatStep,
+ int heatMultiplier, int requiredPulses) {
return GT_Recipe.GT_Recipe_Map.sIC2NuclearFakeRecipe.addFakeRecipe(
input,
output,
@@ -3428,8 +3116,8 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
}
@Override
- public GT_Recipe addIC2ReactorFuelCell(
- ItemStack input, ItemStack output, boolean aMox, float aHeat, float aEnergy, int aCells) {
+ public GT_Recipe addIC2ReactorFuelCell(ItemStack input, ItemStack output, boolean aMox, float aHeat, float aEnergy,
+ int aCells) {
// for the mysterious constant 5.0f,
// see ic2.core.block.reactor.tileentity.TileEntityNuclearReactorElectric.getOfferedEnergy
// don't ask, just accept
@@ -3440,12 +3128,12 @@ public class GT_RecipeAdder implements IGT_RecipeAdder {
output,
aMox ? "MOX Model" : "Uranium Model",
"Neutron Pulse: " + aCells,
- aCells == 1
- ? String.format("Heat: %.1f * n1 * (n1 + 1)", aHeat / 2f)
+ aCells == 1 ? String.format("Heat: %.1f * n1 * (n1 + 1)", aHeat / 2f)
: String.format("Heat: %.1f * (%d + n1) * (%d + n1)", aHeat * aCells / 2f, aCells, aCells + 1),
String.format(
"Energy: %.1f + n2 * %.1f EU/t",
- aEnergy * aCells * pulses * nukePowerMult, aEnergy * nukePowerMult));
+ aEnergy * aCells * pulses * nukePowerMult,
+ aEnergy * nukePowerMult));
}
private boolean areItemsAndFluidsBothNull(ItemStack[] items, FluidStack[] fluids) {
diff --git a/src/main/java/gregtech/common/GT_Server.java b/src/main/java/gregtech/common/GT_Server.java
index 75d98e27a1..1a2d8e6b5a 100644
--- a/src/main/java/gregtech/common/GT_Server.java
+++ b/src/main/java/gregtech/common/GT_Server.java
@@ -5,6 +5,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
public class GT_Server extends GT_Proxy {
+
@Override
public boolean isServerSide() {
return true;
diff --git a/src/main/java/gregtech/common/GT_ThaumcraftCompat.java b/src/main/java/gregtech/common/GT_ThaumcraftCompat.java
index 1f7e8f4de9..3e91f876a8 100644
--- a/src/main/java/gregtech/common/GT_ThaumcraftCompat.java
+++ b/src/main/java/gregtech/common/GT_ThaumcraftCompat.java
@@ -1,18 +1,14 @@
package gregtech.common;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.ConfigCategories;
-import gregtech.api.enums.TC_Aspects;
-import gregtech.api.interfaces.internal.IThaumcraftCompat;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.item.crafting.IRecipe;
import net.minecraft.util.ResourceLocation;
+
import thaumcraft.api.ThaumcraftApi;
import thaumcraft.api.ThaumcraftApiHelper;
import thaumcraft.api.aspects.Aspect;
@@ -25,8 +21,15 @@ import thaumcraft.api.research.ResearchCategories;
import thaumcraft.api.research.ResearchCategoryList;
import thaumcraft.api.research.ResearchItem;
import thaumcraft.api.research.ResearchPage;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.ConfigCategories;
+import gregtech.api.enums.TC_Aspects;
+import gregtech.api.interfaces.internal.IThaumcraftCompat;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
public class GT_ThaumcraftCompat implements IThaumcraftCompat {
+
public GT_ThaumcraftCompat() {
TC_Aspects.AER.mAspect = Aspect.AIR;
TC_Aspects.ALIENIS.mAspect = Aspect.ELDRITCH;
@@ -81,31 +84,31 @@ public class GT_ThaumcraftCompat implements IThaumcraftCompat {
TC_Aspects.STRONTIO.mAspect = new Aspect(
"strontio",
15647411,
- new Aspect[] {Aspect.MIND, Aspect.ENTROPY},
+ new Aspect[] { Aspect.MIND, Aspect.ENTROPY },
new ResourceLocation("gregtech:textures/aspects/" + TC_Aspects.STRONTIO.name() + ".png"),
1);
TC_Aspects.NEBRISUM.mAspect = new Aspect(
"nebrisum",
15658622,
- new Aspect[] {Aspect.MINE, Aspect.GREED},
+ new Aspect[] { Aspect.MINE, Aspect.GREED },
new ResourceLocation("gregtech:textures/aspects/" + TC_Aspects.NEBRISUM.name() + ".png"),
1);
TC_Aspects.ELECTRUM.mAspect = new Aspect(
"electrum",
12644078,
- new Aspect[] {Aspect.ENERGY, Aspect.MECHANISM},
+ new Aspect[] { Aspect.ENERGY, Aspect.MECHANISM },
new ResourceLocation("gregtech:textures/aspects/" + TC_Aspects.ELECTRUM.name() + ".png"),
1);
TC_Aspects.MAGNETO.mAspect = new Aspect(
"magneto",
12632256,
- new Aspect[] {Aspect.METAL, Aspect.TRAVEL},
+ new Aspect[] { Aspect.METAL, Aspect.TRAVEL },
new ResourceLocation("gregtech:textures/aspects/" + TC_Aspects.MAGNETO.name() + ".png"),
1);
TC_Aspects.RADIO.mAspect = new Aspect(
"radio",
12648384,
- new Aspect[] {Aspect.LIGHT, Aspect.ENERGY},
+ new Aspect[] { Aspect.LIGHT, Aspect.ENERGY },
new ResourceLocation("gregtech:textures/aspects/" + TC_Aspects.RADIO.name() + ".png"),
1);
@@ -119,29 +122,17 @@ public class GT_ThaumcraftCompat implements IThaumcraftCompat {
private static final AspectList getAspectList(List<TC_Aspects.TC_AspectStack> aAspects) {
AspectList rAspects = new AspectList();
TC_Aspects.TC_AspectStack tAspect;
- for (Iterator i$ = aAspects.iterator();
- i$.hasNext();
- rAspects.add((Aspect) tAspect.mAspect.mAspect, (int) tAspect.mAmount)) {
+ for (Iterator i$ = aAspects.iterator(); i$.hasNext(); rAspects
+ .add((Aspect) tAspect.mAspect.mAspect, (int) tAspect.mAmount)) {
tAspect = (TC_Aspects.TC_AspectStack) i$.next();
}
return rAspects;
}
@Override
- public Object addResearch(
- String aResearch,
- String aName,
- String aText,
- String[] aParentResearches,
- String aCategory,
- ItemStack aIcon,
- int aComplexity,
- int aType,
- int aX,
- int aY,
- List<TC_Aspects.TC_AspectStack> aAspects,
- ItemStack[] aResearchTriggers,
- Object[] aPages) {
+ public Object addResearch(String aResearch, String aName, String aText, String[] aParentResearches,
+ String aCategory, ItemStack aIcon, int aComplexity, int aType, int aX, int aY,
+ List<TC_Aspects.TC_AspectStack> aAspects, ItemStack[] aResearchTriggers, Object[] aPages) {
if (!GregTech_API.sRecipeFile.get(ConfigCategories.Recipes.researches, aResearch, true)) {
return null;
}
@@ -149,15 +140,21 @@ public class GT_ThaumcraftCompat implements IThaumcraftCompat {
if (tCategory == null) {
return null;
}
- for (Iterator i$ = tCategory.research.values().iterator(); i$.hasNext(); ) {
+ for (Iterator i$ = tCategory.research.values().iterator(); i$.hasNext();) {
ResearchItem tResearch = (ResearchItem) i$.next();
if ((tResearch.displayColumn == aX) && (tResearch.displayRow == aY)) {
aX += (aX > 0 ? 5 : -5);
aY += (aY > 0 ? 5 : -5);
}
}
- ResearchItem rResearch =
- new ResearchItem(aResearch, aCategory, getAspectList(aAspects), aX, aY, aComplexity, aIcon);
+ ResearchItem rResearch = new ResearchItem(
+ aResearch,
+ aCategory,
+ getAspectList(aAspects),
+ aX,
+ aY,
+ aComplexity,
+ aIcon);
ArrayList<ResearchPage> tPages = new ArrayList(aPages.length);
GT_LanguageManager.addStringLocalization("tc.research_name." + aResearch, aName);
GT_LanguageManager.addStringLocalization("tc.research_text." + aResearch, "[GT] " + aText);
@@ -218,10 +215,9 @@ public class GT_ThaumcraftCompat implements IThaumcraftCompat {
}
@Override
- public Object addCrucibleRecipe(
- String aResearch, Object aInput, ItemStack aOutput, List<TC_Aspects.TC_AspectStack> aAspects) {
- if ((GT_Utility.isStringInvalid(aResearch))
- || (aInput == null)
+ public Object addCrucibleRecipe(String aResearch, Object aInput, ItemStack aOutput,
+ List<TC_Aspects.TC_AspectStack> aAspects) {
+ if ((GT_Utility.isStringInvalid(aResearch)) || (aInput == null)
|| (aOutput == null)
|| (aAspects == null)
|| (aAspects.isEmpty())) {
@@ -235,15 +231,9 @@ public class GT_ThaumcraftCompat implements IThaumcraftCompat {
}
@Override
- public Object addInfusionRecipe(
- String aResearch,
- ItemStack aMainInput,
- ItemStack[] aSideInputs,
- ItemStack aOutput,
- int aInstability,
- List<TC_Aspects.TC_AspectStack> aAspects) {
- if ((GT_Utility.isStringInvalid(aResearch))
- || (aMainInput == null)
+ public Object addInfusionRecipe(String aResearch, ItemStack aMainInput, ItemStack[] aSideInputs, ItemStack aOutput,
+ int aInstability, List<TC_Aspects.TC_AspectStack> aAspects) {
+ if ((GT_Utility.isStringInvalid(aResearch)) || (aMainInput == null)
|| (aSideInputs == null)
|| (aOutput == null)
|| (aAspects == null)
@@ -260,16 +250,16 @@ public class GT_ThaumcraftCompat implements IThaumcraftCompat {
}
@Override
- public boolean registerThaumcraftAspectsToItem(
- ItemStack aExampleStack, List<TC_Aspects.TC_AspectStack> aAspects, String aOreDict) {
+ public boolean registerThaumcraftAspectsToItem(ItemStack aExampleStack, List<TC_Aspects.TC_AspectStack> aAspects,
+ String aOreDict) {
if (aAspects.isEmpty()) return false;
ThaumcraftApi.registerObjectTag(aOreDict, (AspectList) getAspectList(aAspects));
return true;
}
@Override
- public boolean registerThaumcraftAspectsToItem(
- ItemStack aStack, List<TC_Aspects.TC_AspectStack> aAspects, boolean aAdditive) {
+ public boolean registerThaumcraftAspectsToItem(ItemStack aStack, List<TC_Aspects.TC_AspectStack> aAspects,
+ boolean aAdditive) {
if (aAspects.isEmpty()) return false;
if (aAdditive) {
ThaumcraftApi.registerComplexObjectTag(aStack, (AspectList) getAspectList(aAspects));
diff --git a/src/main/java/gregtech/common/GT_UndergroundOil.java b/src/main/java/gregtech/common/GT_UndergroundOil.java
index e7351af7c3..482ff54c02 100644
--- a/src/main/java/gregtech/common/GT_UndergroundOil.java
+++ b/src/main/java/gregtech/common/GT_UndergroundOil.java
@@ -2,36 +2,42 @@ package gregtech.common;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
-import gregtech.GT_Mod;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.objects.GT_UO_Dimension;
-import gregtech.api.objects.GT_UO_Fluid;
-import gregtech.api.objects.XSTR;
-import gregtech.api.util.GT_ChunkAssociatedData;
import java.io.DataInput;
import java.io.DataOutput;
import java.io.IOException;
import java.util.Objects;
import java.util.WeakHashMap;
+
import javax.annotation.Nullable;
import javax.annotation.ParametersAreNonnullByDefault;
+
import net.minecraft.world.World;
import net.minecraft.world.chunk.Chunk;
import net.minecraftforge.event.world.ChunkDataEvent;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
+
import org.apache.commons.lang3.tuple.Pair;
+import gregtech.GT_Mod;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.objects.GT_UO_Dimension;
+import gregtech.api.objects.GT_UO_Fluid;
+import gregtech.api.objects.XSTR;
+import gregtech.api.util.GT_ChunkAssociatedData;
+
/**
* Created by Tec on 29.04.2017.
*/
public class GT_UndergroundOil {
+
public static final short DIVIDER = 5000;
private static final GT_UndergroundOilStore STORAGE = new GT_UndergroundOilStore();
private static final ChunkData NIL_FLUID_STACK = new ChunkData(-1, null, null, false);
/**
* Effectively just call {@code undergroundOil(te, -1)} for you
+ *
* @see #undergroundOil(World, int, int, float)
*/
public static FluidStack undergroundOilReadInformation(IGregTechTileEntity te) {
@@ -40,6 +46,7 @@ public class GT_UndergroundOil {
/**
* Effectively just call {@code undergroundOil(chunk, -1)} for you
+ *
* @see #undergroundOil(World, int, int, float)
*/
public static FluidStack undergroundOilReadInformation(Chunk chunk) {
@@ -49,7 +56,8 @@ public class GT_UndergroundOil {
/** @see #undergroundOil(World, int, int, float) */
public static FluidStack undergroundOil(IGregTechTileEntity te, float readOrDrainCoefficient) {
return undergroundOil(
- te.getWorld().getChunkFromBlockCoords(te.getXCoord(), te.getZCoord()), readOrDrainCoefficient);
+ te.getWorld().getChunkFromBlockCoords(te.getXCoord(), te.getZCoord()),
+ readOrDrainCoefficient);
}
// Returns whole content for information purposes -> when drainSpeedCoefficient < 0
@@ -61,45 +69,47 @@ public class GT_UndergroundOil {
/**
* Pump fluid or read info.
- * @param w a remote World. For a WorldClient it will always tell you null
- * @param chunkX chunk coordinate X, i.e. blockX >> 4
- * @param chunkZ chunk coordinate Z, i.e. blockZ >> 4
- * @param readOrDrainCoefficient how fast to pump. The higher the faster. use negative to read expected current output
+ *
+ * @param w a remote World. For a WorldClient it will always tell you null
+ * @param chunkX chunk coordinate X, i.e. blockX >> 4
+ * @param chunkZ chunk coordinate Z, i.e. blockZ >> 4
+ * @param readOrDrainCoefficient how fast to pump. The higher the faster. use negative to read expected current
+ * output
* @return null if nothing here, or depleted already, or a client side world
*/
public static FluidStack undergroundOil(World w, int chunkX, int chunkZ, float readOrDrainCoefficient) {
if (w.isRemote) return null; // troublemakers go away
ChunkData chunkData = STORAGE.get(w, chunkX, chunkZ);
if (chunkData.getVein() == null || chunkData.getFluid() == null) // nothing here...
- return null;
+ return null;
// do stuff on it if needed
FluidStack fluidInChunk = new FluidStack(chunkData.getFluid(), 0);
if (readOrDrainCoefficient >= 0) {
int fluidExtracted = (int) Math.floor(chunkData.getAmount() * (double) readOrDrainCoefficient / DIVIDER);
double averageDecrease = chunkData.getVein().DecreasePerOperationAmount * (double) readOrDrainCoefficient;
int decrease = (int) Math.ceil(averageDecrease);
- if (fluidExtracted <= 0
- || chunkData.amount <= decrease) { // decrease - here it is max value of extraction for easy check
+ if (fluidExtracted <= 0 || chunkData.amount <= decrease) { // decrease - here it is max value of extraction
+ // for easy check
chunkData.setAmount(0);
} else {
fluidInChunk.amount = fluidExtracted; // give appropriate amount
- if (XSTR_INSTANCE.nextFloat() < (decrease - averageDecrease))
- decrease--; // use XSTR_INSTANCE to "subtract double from int"
+ if (XSTR_INSTANCE.nextFloat() < (decrease - averageDecrease)) decrease--; // use XSTR_INSTANCE to
+ // "subtract double from int"
// ex.
// averageDecrease=3.9
// decrease= ceil from 3.9 = 4
// decrease-averageDecrease=0.1 -> chance to subtract 1
// if XSTR_INSTANCE is < chance then subtract 1
- chunkData.changeAmount(
- -decrease); // diminish amount, "randomly" adjusted to double value (averageDecrease)
+ chunkData.changeAmount(-decrease); // diminish amount, "randomly" adjusted to double value
+ // (averageDecrease)
}
} else { // just get info
if (chunkData.amount <= DIVIDER) {
chunkData.setAmount(0);
} else {
// get the expected current output
- fluidInChunk.amount =
- (int) Math.floor(chunkData.getAmount() * (double) -readOrDrainCoefficient / DIVIDER);
+ fluidInChunk.amount = (int) Math
+ .floor(chunkData.getAmount() * (double) -readOrDrainCoefficient / DIVIDER);
}
}
return fluidInChunk;
@@ -107,6 +117,7 @@ public class GT_UndergroundOil {
/**
* Get the deposit as if it is never exploited
+ *
* @return UO fluid kind and amount, or null if nothing here.
*/
public static Pair<GT_UO_Fluid, Integer> getPristineAmount(World world, int chunkX, int chunkZ) {
@@ -143,29 +154,31 @@ public class GT_UndergroundOil {
* Primary functionality:
*
* <ul>
- * <li>Decouple data storage with chunk, making it possible to pump oil from unloaded chunks</li>
- * <li>Regen detection. If fluid generation config is changed, chunk fluid will be regenerated.</li>
+ * <li>Decouple data storage with chunk, making it possible to pump oil from unloaded chunks</li>
+ * <li>Regen detection. If fluid generation config is changed, chunk fluid will be regenerated.</li>
* </ul>
*
* <h2>Serialized form</h2>
* <p>
- * Since the exact file layout is controlled by the super class, here we only concern how each chunk's data is written.
+ * Since the exact file layout is controlled by the super class, here we only concern how each chunk's data is
+ * written.
* <h3>Form A: Empty Chunk</h3>
* <ol>
- * <li>4 bytes of 0 </li>
+ * <li>4 bytes of 0</li>
* </ol>
*
* <h3>Form B: Normal Chunk</h3>
* <ol>
- * <li>4 bytes unsigned integer. Vein Hash.</li>
- * <li>UTF string. Vein Key.</li>
- * <li>4 bytes signed integer. Fluid amount.</li>
+ * <li>4 bytes unsigned integer. Vein Hash.</li>
+ * <li>UTF string. Vein Key.</li>
+ * <li>4 bytes signed integer. Fluid amount.</li>
* </ol>
*
* @author glease
*/
@ParametersAreNonnullByDefault
private static class GT_UndergroundOilStore extends GT_ChunkAssociatedData<ChunkData> {
+
private static final WeakHashMap<GT_UO_Fluid, Integer> hashes = new WeakHashMap<>();
private GT_UndergroundOilStore() {
@@ -187,8 +200,8 @@ public class GT_UndergroundOil {
}
@Override
- protected GT_UndergroundOil.ChunkData readElement(
- DataInput input, int version, World world, int chunkX, int chunkZ) throws IOException {
+ protected GT_UndergroundOil.ChunkData readElement(DataInput input, int version, World world, int chunkX,
+ int chunkZ) throws IOException {
/* see class javadoc for explanation */
if (version != 0) throw new IOException("Region file corrupted");
GT_UndergroundOil.ChunkData pristine = createElement(world, chunkX, chunkZ);
@@ -202,10 +215,7 @@ public class GT_UndergroundOil {
if (hash == 0) return NIL_FLUID_STACK;
return new GT_UndergroundOil.ChunkData(
amount,
- GT_Mod.gregtechproxy
- .mUndergroundOil
- .GetDimension(world.provider.dimensionId)
- .getUOFluid(veinKey),
+ GT_Mod.gregtechproxy.mUndergroundOil.GetDimension(world.provider.dimensionId).getUOFluid(veinKey),
veinKey);
}
@@ -216,7 +226,10 @@ public class GT_UndergroundOil {
int dimensionId = world.provider.dimensionId;
GT_UO_Dimension dimension = GT_Mod.gregtechproxy.mUndergroundOil.GetDimension(dimensionId);
return new GT_UndergroundOil.ChunkData(
- pristine.getRight(), pristine.getLeft(), dimension.getUOFluidKey(pristine.getLeft()), false);
+ pristine.getRight(),
+ pristine.getLeft(),
+ dimension.getUOFluidKey(pristine.getLeft()),
+ false);
}
private static int hash(@Nullable GT_UO_Fluid fluid) {
@@ -234,6 +247,7 @@ public class GT_UndergroundOil {
* Represent the amount of fluid in a given chunk.
*/
private static final class ChunkData implements GT_ChunkAssociatedData.IData {
+
private final Fluid fluid;
@Nullable
diff --git a/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_Layer.java b/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_Layer.java
index 2a66514fe5..737cd530f7 100644
--- a/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_Layer.java
+++ b/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_Layer.java
@@ -4,20 +4,23 @@ import static gregtech.api.enums.GT_Values.debugOrevein;
import static gregtech.api.enums.GT_Values.oreveinPlacerOres;
import static gregtech.api.enums.GT_Values.oreveinPlacerOresMultiplier;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Materials;
-import gregtech.api.util.GT_Log;
-import gregtech.api.world.GT_Worldgen;
-import gregtech.common.blocks.GT_TileEntity_Ores;
import java.util.ArrayList;
import java.util.Random;
+
import net.minecraft.block.Block;
import net.minecraft.init.Blocks;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraft.world.chunk.IChunkProvider;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+import gregtech.api.util.GT_Log;
+import gregtech.api.world.GT_Worldgen;
+import gregtech.common.blocks.GT_TileEntity_Ores;
+
public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
+
public static ArrayList<GT_Worldgen_GT_Ore_Layer> sList = new ArrayList();
public static int sWeight = 0;
public final short mMinY;
@@ -46,24 +49,9 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
public final String aTextWorldgen = "worldgen.";
@Deprecated
- public GT_Worldgen_GT_Ore_Layer(
- String aName,
- boolean aDefault,
- int aMinY,
- int aMaxY,
- int aWeight,
- int aDensity,
- int aSize,
- boolean aOverworld,
- boolean aNether,
- boolean aEnd,
- boolean GC_UNUSED1,
- boolean GC_UNUSED2,
- boolean GC_UNUSED3,
- int aPrimary,
- int aSecondary,
- int aBetween,
- int aSporadic) {
+ public GT_Worldgen_GT_Ore_Layer(String aName, boolean aDefault, int aMinY, int aMaxY, int aWeight, int aDensity,
+ int aSize, boolean aOverworld, boolean aNether, boolean aEnd, boolean GC_UNUSED1, boolean GC_UNUSED2,
+ boolean GC_UNUSED3, int aPrimary, int aSecondary, int aBetween, int aSporadic) {
super(aName, sList, aDefault);
this.mOverworld = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Overworld", aOverworld);
this.mNether = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Nether", aNether);
@@ -79,22 +67,22 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
mMaxY = (short) (this.mMinY + 9);
}
this.mMaxY = mMaxY;
- this.mWeight =
- ((short) GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "RandomWeight", aWeight));
- this.mDensity =
- ((short) GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Density", aDensity));
- this.mSize = ((short)
- Math.max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Size", aSize)));
- this.mPrimaryMeta = ((short)
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "OrePrimaryLayer", aPrimary));
- this.mSecondaryMeta = ((short)
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "OreSecondaryLayer", aSecondary));
- this.mBetweenMeta = ((short)
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "OreSporadiclyInbetween", aBetween));
- this.mSporadicMeta = ((short)
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "OreSporaticlyAround", aSporadic));
- this.mRestrictBiome =
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "RestrictToBiomeName", "None");
+ this.mWeight = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "RandomWeight", aWeight));
+ this.mDensity = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "Density", aDensity));
+ this.mSize = ((short) Math
+ .max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Size", aSize)));
+ this.mPrimaryMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OrePrimaryLayer", aPrimary));
+ this.mSecondaryMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OreSecondaryLayer", aSecondary));
+ this.mBetweenMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OreSporadiclyInbetween", aBetween));
+ this.mSporadicMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OreSporaticlyAround", aSporadic));
+ this.mRestrictBiome = GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "RestrictToBiomeName", "None");
if (this.mEnabled) {
sWeight += this.mWeight;
@@ -102,24 +90,9 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
}
@Deprecated
- public GT_Worldgen_GT_Ore_Layer(
- String aName,
- boolean aDefault,
- int aMinY,
- int aMaxY,
- int aWeight,
- int aDensity,
- int aSize,
- boolean aOverworld,
- boolean aNether,
- boolean aEnd,
- boolean GC_UNUSED1,
- boolean GC_UNUSED2,
- boolean GC_UNUSED3,
- Materials aPrimary,
- Materials aSecondary,
- Materials aBetween,
- Materials aSporadic) {
+ public GT_Worldgen_GT_Ore_Layer(String aName, boolean aDefault, int aMinY, int aMaxY, int aWeight, int aDensity,
+ int aSize, boolean aOverworld, boolean aNether, boolean aEnd, boolean GC_UNUSED1, boolean GC_UNUSED2,
+ boolean GC_UNUSED3, Materials aPrimary, Materials aSecondary, Materials aBetween, Materials aSporadic) {
this(
aName,
aDefault,
@@ -137,21 +110,9 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
aSporadic);
}
- public GT_Worldgen_GT_Ore_Layer(
- String aName,
- boolean aDefault,
- int aMinY,
- int aMaxY,
- int aWeight,
- int aDensity,
- int aSize,
- boolean aOverworld,
- boolean aNether,
- boolean aEnd,
- Materials aPrimary,
- Materials aSecondary,
- Materials aBetween,
- Materials aSporadic) {
+ public GT_Worldgen_GT_Ore_Layer(String aName, boolean aDefault, int aMinY, int aMaxY, int aWeight, int aDensity,
+ int aSize, boolean aOverworld, boolean aNether, boolean aEnd, Materials aPrimary, Materials aSecondary,
+ Materials aBetween, Materials aSporadic) {
super(aName, sList, aDefault);
this.mOverworld = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Overworld", aOverworld);
this.mNether = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Nether", aNether);
@@ -164,22 +125,22 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
mMaxY = (short) (this.mMinY + 9);
}
this.mMaxY = mMaxY;
- this.mWeight =
- ((short) GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "RandomWeight", aWeight));
- this.mDensity =
- ((short) GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Density", aDensity));
- this.mSize = ((short)
- Math.max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Size", aSize)));
- this.mPrimaryMeta = ((short) GregTech_API.sWorldgenFile.get(
- aTextWorldgen + this.mWorldGenName, "OrePrimaryLayer", aPrimary.mMetaItemSubID));
- this.mSecondaryMeta = ((short) GregTech_API.sWorldgenFile.get(
- aTextWorldgen + this.mWorldGenName, "OreSecondaryLayer", aSecondary.mMetaItemSubID));
- this.mBetweenMeta = ((short) GregTech_API.sWorldgenFile.get(
- aTextWorldgen + this.mWorldGenName, "OreSporadiclyInbetween", aBetween.mMetaItemSubID));
- this.mSporadicMeta = ((short) GregTech_API.sWorldgenFile.get(
- aTextWorldgen + this.mWorldGenName, "OreSporaticlyAround", aSporadic.mMetaItemSubID));
- this.mRestrictBiome =
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "RestrictToBiomeName", "None");
+ this.mWeight = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "RandomWeight", aWeight));
+ this.mDensity = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "Density", aDensity));
+ this.mSize = ((short) Math
+ .max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Size", aSize)));
+ this.mPrimaryMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OrePrimaryLayer", aPrimary.mMetaItemSubID));
+ this.mSecondaryMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OreSecondaryLayer", aSecondary.mMetaItemSubID));
+ this.mBetweenMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OreSporadiclyInbetween", aBetween.mMetaItemSubID));
+ this.mSporadicMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "OreSporaticlyAround", aSporadic.mMetaItemSubID));
+ this.mRestrictBiome = GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "RestrictToBiomeName", "None");
if (this.mEnabled) {
sWeight += this.mWeight;
@@ -187,17 +148,8 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
}
@Override
- public int executeWorldgenChunkified(
- World aWorld,
- Random aRandom,
- String aBiome,
- int aDimensionType,
- int aChunkX,
- int aChunkZ,
- int aSeedX,
- int aSeedZ,
- IChunkProvider aChunkGenerator,
- IChunkProvider aChunkProvider) {
+ public int executeWorldgenChunkified(World aWorld, Random aRandom, String aBiome, int aDimensionType, int aChunkX,
+ int aChunkZ, int aSeedX, int aSeedZ, IChunkProvider aChunkGenerator, IChunkProvider aChunkProvider) {
if (mWorldGenName.equals("NoOresInVein")) {
if (debugOrevein) GT_Log.out.println(" NoOresInVein");
// This is a special empty orevein
@@ -206,22 +158,20 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
if (!isGenerationAllowed(
aWorld,
aDimensionType,
- ((aDimensionType == -1) && (this.mNether))
- || ((aDimensionType == 0) && (this.mOverworld))
- || ((aDimensionType == 1) && (this.mEnd))
- ? aDimensionType
- : aDimensionType ^ 0xFFFFFFFF)) {
- /* // Debug code, but spams log
- if (debugOrevein) {
- GT_Log.out.println(
- "Wrong dimension"
- );
- }
- */
+ ((aDimensionType == -1) && (this.mNether)) || ((aDimensionType == 0) && (this.mOverworld))
+ || ((aDimensionType == 1) && (this.mEnd)) ? aDimensionType : aDimensionType ^ 0xFFFFFFFF)) {
+ /*
+ * // Debug code, but spams log if (debugOrevein) { GT_Log.out.println( "Wrong dimension" ); }
+ */
return WRONG_DIMENSION;
}
- /*if (!((aWorld.provider.getDimensionName().equalsIgnoreCase("Overworld")) || (aWorld.provider.getDimensionName().equalsIgnoreCase("Nether"))||(aWorld.provider.getDimensionName().equalsIgnoreCase("Underdark"))||(aWorld.provider.getDimensionName().equalsIgnoreCase("Twilight Forest"))||(aWorld.provider.getDimensionName().equalsIgnoreCase("Underdark"))||(aWorld.provider.getDimensionName().equalsIgnoreCase("The End"))))
- return WRONG_DIMENSION;*/
+ /*
+ * if (!((aWorld.provider.getDimensionName().equalsIgnoreCase("Overworld")) ||
+ * (aWorld.provider.getDimensionName().equalsIgnoreCase("Nether"))||(aWorld.provider.getDimensionName().
+ * equalsIgnoreCase("Underdark"))||(aWorld.provider.getDimensionName().equalsIgnoreCase("Twilight Forest"))||(
+ * aWorld.provider.getDimensionName().equalsIgnoreCase("Underdark"))||(aWorld.provider.getDimensionName().
+ * equalsIgnoreCase("The End")))) return WRONG_DIMENSION;
+ */
if (!this.mRestrictBiome.equals("None") && !(this.mRestrictBiome.equals(aBiome))) {
return WRONG_BIOME;
@@ -277,45 +227,52 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
}
if (debugOrevein) {
- GT_Log.out.print("Trying Orevein:" + this.mWorldGenName + " Dimension="
- + tDimensionName + " mX="
- + aChunkX / 16 + " mZ="
- + aChunkZ / 16 + " oreseedX="
- + aSeedX / 16 + " oreseedZ="
- + aSeedZ / 16 + " cY="
- + tMinY);
+ GT_Log.out.print(
+ "Trying Orevein:" + this.mWorldGenName
+ + " Dimension="
+ + tDimensionName
+ + " mX="
+ + aChunkX / 16
+ + " mZ="
+ + aChunkZ / 16
+ + " oreseedX="
+ + aSeedX / 16
+ + " oreseedZ="
+ + aSeedZ / 16
+ + " cY="
+ + tMinY);
}
- // Adjust the density down the more chunks we are away from the oreseed. The 5 chunks surrounding the seed
+ // Adjust the density down the more chunks we are away from the oreseed. The 5 chunks surrounding the seed
// should always be max density due to truncation of Math.sqrt().
int localDensity = Math.max(
1,
- this.mDensity
- / ((int) Math.sqrt(2
- + Math.pow(aChunkX / 16 - aSeedX / 16, 2)
- + Math.pow(aChunkZ / 16 - aSeedZ / 16, 2))));
+ this.mDensity / ((int) Math
+ .sqrt(2 + Math.pow(aChunkX / 16 - aSeedX / 16, 2) + Math.pow(aChunkZ / 16 - aSeedZ / 16, 2))));
// To allow for early exit due to no ore placed in the bottom layer (probably because we are in the sky), unroll
// 1 pass through the loop
// Now we do bottom-level-first oregen, and work our way upwards.
// Layer -1 Secondary and Sporadic
- int level = tMinY - 1; // Dunno why, but the first layer is actually played one below tMinY. Go figure.
+ int level = tMinY - 1; // Dunno why, but the first layer is actually played one below tMinY. Go figure.
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0)) && (this.mSecondaryMeta > 0)) {
- if (GT_TileEntity_Ores.setOreBlock(
- aWorld, tX, level, tZ, this.mSecondaryMeta, false, isUnderdark)) {
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSecondaryMeta, false, isUnderdark)) {
placeCount[1]++;
}
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ } else
+ if ((aRandom.nextInt(7) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
if ((placeCount[1] + placeCount[3]) == 0) {
@@ -326,167 +283,179 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
for (level = tMinY; level < (tMinY + 2); level++) {
for (int tX = wX; tX < eX; tX++) {
int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ 1,
+ Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
1,
Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mSecondaryMeta > 0)) {
- if (GT_TileEntity_Ores.setOreBlock(
- aWorld, tX, level, tZ, this.mSecondaryMeta, false, isUnderdark)) {
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSecondaryMeta, false, isUnderdark)) {
placeCount[1]++;
}
} else if ((aRandom.nextInt(7) == 0)
&& ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(
- aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark)) placeCount[3]++;
- }
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
}
// Layer 2 is Secondary, in-between, and sporadic
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
- if ((aRandom.nextInt(2) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ if ((aRandom.nextInt(2) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mBetweenMeta > 0)) { // Between are reduce by 1/2 to compensate
if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mBetweenMeta, false, isUnderdark)) {
placeCount[2]++;
}
} else if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mSecondaryMeta > 0)) {
- if (GT_TileEntity_Ores.setOreBlock(
- aWorld, tX, level, tZ, this.mSecondaryMeta, false, isUnderdark)) {
- placeCount[1]++;
- }
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSecondaryMeta, false, isUnderdark)) {
+ placeCount[1]++;
+ }
+ } else
+ if ((aRandom.nextInt(7) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
level++; // Increment level to next layer
// Layer 3 is In-between, and sporadic
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
- if ((aRandom.nextInt(2) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ if ((aRandom.nextInt(2) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mBetweenMeta > 0)) { // Between are reduce by 1/2 to compensate
if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mBetweenMeta, false, isUnderdark)) {
placeCount[2]++;
}
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ } else
+ if ((aRandom.nextInt(7) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
level++; // Increment level to next layer
// Layer 4 is In-between, Primary and sporadic
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
- if ((aRandom.nextInt(2) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ if ((aRandom.nextInt(2) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mBetweenMeta > 0)) { // Between are reduce by 1/2 to compensate
if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mBetweenMeta, false, isUnderdark)) {
placeCount[2]++;
}
- } else if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mPrimaryMeta > 0)) {
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mPrimaryMeta, false, isUnderdark)) {
- placeCount[1]++;
- }
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ } else
+ if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0)) && (this.mPrimaryMeta > 0)) {
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mPrimaryMeta, false, isUnderdark)) {
+ placeCount[1]++;
+ }
+ } else if ((aRandom.nextInt(7) == 0)
+ && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
level++; // Increment level to next layer
// Layer 5 is In-between, Primary and sporadic
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
- if ((aRandom.nextInt(2) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ if ((aRandom.nextInt(2) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
&& (this.mBetweenMeta > 0)) { // Between are reduce by 1/2 to compensate
if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mBetweenMeta, false, isUnderdark)) {
placeCount[2]++;
}
- } else if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mPrimaryMeta > 0)) {
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mPrimaryMeta, false, isUnderdark)) {
- placeCount[1]++;
- }
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ } else
+ if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0)) && (this.mPrimaryMeta > 0)) {
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mPrimaryMeta, false, isUnderdark)) {
+ placeCount[1]++;
+ }
+ } else if ((aRandom.nextInt(7) == 0)
+ && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
level++; // Increment level to next layer
// Layer 6 is Primary and sporadic
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0)) && (this.mPrimaryMeta > 0)) {
if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mPrimaryMeta, false, isUnderdark)) {
placeCount[1]++;
}
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ } else
+ if ((aRandom.nextInt(7) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
level++; // Increment level to next layer
// Layer 7 is Primary and sporadic
for (int tX = wX; tX < eX; tX++) {
- int placeX = Math.max(
- 1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
+ int placeX = Math
+ .max(1, Math.max(MathHelper.abs_int(wXVein - tX), MathHelper.abs_int(eXVein - tX)) / localDensity);
for (int tZ = nZ; tZ < sZ; tZ++) {
int placeZ = Math.max(
- 1, Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
+ 1,
+ Math.max(MathHelper.abs_int(sZVein - tZ), MathHelper.abs_int(nZVein - tZ)) / localDensity);
if (((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0)) && (this.mPrimaryMeta > 0)) {
if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mPrimaryMeta, false, isUnderdark)) {
placeCount[1]++;
}
- } else if ((aRandom.nextInt(7) == 0)
- && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
- && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
- if (GT_TileEntity_Ores.setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
- placeCount[3]++;
- }
+ } else
+ if ((aRandom.nextInt(7) == 0) && ((aRandom.nextInt(placeZ) == 0) || (aRandom.nextInt(placeX) == 0))
+ && (this.mSporadicMeta > 0)) { // Sporadics are reduce by 1/7 to compensate
+ if (GT_TileEntity_Ores
+ .setOreBlock(aWorld, tX, level, tZ, this.mSporadicMeta, false, isUnderdark))
+ placeCount[3]++;
+ }
}
}
// Place small ores for the vein
@@ -517,16 +486,26 @@ public class GT_Worldgen_GT_Ore_Layer extends GT_Worldgen {
}
}
if (debugOrevein) {
- GT_Log.out.println(" wXVein" + wXVein + " eXVein"
- + eXVein + " nZVein"
- + nZVein + " sZVein"
- + sZVein + " locDen="
- + localDensity + " Den="
- + this.mDensity + " Sec="
- + placeCount[1] + " Spo="
- + placeCount[3] + " Bet="
- + placeCount[2] + " Pri="
- + placeCount[0]);
+ GT_Log.out.println(
+ " wXVein" + wXVein
+ + " eXVein"
+ + eXVein
+ + " nZVein"
+ + nZVein
+ + " sZVein"
+ + sZVein
+ + " locDen="
+ + localDensity
+ + " Den="
+ + this.mDensity
+ + " Sec="
+ + placeCount[1]
+ + " Spo="
+ + placeCount[3]
+ + " Bet="
+ + placeCount[2]
+ + " Pri="
+ + placeCount[0]);
}
// Something (at least the bottom layer must have 1 block) must have been placed, return true
return ORE_PLACED;
diff --git a/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_SmallPieces.java b/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_SmallPieces.java
index 55bd77f474..ef8850638c 100644
--- a/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_SmallPieces.java
+++ b/src/main/java/gregtech/common/GT_Worldgen_GT_Ore_SmallPieces.java
@@ -2,17 +2,20 @@ package gregtech.common;
import static gregtech.api.enums.GT_Values.debugSmallOres;
+import java.util.ArrayList;
+import java.util.Random;
+
+import net.minecraft.world.World;
+import net.minecraft.world.chunk.IChunkProvider;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.util.GT_Log;
import gregtech.api.world.GT_Worldgen;
import gregtech.common.blocks.GT_TileEntity_Ores;
-import java.util.ArrayList;
-import java.util.Random;
-import net.minecraft.world.World;
-import net.minecraft.world.chunk.IChunkProvider;
public class GT_Worldgen_GT_Ore_SmallPieces extends GT_Worldgen {
+
public final short mMinY;
public final short mMaxY;
public final short mAmount;
@@ -26,16 +29,8 @@ public class GT_Worldgen_GT_Ore_SmallPieces extends GT_Worldgen {
public static ArrayList<GT_Worldgen_GT_Ore_SmallPieces> sList = new ArrayList<GT_Worldgen_GT_Ore_SmallPieces>();
// TODO CHECK IF INSTANTIATION IS CORRECT
- public GT_Worldgen_GT_Ore_SmallPieces(
- String aName,
- boolean aDefault,
- int aMinY,
- int aMaxY,
- int aAmount,
- boolean aOverworld,
- boolean aNether,
- boolean aEnd,
- Materials aPrimary) {
+ public GT_Worldgen_GT_Ore_SmallPieces(String aName, boolean aDefault, int aMinY, int aMaxY, int aAmount,
+ boolean aOverworld, boolean aNether, boolean aEnd, Materials aPrimary) {
super(aName, GregTech_API.sWorldgenList, aDefault);
this.mOverworld = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Overworld", aOverworld);
this.mNether = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Nether", aNether);
@@ -44,27 +39,17 @@ public class GT_Worldgen_GT_Ore_SmallPieces extends GT_Worldgen {
this.mMaxY = ((short) Math.max(
this.mMinY + 1,
GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "MaxHeight", aMaxY)));
- this.mAmount = ((short)
- Math.max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Amount", aAmount)));
- this.mMeta = ((short)
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Ore", aPrimary.mMetaItemSubID));
+ this.mAmount = ((short) Math
+ .max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Amount", aAmount)));
+ this.mMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "Ore", aPrimary.mMetaItemSubID));
this.mBiome = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "BiomeName", "None");
sList.add(this);
}
- public GT_Worldgen_GT_Ore_SmallPieces(
- String aName,
- boolean aDefault,
- int aMinY,
- int aMaxY,
- int aAmount,
- boolean aOverworld,
- boolean aNether,
- boolean aEnd,
- boolean GC_UNUSED1,
- boolean GC_UNUSED2,
- boolean GC_UNUSED3,
- Materials aPrimary) {
+ public GT_Worldgen_GT_Ore_SmallPieces(String aName, boolean aDefault, int aMinY, int aMaxY, int aAmount,
+ boolean aOverworld, boolean aNether, boolean aEnd, boolean GC_UNUSED1, boolean GC_UNUSED2,
+ boolean GC_UNUSED3, Materials aPrimary) {
super(aName, GregTech_API.sWorldgenList, aDefault);
this.mOverworld = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Overworld", aOverworld);
this.mNether = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Nether", aNether);
@@ -73,35 +58,25 @@ public class GT_Worldgen_GT_Ore_SmallPieces extends GT_Worldgen {
this.mMaxY = ((short) Math.max(
this.mMinY + 1,
GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "MaxHeight", aMaxY)));
- this.mAmount = ((short)
- Math.max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Amount", aAmount)));
- this.mMeta = ((short)
- GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Ore", aPrimary.mMetaItemSubID));
+ this.mAmount = ((short) Math
+ .max(1, GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "Amount", aAmount)));
+ this.mMeta = ((short) GregTech_API.sWorldgenFile
+ .get(aTextWorldgen + this.mWorldGenName, "Ore", aPrimary.mMetaItemSubID));
this.mBiome = GregTech_API.sWorldgenFile.get(aTextWorldgen + this.mWorldGenName, "BiomeName", "None");
sList.add(this);
}
@Override
- public boolean executeWorldgen(
- World aWorld,
- Random aRandom,
- String aBiome,
- int aDimensionType,
- int aChunkX,
- int aChunkZ,
- IChunkProvider aChunkGenerator,
- IChunkProvider aChunkProvider) {
+ public boolean executeWorldgen(World aWorld, Random aRandom, String aBiome, int aDimensionType, int aChunkX,
+ int aChunkZ, IChunkProvider aChunkGenerator, IChunkProvider aChunkProvider) {
if (!this.mBiome.equals("None") && !(this.mBiome.equals(aBiome))) {
return false; // Not the correct biome for ore mix
}
if (!isGenerationAllowed(
aWorld,
aDimensionType,
- ((aDimensionType == -1) && (this.mNether))
- || ((aDimensionType == 0) && (this.mOverworld))
- || ((aDimensionType == 1) && (this.mEnd))
- ? aDimensionType
- : aDimensionType ^ 0xFFFFFFFF)) {
+ ((aDimensionType == -1) && (this.mNether)) || ((aDimensionType == 0) && (this.mOverworld))
+ || ((aDimensionType == 1) && (this.mEnd)) ? aDimensionType : aDimensionType ^ 0xFFFFFFFF)) {
return false;
}
int count = 0;
@@ -124,11 +99,16 @@ public class GT_Worldgen_GT_Ore_SmallPieces extends GT_Worldgen {
}
}
if (debugSmallOres) {
- GT_Log.out.println("Small Ore:" + this.mWorldGenName + " @ dim="
- + aDimensionType + " mX="
- + aChunkX / 16 + " mZ="
- + aChunkZ / 16 + " ore="
- + count);
+ GT_Log.out.println(
+ "Small Ore:" + this.mWorldGenName
+ + " @ dim="
+ + aDimensionType
+ + " mX="
+ + aChunkX / 16
+ + " mZ="
+ + aChunkZ / 16
+ + " ore="
+ + count);
}
return true;
}
diff --git a/src/main/java/gregtech/common/GT_Worldgen_Stone.java b/src/main/java/gregtech/common/GT_Worldgen_Stone.java
index 5ea16eae89..c75d6d6ad4 100644
--- a/src/main/java/gregtech/common/GT_Worldgen_Stone.java
+++ b/src/main/java/gregtech/common/GT_Worldgen_Stone.java
@@ -2,39 +2,53 @@ package gregtech.common;
import static gregtech.api.enums.GT_Values.debugStones;
-import gregtech.api.GregTech_API;
-import gregtech.api.objects.XSTR;
-import gregtech.api.util.GT_Log;
-import gregtech.api.world.GT_Worldgen_Ore;
-import gregtech.common.blocks.GT_Block_Ores_Abstract;
-import gregtech.common.blocks.GT_TileEntity_Ores;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Hashtable;
import java.util.Random;
+
import net.minecraft.block.Block;
import net.minecraft.init.Blocks;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraft.world.chunk.IChunkProvider;
+import gregtech.api.GregTech_API;
+import gregtech.api.objects.XSTR;
+import gregtech.api.util.GT_Log;
+import gregtech.api.world.GT_Worldgen_Ore;
+import gregtech.common.blocks.GT_Block_Ores_Abstract;
+import gregtech.common.blocks.GT_TileEntity_Ores;
+
public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
- static final double sizeConversion[] = {1, 1, 1.333333, 1.333333, 2, 2, 2, 2, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
- }; // Bias the sizes towards skinnier boulders, ie more "shafts" than dikes or sills.
+ static final double sizeConversion[] = { 1, 1, 1.333333, 1.333333, 2, 2, 2, 2, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 }; // Bias
+ // the
+ // sizes
+ // towards
+ // skinnier
+ // boulders,
+ // ie
+ // more
+ // "shafts"
+ // than
+ // dikes
+ // or
+ // sills.
public Hashtable<Long, StoneSeeds> validStoneSeeds = new Hashtable(1024);
class StoneSeeds {
+
public boolean mExists;
StoneSeeds(boolean exists) {
mExists = exists;
}
- }
- ;
+ };
class ValidSeeds {
+
public int mX;
public int mZ;
@@ -42,21 +56,10 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
this.mX = x;
this.mZ = z;
}
- }
- ;
+ };
- public GT_Worldgen_Stone(
- String aName,
- boolean aDefault,
- Block aBlock,
- int aBlockMeta,
- int aDimensionType,
- int aAmount,
- int aSize,
- int aProbability,
- int aMinY,
- int aMaxY,
- Collection<String> aBiomeList,
+ public GT_Worldgen_Stone(String aName, boolean aDefault, Block aBlock, int aBlockMeta, int aDimensionType,
+ int aAmount, int aSize, int aProbability, int aMinY, int aMaxY, Collection<String> aBiomeList,
boolean aAllowToGenerateinVoid) {
super(
aName,
@@ -74,15 +77,8 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
}
@Override
- public boolean executeWorldgen(
- World aWorld,
- Random aRandom,
- String aBiome,
- int aDimensionType,
- int aChunkX,
- int aChunkZ,
- IChunkProvider aChunkGenerator,
- IChunkProvider aChunkProvider) {
+ public boolean executeWorldgen(World aWorld, Random aRandom, String aBiome, int aDimensionType, int aChunkX,
+ int aChunkZ, IChunkProvider aChunkGenerator, IChunkProvider aChunkProvider) {
XSTR stoneRNG = new XSTR();
ArrayList<ValidSeeds> stones = new ArrayList();
@@ -105,21 +101,21 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
| ((long) z & 0x000000000fffffffL));
if (!validStoneSeeds.containsKey(hash)) {
// Determine if RNG says to add stone at this chunk
- stoneRNG.setSeed((long) aWorld.getSeed()
- ^ hash
- + Math.abs(mBlockMeta)
+ stoneRNG.setSeed(
+ (long) aWorld.getSeed() ^ hash + Math.abs(mBlockMeta)
+ Math.abs(mSize)
- + ((GregTech_API.sBlockGranites == mBlock)
- ? (32768)
- : (0))); // Don't judge me. Want different values for different block types
+ + ((GregTech_API.sBlockGranites == mBlock) ? (32768) : (0))); // Don't judge me.
+ // Want different
+ // values for
+ // different block
+ // types
if ((this.mProbability <= 1) || (stoneRNG.nextInt(this.mProbability) == 0)) {
// Add stone at this chunk
validStoneSeeds.put(hash, new StoneSeeds(true));
// Add to generation list
stones.add(new ValidSeeds(x, z));
- if (debugStones)
- GT_Log.out.println(
- "New stoneseed=" + mWorldGenName + " x=" + x + " z=" + z + " realSize=" + realSize);
+ if (debugStones) GT_Log.out.println(
+ "New stoneseed=" + mWorldGenName + " x=" + x + " z=" + z + " realSize=" + realSize);
} else {
validStoneSeeds.put(hash, new StoneSeeds(false));
}
@@ -142,16 +138,14 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
int x = stones.get(0).mX * 16;
int z = stones.get(0).mZ * 16;
- stoneRNG.setSeed((long) aWorld.getSeed()
- ^ ((long) ((aWorld.provider.dimensionId & 0xffL) << 56)
- | (((long) x & 0x000000000fffffffL) << 28)
- | ((long) z & 0x000000000fffffffL))
- + Math.abs(mBlockMeta)
+ stoneRNG.setSeed(
+ (long) aWorld.getSeed() ^ ((long) ((aWorld.provider.dimensionId & 0xffL) << 56)
+ | (((long) x & 0x000000000fffffffL) << 28)
+ | ((long) z & 0x000000000fffffffL)) + Math.abs(mBlockMeta)
+ Math.abs(mSize)
+ ((GregTech_API.sBlockGranites == mBlock) ? (32768) : (0))); // Don't judge me
- for (int i = 0;
- i < this.mAmount;
- i++) { // Not sure why you would want more than one in a chunk! Left alone though.
+ for (int i = 0; i < this.mAmount; i++) { // Not sure why you would want more than one in a chunk! Left alone
+ // though.
// Locate the stoneseed XYZ. Original code would request an isAir at the seed location, causing a chunk
// generation request.
// To reduce potential worldgen cascade, we just always try to place a ball and use the check inside the
@@ -163,9 +157,9 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
// Determine the XYZ sizes of the stoneseed
double xSize = sizeConversion[stoneRNG.nextInt(sizeConversion.length)];
- double ySize = sizeConversion[
- stoneRNG.nextInt(sizeConversion.length)
- / 2]; // Skew the ySize towards the larger sizes, more long skinny pipes
+ double ySize = sizeConversion[stoneRNG.nextInt(sizeConversion.length) / 2]; // Skew the ySize towards
+ // the larger sizes, more
+ // long skinny pipes
double zSize = sizeConversion[stoneRNG.nextInt(sizeConversion.length)];
// Equation for an ellipsoid centered around 0,0,0
@@ -183,17 +177,26 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
// If the (tY-ySize) of the stoneseed is air in the current chunk, mark the seed empty and move on.
if (aWorld.getBlock(aChunkX + 8, tMinY, aChunkZ + 8).isAir(aWorld, aChunkX + 8, tMinY, aChunkZ + 8)) {
- if (debugStones)
- GT_Log.out.println(mWorldGenName + " tX="
- + tX + " tY="
- + tY + " tZ="
- + tZ + " realSize="
- + realSize + " xSize="
- + realSize / xSize + " ySize="
- + realSize / ySize + " zSize="
- + realSize / zSize + " tMinY="
- + tMinY + " tMaxY="
- + tMaxY + " - Skipped because first requesting chunk would not contain this stone");
+ if (debugStones) GT_Log.out.println(
+ mWorldGenName + " tX="
+ + tX
+ + " tY="
+ + tY
+ + " tZ="
+ + tZ
+ + " realSize="
+ + realSize
+ + " xSize="
+ + realSize / xSize
+ + " ySize="
+ + realSize / ySize
+ + " zSize="
+ + realSize / zSize
+ + " tMinY="
+ + tMinY
+ + " tMaxY="
+ + tMaxY
+ + " - Skipped because first requesting chunk would not contain this stone");
long hash = ((long) ((aWorld.provider.dimensionId & 0xffL) << 56)
| (((long) x & 0x000000000fffffffL) << 28)
| ((long) z & 0x000000000fffffffL));
@@ -208,26 +211,37 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
int sZ = Math.max(tMinZ, aChunkZ + 8);
int nZ = Math.min(tMaxZ, aChunkZ + 8 + 16);
- if (debugStones)
- GT_Log.out.println(mWorldGenName + " tX="
- + tX + " tY="
- + tY + " tZ="
- + tZ + " realSize="
- + realSize + " xSize="
- + realSize / xSize + " ySize="
- + realSize / ySize + " zSize="
- + realSize / zSize + " wX="
- + wX + " eX="
- + eX + " tMinY="
- + tMinY + " tMaxY="
- + tMaxY + " sZ="
- + sZ + " nZ="
- + nZ);
+ if (debugStones) GT_Log.out.println(
+ mWorldGenName + " tX="
+ + tX
+ + " tY="
+ + tY
+ + " tZ="
+ + tZ
+ + " realSize="
+ + realSize
+ + " xSize="
+ + realSize / xSize
+ + " ySize="
+ + realSize / ySize
+ + " zSize="
+ + realSize / zSize
+ + " wX="
+ + wX
+ + " eX="
+ + eX
+ + " tMinY="
+ + tMinY
+ + " tMaxY="
+ + tMaxY
+ + " sZ="
+ + sZ
+ + " nZ="
+ + nZ);
double rightHandSide = realSize * realSize + 1; // Precalc the right hand side
- for (int iY = tMinY;
- iY < tMaxY;
- iY++) { // Do placement from the bottom up layer up. Maybe better on cache usage?
+ for (int iY = tMinY; iY < tMaxY; iY++) { // Do placement from the bottom up layer up. Maybe better on
+ // cache usage?
double yCalc = ((double) (iY - tY) * ySize);
yCalc = yCalc * yCalc; // (y*Sy)^2
double leftHandSize = yCalc;
@@ -238,8 +252,8 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
double xCalc = ((double) (iX - tX) * xSize);
xCalc = xCalc * xCalc;
leftHandSize = yCalc + xCalc;
- if (leftHandSize
- > rightHandSide) { // Again, if X and Y is larger than the RHS, skip to the next value
+ if (leftHandSize > rightHandSide) { // Again, if X and Y is larger than the RHS, skip to the
+ // next value
continue;
}
for (int iZ = sZ; iZ < nZ; iZ++) {
@@ -261,24 +275,41 @@ public class GT_Worldgen_Stone extends GT_Worldgen_Ore {
.overrideOreBlockMaterial(this.mBlock, (byte) this.mBlockMeta);
}
} else if (((this.mAllowToGenerateinVoid)
- && (aWorld.getBlock(iX, iY, iZ).isAir(aWorld, iX, iY, iZ)))
- || ((tTargetedBlock != null)
- && ((tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, Blocks.stone))
- || (tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, Blocks.stained_hardened_clay))
- || (tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, Blocks.cobblestone))
- || (tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, Blocks.end_stone))
- || (tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, Blocks.netherrack))
- || (tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, GregTech_API.sBlockGranites))
- || (tTargetedBlock.isReplaceableOreGen(
- aWorld, iX, iY, iZ, GregTech_API.sBlockStones))))) {
- aWorld.setBlock(iX, iY, iZ, this.mBlock, this.mBlockMeta, 0);
- }
+ && (aWorld.getBlock(iX, iY, iZ).isAir(aWorld, iX, iY, iZ)))
+ || ((tTargetedBlock != null) && ((tTargetedBlock
+ .isReplaceableOreGen(aWorld, iX, iY, iZ, Blocks.stone))
+ || (tTargetedBlock.isReplaceableOreGen(
+ aWorld,
+ iX,
+ iY,
+ iZ,
+ Blocks.stained_hardened_clay))
+ || (tTargetedBlock
+ .isReplaceableOreGen(aWorld, iX, iY, iZ, Blocks.cobblestone))
+ || (tTargetedBlock
+ .isReplaceableOreGen(aWorld, iX, iY, iZ, Blocks.end_stone))
+ || (tTargetedBlock
+ .isReplaceableOreGen(aWorld, iX, iY, iZ, Blocks.netherrack))
+ || (tTargetedBlock.isReplaceableOreGen(
+ aWorld,
+ iX,
+ iY,
+ iZ,
+ GregTech_API.sBlockGranites))
+ || (tTargetedBlock.isReplaceableOreGen(
+ aWorld,
+ iX,
+ iY,
+ iZ,
+ GregTech_API.sBlockStones))))) {
+ aWorld.setBlock(
+ iX,
+ iY,
+ iZ,
+ this.mBlock,
+ this.mBlockMeta,
+ 0);
+ }
}
}
}
diff --git a/src/main/java/gregtech/common/GT_Worldgenerator.java b/src/main/java/gregtech/common/GT_Worldgenerator.java
index fe02ed010c..8566fd769e 100644
--- a/src/main/java/gregtech/common/GT_Worldgenerator.java
+++ b/src/main/java/gregtech/common/GT_Worldgenerator.java
@@ -6,26 +6,29 @@ import static gregtech.api.enums.GT_Values.oreveinAttempts;
import static gregtech.api.enums.GT_Values.oreveinMaxPlacementAttempts;
import static gregtech.api.enums.GT_Values.oreveinPercentage;
-import cpw.mods.fml.common.IWorldGenerator;
-import cpw.mods.fml.common.registry.GameRegistry;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Materials;
-import gregtech.api.objects.XSTR;
-import gregtech.api.util.GT_Log;
-import gregtech.api.world.GT_Worldgen;
-import gregtech.common.blocks.GT_TileEntity_Ores;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Hashtable;
import java.util.List;
import java.util.Random;
+
import net.minecraft.init.Blocks;
import net.minecraft.util.MathHelper;
import net.minecraft.world.World;
import net.minecraft.world.chunk.Chunk;
import net.minecraft.world.chunk.IChunkProvider;
+import cpw.mods.fml.common.IWorldGenerator;
+import cpw.mods.fml.common.registry.GameRegistry;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+import gregtech.api.objects.XSTR;
+import gregtech.api.util.GT_Log;
+import gregtech.api.world.GT_Worldgen;
+import gregtech.common.blocks.GT_TileEntity_Ores;
+
public class GT_Worldgenerator implements IWorldGenerator {
+
private static int mEndAsteroidProbability = 300;
private static int mSize = 100;
private static int endMinSize = 50;
@@ -33,7 +36,7 @@ public class GT_Worldgenerator implements IWorldGenerator {
private static boolean endAsteroids = true;
public static List<Runnable> mList = new ArrayList();
public static HashSet<Long> ProcChunks = new HashSet<Long>();
- // This is probably not going to work. Trying to create a fake orevein to put into hashtable when there will be no
+ // This is probably not going to work. Trying to create a fake orevein to put into hashtable when there will be no
// ores in a vein.
public static GT_Worldgen_GT_Ore_Layer noOresInVein = new GT_Worldgen_GT_Ore_Layer(
"NoOresInVein",
@@ -66,45 +69,50 @@ public class GT_Worldgenerator implements IWorldGenerator {
}
@Override
- public void generate(
- Random aRandom,
- int aX,
- int aZ,
- World aWorld,
- IChunkProvider aChunkGenerator,
+ public void generate(Random aRandom, int aX, int aZ, World aWorld, IChunkProvider aChunkGenerator,
IChunkProvider aChunkProvider) {
synchronized (listLock) {
- mList.add(new WorldGenContainer(
- new XSTR(Math.abs(aRandom.nextInt()) + 1),
- aX,
- aZ,
- aWorld.provider.dimensionId,
- aWorld,
- aChunkGenerator,
- aChunkProvider,
- aWorld.getBiomeGenForCoords(aX * 16 + 8, aZ * 16 + 8).biomeName));
- if (debugWorldGen)
- GT_Log.out.println("ADD WorldSeed:" + aWorld.getSeed() + " DimId"
- + aWorld.provider.dimensionId + " chunk x:"
- + aX + " z:"
- + aZ + " SIZE: "
- + mList.size());
+ mList.add(
+ new WorldGenContainer(
+ new XSTR(Math.abs(aRandom.nextInt()) + 1),
+ aX,
+ aZ,
+ aWorld.provider.dimensionId,
+ aWorld,
+ aChunkGenerator,
+ aChunkProvider,
+ aWorld.getBiomeGenForCoords(aX * 16 + 8, aZ * 16 + 8).biomeName));
+ if (debugWorldGen) GT_Log.out.println(
+ "ADD WorldSeed:" + aWorld.getSeed()
+ + " DimId"
+ + aWorld.provider.dimensionId
+ + " chunk x:"
+ + aX
+ + " z:"
+ + aZ
+ + " SIZE: "
+ + mList.size());
}
if (!this.mIsGenerating) {
this.mIsGenerating = true;
int mList_sS = mList.size();
- mList_sS = Math.min(
- mList_sS, 5); // Run a maximum of 5 chunks at a time through worldgen. Extra chunks get done later.
+ mList_sS = Math.min(mList_sS, 5); // Run a maximum of 5 chunks at a time through worldgen. Extra chunks get
+ // done later.
for (int i = 0; i < mList_sS; i++) {
WorldGenContainer toRun = (WorldGenContainer) mList.get(0);
- if (debugWorldGen)
- GT_Log.out.println("RUN WorldSeed:" + aWorld.getSeed() + " DimId"
- + aWorld.provider.dimensionId + " chunk x:"
- + toRun.mX + " z:"
- + toRun.mZ + " SIZE: "
- + mList.size() + " i: "
- + i);
+ if (debugWorldGen) GT_Log.out.println(
+ "RUN WorldSeed:" + aWorld.getSeed()
+ + " DimId"
+ + aWorld.provider.dimensionId
+ + " chunk x:"
+ + toRun.mX
+ + " z:"
+ + toRun.mZ
+ + " SIZE: "
+ + mList.size()
+ + " i: "
+ + i);
synchronized (listLock) {
mList.remove(0);
}
@@ -115,6 +123,7 @@ public class GT_Worldgenerator implements IWorldGenerator {
}
public static class WorldGenContainer implements Runnable {
+
public final Random mRandom;
public final int mX;
public final int mZ;
@@ -124,10 +133,11 @@ public class GT_Worldgenerator implements IWorldGenerator {
public final IChunkProvider mChunkProvider;
public final String mBiome;
// Used for outputting orevein weights and bins
- // static int test=0;
+ // static int test=0;
// Local class to track which orevein seeds must be checked when doing chunkified worldgen
class NearbySeeds {
+
public int mX;
public int mZ;
@@ -140,8 +150,7 @@ public class GT_Worldgenerator implements IWorldGenerator {
public boolean equals(Object o) {
if (this == o) return true;
if (!(o instanceof GT_Worldgenerator.WorldGenContainer.NearbySeeds)) return false;
- GT_Worldgenerator.WorldGenContainer.NearbySeeds that =
- (GT_Worldgenerator.WorldGenContainer.NearbySeeds) o;
+ GT_Worldgenerator.WorldGenContainer.NearbySeeds that = (GT_Worldgenerator.WorldGenContainer.NearbySeeds) o;
if (this.mX != that.mX) return false;
return this.mZ == that.mZ;
}
@@ -152,21 +161,13 @@ public class GT_Worldgenerator implements IWorldGenerator {
result = 31 * result + this.mZ;
return result;
}
- }
- ;
+ };
public static ArrayList<GT_Worldgenerator.WorldGenContainer.NearbySeeds> seedList = new ArrayList();
// aX and aZ are now the by-chunk X and Z for the chunk of interest
- public WorldGenContainer(
- Random aRandom,
- int aX,
- int aZ,
- int aDimensionType,
- World aWorld,
- IChunkProvider aChunkGenerator,
- IChunkProvider aChunkProvider,
- String aBiome) {
+ public WorldGenContainer(Random aRandom, int aX, int aZ, int aDimensionType, World aWorld,
+ IChunkProvider aChunkGenerator, IChunkProvider aChunkProvider, String aBiome) {
this.mRandom = aRandom;
this.mX = aX;
this.mZ = aZ;
@@ -180,20 +181,20 @@ public class GT_Worldgenerator implements IWorldGenerator {
// How to evaluate oregen distribution
// - Enable debugOreveins
// - Fly around for a while, or teleport jumping ~320 blocks at a time, with
- // a 15-30s pause for worldgen to catch up
+ // a 15-30s pause for worldgen to catch up
// - Do this across a large area, at least 2000x2000 blocks for good numbers
// - Open logs\gregtech.log
- // - Using notepad++, do a Search | Find - enter "Added" for the search term
+ // - Using notepad++, do a Search | Find - enter "Added" for the search term
// - Select Find All In Current Document
// - In the Search window, right-click and Select All
// - Copy and paste to a new file
- // - Delete extraneous stuff at top, and blank line at bottom. Line count is
- // # of total oreveins
+ // - Delete extraneous stuff at top, and blank line at bottom. Line count is
+ // # of total oreveins
// - For simple spot checks, use Find All in Current Document for specific
- // oremixes, ie ore.mix.diamond, to check how many appear in the list.
+ // oremixes, ie ore.mix.diamond, to check how many appear in the list.
// - For more complex work, import file into Excel, and sort based on oremix
- // column. Drag select the oremix names, in the bottom right will be how many
- // entries to add in a seperate tab to calculate %ages.
+ // column. Drag select the oremix names, in the bottom right will be how many
+ // entries to add in a seperate tab to calculate %ages.
//
// When using the ore weights, discount or remove the high altitude veins since
// their high weight are offset by their rareness. I usually just use zero for them.
@@ -203,20 +204,20 @@ public class GT_Worldgenerator implements IWorldGenerator {
public void worldGenFindVein(int oreseedX, int oreseedZ) {
// Explanation of oreveinseed implementation.
- // (long)this.mWorld.getSeed()<<16) Deep Dark does two oregen passes, one with getSeed set to +1 the
- // original world seed. This pushes that +1 off the low bits of oreseedZ, so that the hashes are far apart
+ // (long)this.mWorld.getSeed()<<16) Deep Dark does two oregen passes, one with getSeed set to +1 the
+ // original world seed. This pushes that +1 off the low bits of oreseedZ, so that the hashes are far apart
// for the two passes.
- // ((this.mWorld.provider.dimensionId & 0xffL)<<56) Puts the dimension in the top bits of the hash, to
+ // ((this.mWorld.provider.dimensionId & 0xffL)<<56) Puts the dimension in the top bits of the hash, to
// make sure to get unique hashes per dimension
- // ((long)oreseedX & 0x000000000fffffffL) << 28) Puts the chunk X in the bits 29-55. Cuts off the top few
+ // ((long)oreseedX & 0x000000000fffffffL) << 28) Puts the chunk X in the bits 29-55. Cuts off the top few
// bits of the chunk so we have bits for dimension.
- // ( (long)oreseedZ & 0x000000000fffffffL )) Puts the chunk Z in the bits 0-27. Cuts off the top few bits
+ // ( (long)oreseedZ & 0x000000000fffffffL )) Puts the chunk Z in the bits 0-27. Cuts off the top few bits
// of the chunk so we have bits for dimension.
long oreveinSeed = ((long) this.mWorld.getSeed() << 16)
^ ((long) ((this.mWorld.provider.dimensionId & 0xffL) << 56)
| (((long) oreseedX & 0x000000000fffffffL) << 28)
- | ((long) oreseedZ
- & 0x000000000fffffffL)); // Use an RNG that is identical every time it is called for
+ | ((long) oreseedZ & 0x000000000fffffffL)); // Use an RNG that is identical every time it is
+ // called for
// this oreseed.
XSTR oreveinRNG = new XSTR(oreveinSeed);
int oreveinPercentageRoll = oreveinRNG.nextInt(100); // Roll the dice, see if we get an orevein here at all
@@ -226,18 +227,22 @@ public class GT_Worldgenerator implements IWorldGenerator {
tDimensionName = this.mWorld.provider.getDimensionName();
}
- if (debugOrevein)
- GT_Log.out.println(" Finding oreveins for oreveinSeed=" + oreveinSeed + " mX="
- + this.mX + " mZ="
- + this.mZ + " oreseedX="
- + oreseedX + " oreseedZ="
- + oreseedZ + " worldSeed="
- + this.mWorld.getSeed());
+ if (debugOrevein) GT_Log.out.println(
+ " Finding oreveins for oreveinSeed=" + oreveinSeed
+ + " mX="
+ + this.mX
+ + " mZ="
+ + this.mZ
+ + " oreseedX="
+ + oreseedX
+ + " oreseedZ="
+ + oreseedZ
+ + " worldSeed="
+ + this.mWorld.getSeed());
// Search for a valid orevein for this dimension
if (!validOreveins.containsKey(oreveinSeed)) {
- if ((oreveinPercentageRoll < oreveinPercentage)
- && (GT_Worldgen_GT_Ore_Layer.sWeight > 0)
+ if ((oreveinPercentageRoll < oreveinPercentage) && (GT_Worldgen_GT_Ore_Layer.sWeight > 0)
&& (GT_Worldgen_GT_Ore_Layer.sList.size() > 0)) {
int placementAttempts = 0;
boolean oreveinFound = false;
@@ -245,24 +250,13 @@ public class GT_Worldgenerator implements IWorldGenerator {
// Used for outputting orevein weights and bins
/*
- if( test==0 )
- {
- test = 1;
- GT_Log.out.println(
- "sWeight = " + GT_Worldgen_GT_Ore_Layer.sWeight
- );
- for (GT_Worldgen_GT_Ore_Layer tWorldGen : GT_Worldgen_GT_Ore_Layer.sList) {
- GT_Log.out.println(
- ( tWorldGen).mWorldGenName + " mWeight = " + ( tWorldGen).mWeight + " mSize = " + (tWorldGen).mSize
- );
- }
- }
- */
- for (i = 0;
- (i < oreveinAttempts)
- && (!oreveinFound)
- && (placementAttempts < oreveinMaxPlacementAttempts);
- i++) {
+ * if( test==0 ) { test = 1; GT_Log.out.println( "sWeight = " + GT_Worldgen_GT_Ore_Layer.sWeight );
+ * for (GT_Worldgen_GT_Ore_Layer tWorldGen : GT_Worldgen_GT_Ore_Layer.sList) { GT_Log.out.println( (
+ * tWorldGen).mWorldGenName + " mWeight = " + ( tWorldGen).mWeight + " mSize = " + (tWorldGen).mSize
+ * ); } }
+ */
+ for (i = 0; (i < oreveinAttempts) && (!oreveinFound)
+ && (placementAttempts < oreveinMaxPlacementAttempts); i++) {
int tRandomWeight = oreveinRNG.nextInt(GT_Worldgen_GT_Ore_Layer.sWeight);
for (GT_Worldgen_GT_Ore_Layer tWorldGen : GT_Worldgen_GT_Ore_Layer.sList) {
tRandomWeight -= (tWorldGen).mWeight;
@@ -271,7 +265,7 @@ public class GT_Worldgenerator implements IWorldGenerator {
// Adjust the seed so that this layer has a series of unique random numbers.
// Otherwise multiple attempts at this same oreseed will get the same offset and X/Z
// values. If an orevein failed, any orevein with the
- // same minimum heights would fail as well. This prevents that, giving each orevein
+ // same minimum heights would fail as well. This prevents that, giving each orevein
// a unique height each pass through here.
int placementResult = tWorldGen.executeWorldgenChunkified(
this.mWorld,
@@ -286,13 +280,16 @@ public class GT_Worldgenerator implements IWorldGenerator {
this.mChunkProvider);
switch (placementResult) {
case GT_Worldgen_GT_Ore_Layer.ORE_PLACED:
- if (debugOrevein)
- GT_Log.out.println(" Added near oreveinSeed=" + oreveinSeed + " "
- + (tWorldGen).mWorldGenName
- + " tries at oremix="
- + i + " placementAttempts="
- + placementAttempts + " dimensionName="
- + tDimensionName);
+ if (debugOrevein) GT_Log.out.println(
+ " Added near oreveinSeed=" + oreveinSeed
+ + " "
+ + (tWorldGen).mWorldGenName
+ + " tries at oremix="
+ + i
+ + " placementAttempts="
+ + placementAttempts
+ + " dimensionName="
+ + tDimensionName);
validOreveins.put(oreveinSeed, tWorldGen);
oreveinFound = true;
break;
@@ -301,37 +298,48 @@ public class GT_Worldgenerator implements IWorldGenerator {
// SHould do retry in this case until out of chances
break;
case GT_Worldgen_GT_Ore_Layer.NO_OVERLAP:
- if (debugOrevein)
- GT_Log.out.println(" Added far oreveinSeed=" + oreveinSeed + " "
- + (tWorldGen).mWorldGenName
- + " tries at oremix="
- + i + " placementAttempts="
- + placementAttempts + " dimensionName="
- + tDimensionName);
+ if (debugOrevein) GT_Log.out.println(
+ " Added far oreveinSeed=" + oreveinSeed
+ + " "
+ + (tWorldGen).mWorldGenName
+ + " tries at oremix="
+ + i
+ + " placementAttempts="
+ + placementAttempts
+ + " dimensionName="
+ + tDimensionName);
validOreveins.put(oreveinSeed, tWorldGen);
oreveinFound = true;
break;
case GT_Worldgen_GT_Ore_Layer.NO_OVERLAP_AIR_BLOCK:
- if (debugOrevein)
- GT_Log.out.println(" No overlap and air block in test spot="
- + oreveinSeed + " " + (tWorldGen).mWorldGenName
- + " tries at oremix="
- + i + " placementAttempts="
- + placementAttempts + " dimensionName="
- + tDimensionName);
+ if (debugOrevein) GT_Log.out.println(
+ " No overlap and air block in test spot=" + oreveinSeed
+ + " "
+ + (tWorldGen).mWorldGenName
+ + " tries at oremix="
+ + i
+ + " placementAttempts="
+ + placementAttempts
+ + " dimensionName="
+ + tDimensionName);
// SHould do retry in this case until out of chances
placementAttempts++;
break;
}
break; // Try the next orevein
} catch (Throwable e) {
- if (debugOrevein)
- GT_Log.out.println("Exception occurred on oreVein" + tWorldGen + " oreveinSeed="
- + oreveinSeed + " mX="
- + this.mX + " mZ="
- + this.mZ + " oreseedX="
- + oreseedX + " oreseedZ="
- + oreseedZ);
+ if (debugOrevein) GT_Log.out.println(
+ "Exception occurred on oreVein" + tWorldGen
+ + " oreveinSeed="
+ + oreveinSeed
+ + " mX="
+ + this.mX
+ + " mZ="
+ + this.mZ
+ + " oreseedX="
+ + oreseedX
+ + " oreseedZ="
+ + oreseedZ);
e.printStackTrace(GT_Log.err);
}
}
@@ -339,37 +347,50 @@ public class GT_Worldgenerator implements IWorldGenerator {
}
// Only add an empty orevein if unable to place a vein at the oreseed chunk.
if ((!oreveinFound) && (this.mX == oreseedX) && (this.mZ == oreseedZ)) {
- if (debugOrevein)
- GT_Log.out.println(" Empty oreveinSeed=" + oreveinSeed + " mX="
- + this.mX + " mZ="
- + this.mZ + " oreseedX="
- + oreseedX + " oreseedZ="
- + oreseedZ + " tries at oremix="
- + i + " placementAttempts="
- + placementAttempts + " dimensionName="
- + tDimensionName);
+ if (debugOrevein) GT_Log.out.println(
+ " Empty oreveinSeed=" + oreveinSeed
+ + " mX="
+ + this.mX
+ + " mZ="
+ + this.mZ
+ + " oreseedX="
+ + oreseedX
+ + " oreseedZ="
+ + oreseedZ
+ + " tries at oremix="
+ + i
+ + " placementAttempts="
+ + placementAttempts
+ + " dimensionName="
+ + tDimensionName);
validOreveins.put(oreveinSeed, noOresInVein);
}
} else if (oreveinPercentageRoll >= oreveinPercentage) {
- if (debugOrevein)
- GT_Log.out.println(" Skipped oreveinSeed=" + oreveinSeed + " mX="
- + this.mX + " mZ="
- + this.mZ + " oreseedX="
- + oreseedX + " oreseedZ="
- + oreseedZ + " RNG="
- + oreveinPercentageRoll + " %="
- + oreveinPercentage + " dimensionName="
- + tDimensionName);
+ if (debugOrevein) GT_Log.out.println(
+ " Skipped oreveinSeed=" + oreveinSeed
+ + " mX="
+ + this.mX
+ + " mZ="
+ + this.mZ
+ + " oreseedX="
+ + oreseedX
+ + " oreseedZ="
+ + oreseedZ
+ + " RNG="
+ + oreveinPercentageRoll
+ + " %="
+ + oreveinPercentage
+ + " dimensionName="
+ + tDimensionName);
validOreveins.put(oreveinSeed, noOresInVein);
}
} else {
// oreseed is located in the previously processed table
- if (debugOrevein)
- GT_Log.out.print(" Valid oreveinSeed=" + oreveinSeed + " validOreveins.size()="
- + validOreveins.size() + " ");
+ if (debugOrevein) GT_Log.out.print(
+ " Valid oreveinSeed=" + oreveinSeed + " validOreveins.size()=" + validOreveins.size() + " ");
GT_Worldgen_GT_Ore_Layer tWorldGen = validOreveins.get(oreveinSeed);
- oreveinRNG.setSeed(oreveinSeed
- ^ (tWorldGen.mPrimaryMeta)); // Reset RNG to only be based on oreseed X/Z and type of vein
+ oreveinRNG.setSeed(oreveinSeed ^ (tWorldGen.mPrimaryMeta)); // Reset RNG to only be based on oreseed X/Z
+ // and type of vein
int placementResult = tWorldGen.executeWorldgenChunkified(
this.mWorld,
oreveinRNG,
@@ -400,10 +421,8 @@ public class GT_Worldgenerator implements IWorldGenerator {
try {
for (GT_Worldgen tWorldGen : GregTech_API.sWorldgenList) {
/*
- if (debugWorldGen) GT_Log.out.println(
- "tWorldGen.mWorldGenName="+tWorldGen.mWorldGenName
- );
- */
+ * if (debugWorldGen) GT_Log.out.println( "tWorldGen.mWorldGenName="+tWorldGen.mWorldGenName );
+ */
tWorldGen.executeWorldgen(
this.mWorld,
this.mRandom,
@@ -459,8 +478,7 @@ public class GT_Worldgenerator implements IWorldGenerator {
// if (((tDimensionType == 1) && endAsteroids && ((mEndAsteroidProbability <= 1) ||
// (aRandom.nextInt(mEndAsteroidProbability) == 0))) || ((tDimensionName.equals("Asteroids")) && gcAsteroids
// && ((mGCAsteroidProbability <= 1) || (aRandom.nextInt(mGCAsteroidProbability) == 0)))) {
- if (((tDimensionType == 1)
- && endAsteroids
+ if (((tDimensionType == 1) && endAsteroids
&& ((mEndAsteroidProbability <= 1) || (aRandom.nextInt(mEndAsteroidProbability) == 0)))) {
short primaryMeta = 0;
short secondaryMeta = 0;
@@ -499,7 +517,7 @@ public class GT_Worldgenerator implements IWorldGenerator {
if (tDimensionType == 1) {
mSize = aRandom.nextInt((int) (endMaxSize - endMinSize));
// } else if (tDimensionName.equals("Asteroids")) {
- // mSize = aRandom.nextInt((int) (gcMaxSize - gcMinSize));
+ // mSize = aRandom.nextInt((int) (gcMaxSize - gcMinSize));
}
if ((mWorld.getBlock(tX, tY, tZ).isAir(mWorld, tX, tY, tZ))) {
float randomRadian = aRandom.nextFloat() * 3.141593F;
@@ -531,21 +549,20 @@ public class GT_Worldgenerator implements IWorldGenerator {
for (int eZ = tMinZ; eZ <= tMaxZ; eZ++) {
double zChance = (eZ + 0.5D - zCenter) / (halfLength / 2.0D);
if ((xChance * xChance + yChance * yChance + zChance * zChance < 1.0D)
- && (mWorld.getBlock(tX, tY, tZ)
- .isAir(mWorld, tX, tY, tZ))) {
+ && (mWorld.getBlock(tX, tY, tZ).isAir(mWorld, tX, tY, tZ))) {
int ranOre = aRandom.nextInt(50);
if (ranOre < 3) {
- GT_TileEntity_Ores.setOreBlock(
- mWorld, eX, eY, eZ, primaryMeta, false);
+ GT_TileEntity_Ores
+ .setOreBlock(mWorld, eX, eY, eZ, primaryMeta, false);
} else if (ranOre < 6) {
- GT_TileEntity_Ores.setOreBlock(
- mWorld, eX, eY, eZ, secondaryMeta, false);
+ GT_TileEntity_Ores
+ .setOreBlock(mWorld, eX, eY, eZ, secondaryMeta, false);
} else if (ranOre < 8) {
- GT_TileEntity_Ores.setOreBlock(
- mWorld, eX, eY, eZ, betweenMeta, false);
+ GT_TileEntity_Ores
+ .setOreBlock(mWorld, eX, eY, eZ, betweenMeta, false);
} else if (ranOre < 10) {
- GT_TileEntity_Ores.setOreBlock(
- mWorld, eX, eY, eZ, sporadicMeta, false);
+ GT_TileEntity_Ores
+ .setOreBlock(mWorld, eX, eY, eZ, sporadicMeta, false);
} else {
mWorld.setBlock(eX, eY, eZ, Blocks.end_stone, 0, 0);
}
@@ -566,9 +583,13 @@ public class GT_Worldgenerator implements IWorldGenerator {
long endTime = System.nanoTime();
long duration = (endTime - startTime);
if (debugWorldGen) {
- GT_Log.out.println(" Oregen took " + (oregenTime - leftOverTime) + " Leftover gen took "
- + (leftOverTime - startTime) + " Worldgen took "
- + duration + " nanoseconds");
+ GT_Log.out.println(
+ " Oregen took " + (oregenTime - leftOverTime)
+ + " Leftover gen took "
+ + (leftOverTime - startTime)
+ + " Worldgen took "
+ + duration
+ + " nanoseconds");
}
}
}
diff --git a/src/main/java/gregtech/common/bees/GT_AlleleBeeSpecies.java b/src/main/java/gregtech/common/bees/GT_AlleleBeeSpecies.java
index 8c8852c189..e3b916db88 100644
--- a/src/main/java/gregtech/common/bees/GT_AlleleBeeSpecies.java
+++ b/src/main/java/gregtech/common/bees/GT_AlleleBeeSpecies.java
@@ -1,24 +1,20 @@
package gregtech.common.bees;
+import java.awt.*;
+
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+
import forestry.api.apiculture.EnumBeeChromosome;
import forestry.api.apiculture.IAlleleBeeSpeciesCustom;
import forestry.api.genetics.AlleleManager;
import forestry.api.genetics.IClassification;
import forestry.apiculture.genetics.alleles.AlleleBeeSpecies;
-import java.awt.*;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
public class GT_AlleleBeeSpecies extends AlleleBeeSpecies {
- public GT_AlleleBeeSpecies(
- String uid,
- boolean dominant,
- String unlocalizedName,
- String authority,
- String unlocalizedDescription,
- IClassification branch,
- String binomial,
- Color primaryColor,
+
+ public GT_AlleleBeeSpecies(String uid, boolean dominant, String unlocalizedName, String authority,
+ String unlocalizedDescription, IClassification branch, String binomial, Color primaryColor,
Color secondaryColor) {
super(
uid,
diff --git a/src/main/java/gregtech/common/bees/GT_AlleleHelper.java b/src/main/java/gregtech/common/bees/GT_AlleleHelper.java
index 46175730e9..9143536dbd 100644
--- a/src/main/java/gregtech/common/bees/GT_AlleleHelper.java
+++ b/src/main/java/gregtech/common/bees/GT_AlleleHelper.java
@@ -1,5 +1,12 @@
package gregtech.common.bees;
+import java.util.EnumMap;
+import java.util.HashMap;
+import java.util.Locale;
+import java.util.Map;
+
+import org.apache.commons.lang3.reflect.FieldUtils;
+
import forestry.api.apiculture.EnumBeeChromosome;
import forestry.api.arboriculture.EnumTreeChromosome;
import forestry.api.genetics.*;
@@ -10,11 +17,6 @@ import forestry.core.genetics.alleles.*;
import forestry.core.utils.vect.IVect;
import forestry.plugins.PluginManager;
import gregtech.GT_Mod;
-import java.util.EnumMap;
-import java.util.HashMap;
-import java.util.Locale;
-import java.util.Map;
-import org.apache.commons.lang3.reflect.FieldUtils;
public class GT_AlleleHelper extends AlleleHelper {
@@ -33,7 +35,8 @@ public class GT_AlleleHelper extends AlleleHelper {
createAlleles(EnumAllele.Territory.class, EnumBeeChromosome.TERRITORY, EnumTreeChromosome.TERRITORY);
AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.territoryDefault", get(EnumAllele.Territory.AVERAGE));
+ "forestry.territoryDefault",
+ get(EnumAllele.Territory.AVERAGE));
}
if (PluginManager.Module.APICULTURE.isEnabled() || PluginManager.Module.LEPIDOPTEROLOGY.isEnabled()) {
@@ -50,8 +53,8 @@ public class GT_AlleleHelper extends AlleleHelper {
EnumBeeChromosome.FLOWER_PROVIDER,
EnumButterflyChromosome.FLOWER_PROVIDER);
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.speedNorm", get(EnumAllele.Speed.NORMAL));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.speedNorm", get(EnumAllele.Speed.NORMAL));
}
if (PluginManager.Module.ARBORICULTURE.isEnabled()) {
@@ -62,30 +65,33 @@ public class GT_AlleleHelper extends AlleleHelper {
createAlleles(EnumAllele.Maturation.class, EnumTreeChromosome.MATURATION);
createAlleles(EnumAllele.Sappiness.class, EnumTreeChromosome.SAPPINESS);
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.heightMax10", get(EnumAllele.Height.AVERAGE));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.saplingsDefault", get(EnumAllele.Saplings.AVERAGE));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.saplingsDouble", get(EnumAllele.Saplings.HIGH));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.saplingsTriple", get(EnumAllele.Saplings.HIGHER));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.yieldDefault", get(EnumAllele.Yield.AVERAGE));
AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.heightMax10", get(EnumAllele.Height.AVERAGE));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.saplingsDefault", get(EnumAllele.Saplings.AVERAGE));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.saplingsDouble", get(EnumAllele.Saplings.HIGH));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.saplingsTriple", get(EnumAllele.Saplings.HIGHER));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.yieldDefault", get(EnumAllele.Yield.AVERAGE));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturitySlowest", get(EnumAllele.Maturation.SLOWEST));
+ "forestry.maturitySlowest",
+ get(EnumAllele.Maturation.SLOWEST));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.maturitySlower", get(EnumAllele.Maturation.SLOWER));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.maturitySlow", get(EnumAllele.Maturation.SLOW));
AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturitySlower", get(EnumAllele.Maturation.SLOWER));
+ "forestry.maturityAverage",
+ get(EnumAllele.Maturation.AVERAGE));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.maturityFast", get(EnumAllele.Maturation.FAST));
+ AlleleManager.alleleRegistry
+ .registerDeprecatedAlleleReplacement("forestry.maturityFaster", get(EnumAllele.Maturation.FASTER));
AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturitySlow", get(EnumAllele.Maturation.SLOW));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturityAverage", get(EnumAllele.Maturation.AVERAGE));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturityFast", get(EnumAllele.Maturation.FAST));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturityFaster", get(EnumAllele.Maturation.FASTER));
- AlleleManager.alleleRegistry.registerDeprecatedAlleleReplacement(
- "forestry.maturityFastest", get(EnumAllele.Maturation.FASTEST));
+ "forestry.maturityFastest",
+ get(EnumAllele.Maturation.FASTEST));
}
if (PluginManager.Module.LEPIDOPTEROLOGY.isEnabled()) {
@@ -126,7 +132,9 @@ public class GT_AlleleHelper extends AlleleHelper {
try {
helper.alleleMaps = (Map<Class<?>, Map<?, ? extends IAllele>>) FieldUtils.readField(
- FieldUtils.getField(AlleleHelper.class, "alleleMaps", true), AlleleHelper.instance, true);
+ FieldUtils.getField(AlleleHelper.class, "alleleMaps", true),
+ AlleleHelper.instance,
+ true);
} catch (IllegalAccessException e) {
e.printStackTrace();
}
@@ -149,11 +157,11 @@ public class GT_AlleleHelper extends AlleleHelper {
}
// uncomment this once all addon mods are using the allele registration with IChromosomeType
- // Collection<IChromosomeType> validTypes = AlleleManager.alleleRegistry.getChromosomeTypes(allele);
- // if (validTypes.size() > 0 && !validTypes.contains(chromosomeType)) {
- // throw new IllegalArgumentException("Allele can't applied to this Chromosome type. Expected: " + validTypes
+ // Collection<IChromosomeType> validTypes = AlleleManager.alleleRegistry.getChromosomeTypes(allele);
+ // if (validTypes.size() > 0 && !validTypes.contains(chromosomeType)) {
+ // throw new IllegalArgumentException("Allele can't applied to this Chromosome type. Expected: " + validTypes
// + " Got: " + chromosomeType);
- // }
+ // }
alleles[chromosomeType.ordinal()] = allele;
}
@@ -182,6 +190,7 @@ public class GT_AlleleHelper extends AlleleHelper {
IAllele allele = map.get(value);
if (allele == null) {
allele = new IAllele() {
+
@Override
public String getUID() {
return "NOT_FOUND";
@@ -216,8 +225,8 @@ public class GT_AlleleHelper extends AlleleHelper {
alleleMaps.put(enumClass, map);
}
- private static <K extends IAlleleValue<V>, V> IAllele createAllele(
- String category, K enumValue, IChromosomeType... types) {
+ private static <K extends IAlleleValue<V>, V> IAllele createAllele(String category, K enumValue,
+ IChromosomeType... types) {
V value = enumValue.getValue();
boolean isDominant = enumValue.isDominant();
String name = enumValue.toString().toLowerCase(Locale.ENGLISH);
@@ -229,18 +238,22 @@ public class GT_AlleleHelper extends AlleleHelper {
return AlleleManager.alleleFactory.createInteger(modId, category, name, (Integer) value, isDominant, types);
} else if (IVect.class.isAssignableFrom(valueClass)) {
IVect area = (IVect) value;
- return AlleleManager.alleleFactory.createArea(
- modId, category, name, area.getX(), area.getY(), area.getZ(), isDominant, types);
+ return AlleleManager.alleleFactory
+ .createArea(modId, category, name, area.getX(), area.getY(), area.getZ(), isDominant, types);
} else if (Boolean.class.isAssignableFrom(valueClass)) {
return AlleleManager.alleleFactory.createBoolean(modId, category, (Boolean) value, isDominant, types);
} else if (EnumTolerance.class.isAssignableFrom(valueClass)) {
- IAlleleTolerance alleleTolerance =
- new AlleleTolerance(modId, category, name, (EnumTolerance) value, isDominant);
+ IAlleleTolerance alleleTolerance = new AlleleTolerance(
+ modId,
+ category,
+ name,
+ (EnumTolerance) value,
+ isDominant);
AlleleManager.alleleRegistry.registerAllele(alleleTolerance, types);
return alleleTolerance;
} else if (FlowerProvider.class.isAssignableFrom(valueClass)) {
- return AlleleManager.alleleFactory.createFlowers(
- modId, category, name, (FlowerProvider) value, isDominant, types);
+ return AlleleManager.alleleFactory
+ .createFlowers(modId, category, name, (FlowerProvider) value, isDominant, types);
}
throw new RuntimeException("could not create allele for category: " + category + " and value " + valueClass);
}
diff --git a/src/main/java/gregtech/common/bees/GT_Bee_Mutation.java b/src/main/java/gregtech/common/bees/GT_Bee_Mutation.java
index 357c7b9c36..7e78ef8fcd 100644
--- a/src/main/java/gregtech/common/bees/GT_Bee_Mutation.java
+++ b/src/main/java/gregtech/common/bees/GT_Bee_Mutation.java
@@ -1,5 +1,13 @@
package gregtech.common.bees;
+import java.lang.reflect.Field;
+import java.util.List;
+
+import net.minecraft.util.ChunkCoordinates;
+import net.minecraft.world.World;
+
+import org.apache.commons.lang3.reflect.FieldUtils;
+
import forestry.api.apiculture.*;
import forestry.api.core.IClimateProvider;
import forestry.api.genetics.IAllele;
@@ -7,11 +15,6 @@ import forestry.api.genetics.IGenome;
import forestry.api.genetics.IMutationCondition;
import forestry.apiculture.genetics.BeeMutation;
import forestry.core.genetics.mutations.Mutation;
-import java.lang.reflect.Field;
-import java.util.List;
-import net.minecraft.util.ChunkCoordinates;
-import net.minecraft.world.World;
-import org.apache.commons.lang3.reflect.FieldUtils;
public class GT_Bee_Mutation extends BeeMutation {
@@ -29,12 +32,8 @@ public class GT_Bee_Mutation extends BeeMutation {
}
@Override
- public float getChance(
- IBeeHousing housing,
- IAlleleBeeSpecies allele0,
- IAlleleBeeSpecies allele1,
- IBeeGenome genome0,
- IBeeGenome genome1) {
+ public float getChance(IBeeHousing housing, IAlleleBeeSpecies allele0, IAlleleBeeSpecies allele1,
+ IBeeGenome genome0, IBeeGenome genome1) {
World world = housing != null ? housing.getWorld() : null;
ChunkCoordinates housingCoordinates = housing != null ? housing.getCoordinates() : null;
int x = housingCoordinates != null ? housingCoordinates.posX : 0;
@@ -48,8 +47,7 @@ public class GT_Bee_Mutation extends BeeMutation {
}
IBeeModifier beeHousingModifier = BeeManager.beeRoot.createBeeHousingModifier(housing);
- IBeeModifier beeModeModifier =
- BeeManager.beeRoot.getBeekeepingMode(world).getBeeModifier();
+ IBeeModifier beeModeModifier = BeeManager.beeRoot.getBeekeepingMode(world).getBeeModifier();
processedChance *= beeHousingModifier.getMutationModifier(genome0, genome1, processedChance);
processedChance *= beeModeModifier.getMutationModifier(genome0, genome1, processedChance);
@@ -58,16 +56,8 @@ public class GT_Bee_Mutation extends BeeMutation {
}
@SuppressWarnings("unchecked")
- private float getBasicChance(
- World world,
- int x,
- int y,
- int z,
- IAllele allele0,
- IAllele allele1,
- IGenome genome0,
- IGenome genome1,
- IClimateProvider climate) {
+ private float getBasicChance(World world, int x, int y, int z, IAllele allele0, IAllele allele1, IGenome genome0,
+ IGenome genome1, IClimateProvider climate) {
float mutationChance = this.getBaseChance();
List<IMutationCondition> mutationConditions = null;
Field f = FieldUtils.getDeclaredField(Mutation.class, "mutationConditions", true);
@@ -79,14 +69,12 @@ public class GT_Bee_Mutation extends BeeMutation {
e.printStackTrace();
}
- if (mutationConditions != null)
- for (IMutationCondition mutationCondition : mutationConditions) {
- mutationChance *=
- mutationCondition.getChance(world, x, y, z, allele0, allele1, genome0, genome1, climate);
- if (mutationChance == 0) {
- return 0;
- }
+ if (mutationConditions != null) for (IMutationCondition mutationCondition : mutationConditions) {
+ mutationChance *= mutationCondition.getChance(world, x, y, z, allele0, allele1, genome0, genome1, climate);
+ if (mutationChance == 0) {
+ return 0;
}
+ }
return mutationChance;
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java
index 3f717b4d79..7d04a7bde3 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings1.java
@@ -1,26 +1,22 @@
package gregtech.common.blocks;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Textures;
-import gregtech.api.util.GT_LanguageManager;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Textures;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Block_Casings1 extends GT_Block_Casings_Abstract {
/**
- * Texture Index Information
- * Textures.BlockIcons.casingTexturePages[0][0-63] - Gregtech
- * Textures.BlockIcons.casingTexturePages[0][64-127] - GT++
- * Textures.BlockIcons.casingTexturePages[1][0-127] - Gregtech
- * Textures.BlockIcons.casingTexturePages[2][0-127] - Free
- * Textures.BlockIcons.casingTexturePages[3][0-127] - Free
- * Textures.BlockIcons.casingTexturePages[4][0-127] - Free
- * Textures.BlockIcons.casingTexturePages[5][0-127] - Free
- * Textures.BlockIcons.casingTexturePages[6][0-127] - Free
- * Textures.BlockIcons.casingTexturePages[7][0-127] - TecTech
- * Textures.BlockIcons.casingTexturePages[8][0-127] - TecTech
+ * Texture Index Information Textures.BlockIcons.casingTexturePages[0][0-63] - Gregtech
+ * Textures.BlockIcons.casingTexturePages[0][64-127] - GT++ Textures.BlockIcons.casingTexturePages[1][0-127] -
+ * Gregtech Textures.BlockIcons.casingTexturePages[2][0-127] - Free Textures.BlockIcons.casingTexturePages[3][0-127]
+ * - Free Textures.BlockIcons.casingTexturePages[4][0-127] - Free Textures.BlockIcons.casingTexturePages[5][0-127] -
+ * Free Textures.BlockIcons.casingTexturePages[6][0-127] - Free Textures.BlockIcons.casingTexturePages[7][0-127] -
+ * TecTech Textures.BlockIcons.casingTexturePages[8][0-127] - TecTech
*/
public GT_Block_Casings1() {
super(GT_Item_Casings1.class, "gt.blockcasings", GT_Material_Casings.INSTANCE, 16);
@@ -37,8 +33,8 @@ public class GT_Block_Casings1 extends GT_Block_Casings_Abstract {
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "UHV Machine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Bronze Plated Bricks");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Heat Proof Machine Casing");
- GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".12.name", "Dimensionally Transcendent Casing");
+ GT_LanguageManager
+ .addStringLocalization(getUnlocalizedName() + ".12.name", "Dimensionally Transcendent Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".13.name", "Dimensional Injection Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Dimensional Bridge");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Superconducting Coil Block");
@@ -95,8 +91,7 @@ public class GT_Block_Casings1 extends GT_Block_Casings_Abstract {
@Override
public int colorMultiplier(IBlockAccess aWorld, int aX, int aY, int aZ) {
- return aWorld.getBlockMetadata(aX, aY, aZ) > 9
- ? super.colorMultiplier(aWorld, aX, aY, aZ)
+ return aWorld.getBlockMetadata(aX, aY, aZ) > 9 ? super.colorMultiplier(aWorld, aX, aY, aZ)
: gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[0] << 16
| gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[1] << 8
| gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[2];
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java
index 7ee9472308..044806874b 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings2.java
@@ -1,10 +1,5 @@
package gregtech.common.blocks;
-import gregtech.api.enums.Dyes;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Textures;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_LanguageManager;
import net.minecraft.block.Block;
import net.minecraft.entity.Entity;
import net.minecraft.init.Blocks;
@@ -13,7 +8,14 @@ import net.minecraft.util.IIcon;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.enums.Dyes;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Textures;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Block_Casings2 extends GT_Block_Casings_Abstract {
+
public GT_Block_Casings2() {
super(GT_Item_Casings2.class, "gt.blockcasings2", GT_Material_Casings.INSTANCE, 96);
// Special handler for Pyrolyse Oven Casing on hatches...
@@ -102,10 +104,9 @@ public class GT_Block_Casings2 extends GT_Block_Casings_Abstract {
}
@Override
- public float getExplosionResistance(
- Entity aTNT, World aWorld, int aX, int aY, int aZ, double eX, double eY, double eZ) {
- return aWorld.getBlockMetadata(aX, aY, aZ) == 8
- ? Blocks.bedrock.getExplosionResistance(aTNT)
+ public float getExplosionResistance(Entity aTNT, World aWorld, int aX, int aY, int aZ, double eX, double eY,
+ double eZ) {
+ return aWorld.getBlockMetadata(aX, aY, aZ) == 8 ? Blocks.bedrock.getExplosionResistance(aTNT)
: super.getExplosionResistance(aTNT, aWorld, aX, aY, aZ, eX, eY, eZ);
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java
index 677c457678..aef025d08f 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings3.java
@@ -1,12 +1,14 @@
package gregtech.common.blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
import gregtech.api.util.GT_LanguageManager;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
public class GT_Block_Casings3 extends GT_Block_Casings_Abstract {
+
public GT_Block_Casings3() {
super(GT_Item_Casings3.class, "gt.blockcasings3", GT_Material_Casings.INSTANCE, 16);
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Yellow Stripes Block");
@@ -78,16 +80,13 @@ public class GT_Block_Casings3 extends GT_Block_Casings_Abstract {
case 12:
return Textures.BlockIcons.MACHINE_CASING_RADIATIONPROOF.getIcon();
case 13:
- return aSide > 1
- ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_BRONZE.getIcon()
+ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_BRONZE.getIcon()
: Textures.BlockIcons.MACHINE_BRONZEPLATEDBRICKS.getIcon();
case 14:
- return aSide > 1
- ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_STEEL.getIcon()
+ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_STEEL.getIcon()
: Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
case 15:
- return aSide > 1
- ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TUNGSTENSTEEL.getIcon()
+ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TUNGSTENSTEEL.getIcon()
: Textures.BlockIcons.MACHINE_CASING_ROBUST_TUNGSTENSTEEL.getIcon();
}
return Textures.BlockIcons.MACHINE_CASING_SOLID_STEEL.getIcon();
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java
index 62c7649dc2..087818d099 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings4.java
@@ -1,5 +1,10 @@
package gregtech.common.blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.IIcon;
+import net.minecraft.world.IBlockAccess;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.GT_Mod;
@@ -9,58 +14,42 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_RenderingWorld;
import gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_LargeTurbine;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.IBlockAccess;
public class GT_Block_Casings4 extends GT_Block_Casings_Abstract {
+
/**
* This mapping is used to look up which texture should be used to render the connected texture for fusion casings.
*
- * This mapping is computed from that giant if ladder from #getIcon in commit da3421547afadc49938b5b6a7f9a9679afa1d570
- * The exact meaning of these numbers are like black magic. Read the original getIcon implementation to understand why
- * it is 0, 1, etc, if that if ladder is even intelligible.
+ * This mapping is computed from that giant if ladder from #getIcon in commit
+ * da3421547afadc49938b5b6a7f9a9679afa1d570 The exact meaning of these numbers are like black magic. Read the
+ * original getIcon implementation to understand why it is 0, 1, etc, if that if ladder is even intelligible.
*/
private static final int[][] mapping = new int[][] {
- {
- 7, 7, 7, 7, 0, 7, 0, 7, 1, 7, 1, 7, 8, 7, 8, 7, 0, 7, 0, 7, 0, 7, 0, 7, 9, 7, 9, 7, 3, 7, 3, 7, 1, 7, 1, 7,
- 11, 7, 11, 7, 1, 7, 1, 7, 2, 7, 2, 7, 10, 7, 10, 7, 5, 7, 5, 7, 4, 7, 4, 7, 6, 7, 6, 7
- },
- {
- 7, 7, 7, 7, 0, 0, 7, 7, 1, 1, 7, 7, 8, 8, 7, 7, 0, 0, 7, 7, 0, 0, 7, 7, 9, 9, 7, 7, 3, 3, 7, 7, 1, 1, 7, 7,
- 11, 11, 7, 7, 1, 1, 7, 7, 2, 2, 7, 7, 10, 10, 7, 7, 5, 5, 7, 7, 4, 4, 7, 7, 6, 6, 7, 7
- },
- {
- 7, 1, 1, 1, 0, 9, 10, 4, 7, 1, 1, 1, 0, 9, 10, 4, 0, 8, 11, 2, 0, 3, 5, 6, 0, 8, 11, 2, 0, 3, 5, 6, 7, 7, 7,
- 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7
- },
- {
- 7, 1, 1, 1, 0, 8, 11, 2, 7, 7, 7, 7, 7, 7, 7, 7, 0, 9, 10, 4, 0, 3, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 1, 1,
- 1, 0, 8, 11, 2, 7, 7, 7, 7, 7, 7, 7, 7, 0, 9, 10, 4, 0, 3, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7
- },
- {
- 7, 1, 1, 1, 7, 1, 1, 1, 0, 8, 11, 2, 0, 8, 11, 2, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 0, 9, 10,
- 4, 0, 9, 10, 4, 0, 3, 5, 6, 0, 3, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7
- },
- {
- 7, 1, 1, 1, 7, 7, 7, 7, 0, 9, 10, 4, 7, 7, 7, 7, 7, 1, 1, 1, 7, 7, 7, 7, 0, 9, 10, 4, 7, 7, 7, 7, 0, 8, 11,
- 2, 7, 7, 7, 7, 0, 3, 5, 6, 7, 7, 7, 7, 0, 8, 11, 2, 7, 7, 7, 7, 0, 3, 5, 6, 7, 7, 7, 7
- },
- };
+ { 7, 7, 7, 7, 0, 7, 0, 7, 1, 7, 1, 7, 8, 7, 8, 7, 0, 7, 0, 7, 0, 7, 0, 7, 9, 7, 9, 7, 3, 7, 3, 7, 1, 7, 1,
+ 7, 11, 7, 11, 7, 1, 7, 1, 7, 2, 7, 2, 7, 10, 7, 10, 7, 5, 7, 5, 7, 4, 7, 4, 7, 6, 7, 6, 7 },
+ { 7, 7, 7, 7, 0, 0, 7, 7, 1, 1, 7, 7, 8, 8, 7, 7, 0, 0, 7, 7, 0, 0, 7, 7, 9, 9, 7, 7, 3, 3, 7, 7, 1, 1, 7,
+ 7, 11, 11, 7, 7, 1, 1, 7, 7, 2, 2, 7, 7, 10, 10, 7, 7, 5, 5, 7, 7, 4, 4, 7, 7, 6, 6, 7, 7 },
+ { 7, 1, 1, 1, 0, 9, 10, 4, 7, 1, 1, 1, 0, 9, 10, 4, 0, 8, 11, 2, 0, 3, 5, 6, 0, 8, 11, 2, 0, 3, 5, 6, 7, 7,
+ 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7 },
+ { 7, 1, 1, 1, 0, 8, 11, 2, 7, 7, 7, 7, 7, 7, 7, 7, 0, 9, 10, 4, 0, 3, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 1, 1,
+ 1, 0, 8, 11, 2, 7, 7, 7, 7, 7, 7, 7, 7, 0, 9, 10, 4, 0, 3, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7 },
+ { 7, 1, 1, 1, 7, 1, 1, 1, 0, 8, 11, 2, 0, 8, 11, 2, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 0, 9,
+ 10, 4, 0, 9, 10, 4, 0, 3, 5, 6, 0, 3, 5, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7 },
+ { 7, 1, 1, 1, 7, 7, 7, 7, 0, 9, 10, 4, 7, 7, 7, 7, 7, 1, 1, 1, 7, 7, 7, 7, 0, 9, 10, 4, 7, 7, 7, 7, 0, 8,
+ 11, 2, 7, 7, 7, 7, 0, 3, 5, 6, 7, 7, 7, 7, 0, 8, 11, 2, 7, 7, 7, 7, 0, 3, 5, 6, 7, 7, 7, 7 }, };
public static boolean mConnectedMachineTextures = true;
public GT_Block_Casings4() {
super(GT_Item_Casings4.class, "gt.blockcasings4", GT_Material_Casings.INSTANCE, 16);
- GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".0.name", "Robust Tungstensteel Machine Casing");
- GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".1.name", "Clean Stainless Steel Machine Casing");
+ GT_LanguageManager
+ .addStringLocalization(getUnlocalizedName() + ".0.name", "Robust Tungstensteel Machine Casing");
+ GT_LanguageManager
+ .addStringLocalization(getUnlocalizedName() + ".1.name", "Clean Stainless Steel Machine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".2.name", "Stable Titanium Machine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Titanium Firebox Casing");
- // GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Fusion Casing");
- // GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Fusion Casing");
+ // GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Fusion Casing");
+ // GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".5.name", "Fusion Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".6.name", "Fusion Machine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".7.name", "Fusion Coil Block");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Fusion Machine Casing MK II");
@@ -109,8 +98,7 @@ public class GT_Block_Casings4 extends GT_Block_Casings_Abstract {
case 11:
return Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon();
case 3:
- return aSide > 1
- ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TITANIUM.getIcon()
+ return aSide > 1 ? Textures.BlockIcons.MACHINE_CASING_FIREBOX_TITANIUM.getIcon()
: Textures.BlockIcons.MACHINE_CASING_STABLE_TITANIUM.getIcon();
case 4:
// Do not overwrite!
@@ -140,20 +128,16 @@ public class GT_Block_Casings4 extends GT_Block_Casings_Abstract {
public IIcon getTurbineCasing(int meta, int iconIndex, boolean active) {
switch (meta) {
case 10:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE1[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE1[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE1[iconIndex].getIcon();
case 11:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE2[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE2[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE2[iconIndex].getIcon();
case 12:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE3[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE3[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE3[iconIndex].getIcon();
default:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE[iconIndex].getIcon();
}
}
@@ -162,28 +146,20 @@ public class GT_Block_Casings4 extends GT_Block_Casings_Abstract {
public IIcon getTurbineCasing(int meta, int iconIndex, boolean active, boolean hasTurbine) {
switch (meta) {
case 10:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE1[iconIndex].getIcon()
- : hasTurbine
- ? Textures.BlockIcons.TURBINE1[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE1[iconIndex].getIcon()
+ : hasTurbine ? Textures.BlockIcons.TURBINE1[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE_EMPTY1[iconIndex].getIcon();
case 11:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE2[iconIndex].getIcon()
- : hasTurbine
- ? Textures.BlockIcons.TURBINE2[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE2[iconIndex].getIcon()
+ : hasTurbine ? Textures.BlockIcons.TURBINE2[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE_EMPTY2[iconIndex].getIcon();
case 12:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE3[iconIndex].getIcon()
- : hasTurbine
- ? Textures.BlockIcons.TURBINE3[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE3[iconIndex].getIcon()
+ : hasTurbine ? Textures.BlockIcons.TURBINE3[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE_EMPTY3[iconIndex].getIcon();
default:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
- : hasTurbine
- ? Textures.BlockIcons.TURBINE[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
+ : hasTurbine ? Textures.BlockIcons.TURBINE[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE_EMPTY[iconIndex].getIcon();
}
}
@@ -233,7 +209,10 @@ public class GT_Block_Casings4 extends GT_Block_Casings_Abstract {
if ((tState = isTurbineControllerWithSide(aWorld, xCoord + j, yCoord + i, zCoord, aSide))
!= 0) {
return getTurbineCasing(
- tMeta, 4 + i * 3 - j * tInvertLeftRightMod, tState == 1, tState == 2);
+ tMeta,
+ 4 + i * 3 - j * tInvertLeftRightMod,
+ tState == 1,
+ tState == 2);
}
}
}
@@ -246,7 +225,10 @@ public class GT_Block_Casings4 extends GT_Block_Casings_Abstract {
if ((tState = isTurbineControllerWithSide(aWorld, xCoord, yCoord + i, zCoord + j, aSide))
!= 0) {
return getTurbineCasing(
- tMeta, 4 + i * 3 + j * tInvertLeftRightMod, tState == 1, tState == 2);
+ tMeta,
+ 4 + i * 3 + j * tInvertLeftRightMod,
+ tState == 1,
+ tState == 2);
}
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings5.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings5.java
index c02bc79206..364d6e0eed 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings5.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings5.java
@@ -2,6 +2,11 @@ package gregtech.common.blocks;
import static gregtech.api.enums.HeatingCoilLevel.*;
+import java.util.function.Consumer;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.enums.HeatingCoilLevel;
@@ -9,9 +14,6 @@ import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IHeatingCoil;
import gregtech.api.util.GT_LanguageManager;
-import java.util.function.Consumer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
public class GT_Block_Casings5 extends GT_Block_Casings_Abstract implements IHeatingCoil {
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings6.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings6.java
index 0b6b89198a..177b5bdbe7 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings6.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings6.java
@@ -1,15 +1,17 @@
package gregtech.common.blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+import net.minecraft.world.IBlockAccess;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
import gregtech.api.util.GT_LanguageManager;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.IBlockAccess;
public class GT_Block_Casings6 extends GT_Block_Casings_Abstract {
+
public GT_Block_Casings6() {
super(GT_Item_Casings6.class, "gt.blockcasings6", GT_Material_Casings.INSTANCE, 16);
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings8.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings8.java
index 03f7262219..bda180b45d 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings8.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings8.java
@@ -1,5 +1,10 @@
package gregtech.common.blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.IIcon;
+import net.minecraft.world.IBlockAccess;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.enums.ItemList;
@@ -8,20 +13,16 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_RenderingWorld;
import gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_LargeTurbine;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.IBlockAccess;
public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
+
public static boolean mConnectedMachineTextures = true;
// WATCH OUT FOR TEXTURE ID's
public GT_Block_Casings8() {
super(GT_Item_Casings8.class, "gt.blockcasings8", GT_Material_Casings.INSTANCE, 15);
/*
- * DO NOT USE INDEX 15 !
- * USED HERE: https://github.com/GTNewHorizons/Electro-Magic-Tools/pull/17
+ * DO NOT USE INDEX 15 ! USED HERE: https://github.com/GTNewHorizons/Electro-Magic-Tools/pull/17
*/
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "Chemically Inert Machine Casing");
@@ -30,20 +31,24 @@ public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".3.name", "Mining Black Plutonium Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".4.name", "Extreme Engine Intake Casing");
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".5.name", "Europium Reinforced Radiation Proof Machine Casing");
- GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".6.name", "Advanced Rhodium Plated Palladium Machine Casing");
+ getUnlocalizedName() + ".5.name",
+ "Europium Reinforced Radiation Proof Machine Casing");
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".7.name", "Advanced Iridium Plated Machine Casing");
+ getUnlocalizedName() + ".6.name",
+ "Advanced Rhodium Plated Palladium Machine Casing");
+ GT_LanguageManager
+ .addStringLocalization(getUnlocalizedName() + ".7.name", "Advanced Iridium Plated Machine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".8.name", "Magical Machine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".9.name", "HSS-S Turbine Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".10.name", "Radiant Naquadah Alloy Casing");
+ GT_LanguageManager
+ .addStringLocalization(getUnlocalizedName() + ".11.name", "Basic Photolithographic Framework Casing");
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".11.name", "Basic Photolithographic Framework Casing");
- GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".12.name", "Reinforced Photolithographic Framework Casing");
+ getUnlocalizedName() + ".12.name",
+ "Reinforced Photolithographic Framework Casing");
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".13.name", "Radiation Proof Photolithographic Framework Casing");
+ getUnlocalizedName() + ".13.name",
+ "Radiation Proof Photolithographic Framework Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".14.name", "Infinity Cooled Casing");
ItemList.Casing_Chemically_Inert.set(new ItemStack(this, 1, 0));
@@ -81,8 +86,8 @@ public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
case 3:
return Textures.BlockIcons.MACHINE_CASING_MINING_BLACKPLUTONIUM.getIcon();
case 4:
- return Textures.BlockIcons.MACHINE_CASING_EXTREME_ENGINE_INTAKE
- .getIcon(); // changed color in a terrible way
+ return Textures.BlockIcons.MACHINE_CASING_EXTREME_ENGINE_INTAKE.getIcon(); // changed color in a
+ // terrible way
case 5:
return Textures.BlockIcons.MACHINE_CASING_ADVANCEDRADIATIONPROOF.getIcon();
case 6:
@@ -111,12 +116,10 @@ public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
public IIcon getTurbineCasing(int meta, int iconIndex, boolean active) {
switch (meta) {
case 9:
- return active
- ? Textures.BlockIcons.TURBINE_ADVGASACTIVE[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ADVGASACTIVE[iconIndex].getIcon()
: Textures.BlockIcons.TURBINEADVGAS[iconIndex].getIcon();
default:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE[iconIndex].getIcon();
}
}
@@ -124,16 +127,12 @@ public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
public IIcon getTurbineCasing(int meta, int iconIndex, boolean active, boolean hasTurbine) {
switch (meta) {
case 9:
- return active
- ? Textures.BlockIcons.TURBINE_ADVGASACTIVE[iconIndex].getIcon()
- : hasTurbine
- ? Textures.BlockIcons.TURBINEADVGAS[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ADVGASACTIVE[iconIndex].getIcon()
+ : hasTurbine ? Textures.BlockIcons.TURBINEADVGAS[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE_ADVGASEMPTY[iconIndex].getIcon();
default:
- return active
- ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
- : hasTurbine
- ? Textures.BlockIcons.TURBINE[iconIndex].getIcon()
+ return active ? Textures.BlockIcons.TURBINE_ACTIVE[iconIndex].getIcon()
+ : hasTurbine ? Textures.BlockIcons.TURBINE[iconIndex].getIcon()
: Textures.BlockIcons.TURBINE_EMPTY[iconIndex].getIcon();
}
}
@@ -182,7 +181,10 @@ public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
if ((tState = isTurbineControllerWithSide(aWorld, xCoord + j, yCoord + i, zCoord, aSide))
!= 0) {
return getTurbineCasing(
- tMeta, 4 + i * 3 - j * tInvertLeftRightMod, tState == 1, tState == 2);
+ tMeta,
+ 4 + i * 3 - j * tInvertLeftRightMod,
+ tState == 1,
+ tState == 2);
}
}
}
@@ -195,7 +197,10 @@ public class GT_Block_Casings8 extends GT_Block_Casings_Abstract {
if ((tState = isTurbineControllerWithSide(aWorld, xCoord, yCoord + i, zCoord + j, aSide))
!= 0) {
return getTurbineCasing(
- tMeta, 4 + i * 3 + j * tInvertLeftRightMod, tState == 1, tState == 2);
+ tMeta,
+ 4 + i * 3 + j * tInvertLeftRightMod,
+ tState == 1,
+ tState == 2);
}
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings9.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings9.java
index 423cc1da9a..55e0f508d5 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings9.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings9.java
@@ -1,20 +1,22 @@
package gregtech.common.blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
import gregtech.api.util.GT_LanguageManager;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
public class GT_Block_Casings9 extends GT_Block_Casings_Abstract {
+
public GT_Block_Casings9() {
super(GT_Item_Casings9.class, "gt.blockcasings9", GT_Material_Casings.INSTANCE, 2);
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".0.name", "PBI Pipe Casing");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".1.name", "Advanced Filter Casing");
- GT_LanguageManager.addStringLocalization(
- getUnlocalizedName() + ".1.tooltip", "Less than five 0.1μm particles per m^3");
+ GT_LanguageManager
+ .addStringLocalization(getUnlocalizedName() + ".1.tooltip", "Less than five 0.1μm particles per m^3");
ItemList.Casing_Pipe_Polybenzimidazole.set(new ItemStack(this, 1, 0));
ItemList.Casing_Vent_T2.set(new ItemStack(this, 1, 1));
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java
index 452ed16d44..6cd2700250 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Casings_Abstract.java
@@ -1,13 +1,7 @@
package gregtech.common.blocks;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Textures;
-import gregtech.api.items.GT_Generic_Block;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_LanguageManager;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
@@ -22,8 +16,17 @@ import net.minecraft.util.StatCollector;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Textures;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_LanguageManager;
+
public abstract class GT_Block_Casings_Abstract extends GT_Generic_Block
implements gregtech.api.interfaces.IHasIndexedTexture {
+
public GT_Block_Casings_Abstract(Class<? extends ItemBlock> aItemClass, String aName, Material aMaterial) {
super(aItemClass, aName, aMaterial);
setStepSound(soundTypeMetal);
@@ -32,8 +35,8 @@ public abstract class GT_Block_Casings_Abstract extends GT_Generic_Block
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + 32767 + ".name", "Any Sub Block of this");
}
- public GT_Block_Casings_Abstract(
- Class<? extends ItemBlock> aItemClass, String aName, Material aMaterial, int aMaxMeta) {
+ public GT_Block_Casings_Abstract(Class<? extends ItemBlock> aItemClass, String aName, Material aMaterial,
+ int aMaxMeta) {
this(aItemClass, aName, aMaterial);
for (int i = 0; i < aMaxMeta; i++) {
Textures.BlockIcons.setCasingTextureForId(getTextureIndex(i), TextureFactory.of(this, i));
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Concretes.java b/src/main/java/gregtech/common/blocks/GT_Block_Concretes.java
index 7debd01173..0207ab975a 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Concretes.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Concretes.java
@@ -1,17 +1,19 @@
package gregtech.common.blocks;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.IBlockOnWalkOver;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_OreDictUnificator;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.world.World;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IBlockOnWalkOver;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_OreDictUnificator;
+
public class GT_Block_Concretes extends GT_Block_Stones_Abstract implements IBlockOnWalkOver {
+
public GT_Block_Concretes() {
super(GT_Item_Concretes.class, "gt.blockconcretes");
setResistance(20.0F);
@@ -70,8 +72,7 @@ public class GT_Block_Concretes extends GT_Block_Stones_Abstract implements IBlo
@Override
public void onWalkOver(EntityLivingBase aEntity, World aWorld, int aX, int aY, int aZ) {
- if ((aEntity.motionX != 0 || aEntity.motionZ != 0)
- && !aEntity.isInWater()
+ if ((aEntity.motionX != 0 || aEntity.motionZ != 0) && !aEntity.isInWater()
&& !aEntity.isWet()
&& !aEntity.isSneaking()) {
double tSpeed = (aWorld.getBlock(aX, aY - 1, aZ).slipperiness >= 0.8 ? 1.5 : 1.2);
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Granites.java b/src/main/java/gregtech/common/blocks/GT_Block_Granites.java
index 5c98c18920..df50c5223f 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Granites.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Granites.java
@@ -1,9 +1,5 @@
package gregtech.common.blocks;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_OreDictUnificator;
import net.minecraft.entity.Entity;
import net.minecraft.entity.boss.EntityWither;
import net.minecraft.init.Blocks;
@@ -12,7 +8,13 @@ import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_OreDictUnificator;
+
public class GT_Block_Granites extends GT_Block_Stones_Abstract {
+
public GT_Block_Granites() {
super(GT_Item_Granites.class, "gt.blockgranites");
setResistance(60.0F);
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Machines.java b/src/main/java/gregtech/common/blocks/GT_Block_Machines.java
index 25db7f32dd..82e7ec61ac 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Machines.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Machines.java
@@ -5,32 +5,11 @@ import static gregtech.api.enums.GT_Values.ALL_VALID_SIDES;
import static gregtech.api.enums.GT_Values.SIDE_UP;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
-import com.cricketcraft.chisel.api.IFacade;
-import cpw.mods.fml.common.Optional;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IDebugableBlock;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.ICoverable;
-import gregtech.api.interfaces.tileentity.IDebugableTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.items.GT_Generic_Block;
-import gregtech.api.metatileentity.BaseMetaPipeEntity;
-import gregtech.api.metatileentity.BaseMetaTileEntity;
-import gregtech.api.metatileentity.BaseTileEntity;
-import gregtech.api.metatileentity.CoverableTileEntity;
-import gregtech.api.util.GT_BaseCrop;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.covers.CoverInfo;
-import gregtech.common.render.GT_Renderer_Block;
-import gregtech.common.tileentities.storage.GT_MetaTileEntity_QuantumChest;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.Random;
+
import net.minecraft.block.Block;
import net.minecraft.block.ITileEntityProvider;
import net.minecraft.client.renderer.texture.IIconRegister;
@@ -53,8 +32,33 @@ import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import com.cricketcraft.chisel.api.IFacade;
+
+import cpw.mods.fml.common.Optional;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IDebugableBlock;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.interfaces.tileentity.IDebugableTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.metatileentity.BaseMetaPipeEntity;
+import gregtech.api.metatileentity.BaseMetaTileEntity;
+import gregtech.api.metatileentity.BaseTileEntity;
+import gregtech.api.metatileentity.CoverableTileEntity;
+import gregtech.api.util.GT_BaseCrop;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.covers.CoverInfo;
+import gregtech.common.render.GT_Renderer_Block;
+import gregtech.common.tileentities.storage.GT_MetaTileEntity_QuantumChest;
+
@Optional.Interface(iface = "com.cricketcraft.chisel.api.IFacade", modid = "ChiselAPI")
public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlock, ITileEntityProvider, IFacade {
+
private static final ThreadLocal<IGregTechTileEntity> mTemporaryTileEntity = new ThreadLocal<>();
private boolean renderAsNormalBlock;
@@ -226,8 +230,8 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
@SuppressWarnings("unchecked") // Old API uses raw List type
@Override
- public void addCollisionBoxesToList(
- World aWorld, int aX, int aY, int aZ, AxisAlignedBB inputAABB, List outputAABB, Entity collider) {
+ public void addCollisionBoxesToList(World aWorld, int aX, int aY, int aZ, AxisAlignedBB inputAABB, List outputAABB,
+ Entity collider) {
final TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
if (tTileEntity instanceof IGregTechTileEntity
&& ((IGregTechTileEntity) tTileEntity).getMetaTileEntity() != null) {
@@ -334,35 +338,25 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
@Override
public float getPlayerRelativeBlockHardness(EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ) {
final TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
- return tTileEntity instanceof BaseMetaTileEntity
- && ((BaseMetaTileEntity) tTileEntity).privateAccess()
- && !((BaseMetaTileEntity) tTileEntity).playerOwnsThis(aPlayer, true)
- ? -1.0F
- : super.getPlayerRelativeBlockHardness(aPlayer, aWorld, aX, aY, aZ);
- }
-
- @Override
- public boolean onBlockActivated(
- World aWorld,
- int aX,
- int aY,
- int aZ,
- EntityPlayer aPlayer,
- int aSide,
- float aOffsetX,
- float aOffsetY,
- float aOffsetZ) {
+ return tTileEntity instanceof BaseMetaTileEntity && ((BaseMetaTileEntity) tTileEntity).privateAccess()
+ && !((BaseMetaTileEntity) tTileEntity).playerOwnsThis(aPlayer, true) ? -1.0F
+ : super.getPlayerRelativeBlockHardness(aPlayer, aWorld, aX, aY, aZ);
+ }
+
+ @Override
+ public boolean onBlockActivated(World aWorld, int aX, int aY, int aZ, EntityPlayer aPlayer, int aSide,
+ float aOffsetX, float aOffsetY, float aOffsetZ) {
final TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
if (tTileEntity == null) {
return false;
}
if (aPlayer.isSneaking()) {
final ItemStack tCurrentItem = aPlayer.inventory.getCurrentItem();
- if (tCurrentItem != null
- && !GT_Utility.isStackInList(tCurrentItem, GregTech_API.sScrewdriverList)
+ if (tCurrentItem != null && !GT_Utility.isStackInList(tCurrentItem, GregTech_API.sScrewdriverList)
&& !GT_Utility.isStackInList(tCurrentItem, GregTech_API.sWrenchList)
&& !GT_Utility.isStackInList(tCurrentItem, GregTech_API.sWireCutterList)
- && !GT_Utility.isStackInList(tCurrentItem, GregTech_API.sSolderingToolList)) return false;
+ && !GT_Utility.isStackInList(tCurrentItem, GregTech_API.sSolderingToolList))
+ return false;
}
if ((tTileEntity instanceof IGregTechTileEntity)) {
if (((IGregTechTileEntity) tTileEntity).getTimer() < 50L) {
@@ -400,7 +394,10 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
if (tTileEntity instanceof BaseMetaTileEntity) {
GT_Log.exp.printf(
"Explosion at : %d | %d | %d DIMID: %s due to near explosion!%n",
- aX, aY, aZ, aWorld.provider.dimensionId);
+ aX,
+ aY,
+ aZ,
+ aWorld.provider.dimensionId);
((BaseMetaTileEntity) tTileEntity).doEnergyExplosion();
}
super.onBlockExploded(aWorld, aX, aY, aZ, aExplosion);
@@ -417,8 +414,7 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
if (!(tGregTechTileEntity.getMetaTileEntity() instanceof GT_MetaTileEntity_QuantumChest)) {
for (int i = 0; i < tGregTechTileEntity.getSizeInventory(); i++) {
final ItemStack tItem = tGregTechTileEntity.getStackInSlot(i);
- if ((tItem != null)
- && (tItem.stackSize > 0)
+ if ((tItem != null) && (tItem.stackSize > 0)
&& (tGregTechTileEntity.isValidSlot(i))
&& tGregTechTileEntity.shouldDropItemAt(i)) {
final EntityItem tItemEntity = new EntityItem(
@@ -428,8 +424,7 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
aZ + XSTR_INSTANCE.nextFloat() * 0.8F + 0.1F,
new ItemStack(tItem.getItem(), tItem.stackSize, tItem.getItemDamage()));
if (tItem.hasTagCompound()) {
- tItemEntity.getEntityItem().setTagCompound((NBTTagCompound)
- tItem.getTagCompound().copy());
+ tItemEntity.getEntityItem().setTagCompound((NBTTagCompound) tItem.getTagCompound().copy());
}
tItemEntity.motionX = (XSTR_INSTANCE.nextGaussian() * 0.05D);
tItemEntity.motionY = (XSTR_INSTANCE.nextGaussian() * 0.25D);
@@ -508,15 +503,18 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
}
@Override
- public void dropBlockAsItemWithChance(
- World aWorld, int aX, int aY, int aZ, int aMetadata, float chance, int aFortune) {
+ public void dropBlockAsItemWithChance(World aWorld, int aX, int aY, int aZ, int aMetadata, float chance,
+ int aFortune) {
if (!aWorld.isRemote) {
final TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
if (tTileEntity != null && (chance < 1.0F)) {
if (tTileEntity instanceof BaseMetaTileEntity && (GregTech_API.sMachineNonWrenchExplosions)) {
GT_Log.exp.printf(
"Explosion at : %d | %d | %d DIMID: %s NonWrench picking/Rain!%n",
- aX, aY, aZ, aWorld.provider.dimensionId);
+ aX,
+ aY,
+ aZ,
+ aWorld.provider.dimensionId);
((BaseMetaTileEntity) tTileEntity).doEnergyExplosion();
}
} else {
@@ -595,15 +593,8 @@ public class GT_Block_Machines extends GT_Generic_Block implements IDebugableBlo
}
@Override
- public float getExplosionResistance(
- Entity entity,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- double explosionX,
- double explosionY,
- double explosionZ) {
+ public float getExplosionResistance(Entity entity, World aWorld, int aX, int aY, int aZ, double explosionX,
+ double explosionY, double explosionZ) {
final TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
if (tTileEntity instanceof IGregTechTileEntity) {
return ((IGregTechTileEntity) tTileEntity).getBlastResistance((byte) 6);
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Metal.java b/src/main/java/gregtech/common/blocks/GT_Block_Metal.java
index 2bb703a2f9..b33a43e821 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Metal.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Metal.java
@@ -1,16 +1,18 @@
package gregtech.common.blocks;
+import net.minecraft.block.material.Material;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.common.Loader;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_OreDictUnificator;
-import net.minecraft.block.material.Material;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
public class GT_Block_Metal extends GT_Block_Storage {
+
public Materials[] mMats;
public OrePrefixes mPrefix;
public IIconContainer[] mBlockIcons;
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Ores.java b/src/main/java/gregtech/common/blocks/GT_Block_Ores.java
index 3f0c829b50..942441b0ba 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Ores.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Ores.java
@@ -5,15 +5,8 @@ import static gregtech.api.enums.Textures.BlockIcons.GRANITE_BLACK_STONE;
import static gregtech.api.enums.Textures.BlockIcons.GRANITE_RED_STONE;
import static gregtech.api.enums.Textures.BlockIcons.MARBLE_STONE;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.GT_Mod;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.render.TextureFactory;
import java.util.Arrays;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
@@ -22,7 +15,17 @@ import net.minecraft.util.IIcon;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.GT_Mod;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.render.TextureFactory;
+
public class GT_Block_Ores extends GT_Block_Ores_Abstract {
+
private static final String UNLOCALIZED_NAME = "gt.blockores";
public GT_Block_Ores() {
@@ -35,18 +38,11 @@ public class GT_Block_Ores extends GT_Block_Ores_Abstract {
}
@Override
- public OrePrefixes[]
- getProcessingPrefix() { // Must have 8 entries; an entry can be null to disable automatic recipes.
- return new OrePrefixes[] {
- OrePrefixes.ore,
- OrePrefixes.oreNetherrack,
- OrePrefixes.oreEndstone,
- OrePrefixes.oreBlackgranite,
- OrePrefixes.oreRedgranite,
- OrePrefixes.oreMarble,
- OrePrefixes.oreBasalt,
- null
- };
+ public OrePrefixes[] getProcessingPrefix() { // Must have 8 entries; an entry can be null to disable automatic
+ // recipes.
+ return new OrePrefixes[] { OrePrefixes.ore, OrePrefixes.oreNetherrack, OrePrefixes.oreEndstone,
+ OrePrefixes.oreBlackgranite, OrePrefixes.oreRedgranite, OrePrefixes.oreMarble, OrePrefixes.oreBasalt,
+ null };
}
@Override
@@ -110,30 +106,15 @@ public class GT_Block_Ores extends GT_Block_Ores_Abstract {
@Override
public Materials[] getDroppedDusts() { // Must have 8 entries; can be null.
- return new Materials[] {
- Materials.Stone,
- Materials.Netherrack,
- Materials.Endstone,
- Materials.GraniteBlack,
- Materials.GraniteRed,
- Materials.Marble,
- Materials.Basalt,
- Materials.Stone
- };
+ return new Materials[] { Materials.Stone, Materials.Netherrack, Materials.Endstone, Materials.GraniteBlack,
+ Materials.GraniteRed, Materials.Marble, Materials.Basalt, Materials.Stone };
}
@Override
public boolean[] getEnabledMetas() {
- return new boolean[] {
- true,
- true,
- true,
- GT_Mod.gregtechproxy.enableBlackGraniteOres,
- GT_Mod.gregtechproxy.enableRedGraniteOres,
- GT_Mod.gregtechproxy.enableMarbleOres,
- GT_Mod.gregtechproxy.enableBasaltOres,
- true
- };
+ return new boolean[] { true, true, true, GT_Mod.gregtechproxy.enableBlackGraniteOres,
+ GT_Mod.gregtechproxy.enableRedGraniteOres, GT_Mod.gregtechproxy.enableMarbleOres,
+ GT_Mod.gregtechproxy.enableBasaltOres, true };
}
@Override
@@ -142,16 +123,10 @@ public class GT_Block_Ores extends GT_Block_Ores_Abstract {
Arrays.fill(rTextures, TextureFactory.of(Blocks.stone));
rTextures[1] = TextureFactory.of(Blocks.netherrack);
rTextures[2] = TextureFactory.of(Blocks.end_stone);
- rTextures[3] = TextureFactory.builder()
- .addIcon(GRANITE_BLACK_STONE)
- .stdOrient()
- .build();
- rTextures[4] =
- TextureFactory.builder().addIcon(GRANITE_RED_STONE).stdOrient().build();
- rTextures[5] =
- TextureFactory.builder().addIcon(MARBLE_STONE).stdOrient().build();
- rTextures[6] =
- TextureFactory.builder().addIcon(BASALT_STONE).stdOrient().build();
+ rTextures[3] = TextureFactory.builder().addIcon(GRANITE_BLACK_STONE).stdOrient().build();
+ rTextures[4] = TextureFactory.builder().addIcon(GRANITE_RED_STONE).stdOrient().build();
+ rTextures[5] = TextureFactory.builder().addIcon(MARBLE_STONE).stdOrient().build();
+ rTextures[6] = TextureFactory.builder().addIcon(BASALT_STONE).stdOrient().build();
return rTextures;
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java
index ae41933c1c..66acc22a22 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java
@@ -1,23 +1,10 @@
package gregtech.common.blocks;
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.GT_Mod;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.items.GT_Generic_Block;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_OreDictUnificator;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.render.GT_Renderer_Block;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
+
import net.minecraft.block.Block;
import net.minecraft.block.ITileEntityProvider;
import net.minecraft.block.material.Material;
@@ -37,7 +24,23 @@ import net.minecraft.util.StatCollector;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import cpw.mods.fml.common.Loader;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.GT_Mod;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.render.GT_Renderer_Block;
+
public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements ITileEntityProvider {
+
private static final String DOT_NAME = ".name";
private static final String DOT_TOOLTIP = ".tooltip";
public static ThreadLocal<GT_TileEntity_Ores> mTemporaryTileEntity = new ThreadLocal<>();
@@ -45,8 +48,8 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
public static boolean tHideOres;
public static Set<Materials> aBlockedOres = new HashSet<>();
- protected GT_Block_Ores_Abstract(
- String aUnlocalizedName, int aOreMetaCount, boolean aHideFirstMeta, Material aMaterial) {
+ protected GT_Block_Ores_Abstract(String aUnlocalizedName, int aOreMetaCount, boolean aHideFirstMeta,
+ Material aMaterial) {
super(GT_Item_Ores.class, aUnlocalizedName, aMaterial);
this.isBlockContainer = true;
setStepSound(soundTypeStone);
@@ -71,10 +74,9 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
GregTech_API.sGeneratedMaterials[i].getToolTip());
GT_LanguageManager.addStringLocalization(
getUnlocalizedName() + "." + ((i + 16000) + (j * 1000)) + DOT_NAME,
- "Small "
- + (GT_LanguageManager.i18nPlaceholder
- ? getLocalizedNameFormat(GregTech_API.sGeneratedMaterials[i])
- : getLocalizedName(GregTech_API.sGeneratedMaterials[i])));
+ "Small " + (GT_LanguageManager.i18nPlaceholder
+ ? getLocalizedNameFormat(GregTech_API.sGeneratedMaterials[i])
+ : getLocalizedName(GregTech_API.sGeneratedMaterials[i])));
GT_LanguageManager.addStringLocalization(
getUnlocalizedName() + "." + ((i + 16000) + (j * 1000)) + DOT_TOOLTIP,
GregTech_API.sGeneratedMaterials[i].getToolTip());
@@ -159,16 +161,8 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
}
@Override
- public boolean onBlockActivated(
- World aWorld,
- int aX,
- int aY,
- int aZ,
- EntityPlayer aPlayer,
- int aSide,
- float aOffsetX,
- float aOffsetY,
- float aOffsetZ) {
+ public boolean onBlockActivated(World aWorld, int aX, int aY, int aZ, EntityPlayer aPlayer, int aSide,
+ float aOffsetX, float aOffsetY, float aOffsetZ) {
if (!aPlayer.isSneaking() || !aPlayer.capabilities.isCreativeMode) {
return false;
}
@@ -184,8 +178,8 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
}
@Override
- public boolean onBlockEventReceived(
- World p_149696_1_, int p_149696_2_, int p_149696_3_, int p_149696_4_, int p_149696_5_, int p_149696_6_) {
+ public boolean onBlockEventReceived(World p_149696_1_, int p_149696_2_, int p_149696_3_, int p_149696_4_,
+ int p_149696_5_, int p_149696_6_) {
super.onBlockEventReceived(p_149696_1_, p_149696_2_, p_149696_3_, p_149696_4_, p_149696_5_, p_149696_6_);
TileEntity tileentity = p_149696_1_.getTileEntity(p_149696_2_, p_149696_3_, p_149696_4_);
return tileentity != null && tileentity.receiveClientEvent(p_149696_5_, p_149696_6_);
@@ -212,15 +206,8 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
}
@Override
- public float getExplosionResistance(
- Entity entity,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- double explosionX,
- double explosionY,
- double explosionZ) {
+ public float getExplosionResistance(Entity entity, World aWorld, int aX, int aY, int aZ, double explosionX,
+ double explosionY, double explosionZ) {
return 1.0F + getHarvestLevel(aWorld.getBlockMetadata(aX, aY, aZ)) * 1.0F;
}
@@ -285,7 +272,13 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
@SideOnly(Side.CLIENT)
public boolean addHitEffects(World worldObj, MovingObjectPosition target, EffectRenderer effectRenderer) {
GT_Renderer_Block.addHitEffects(
- effectRenderer, this, worldObj, target.blockX, target.blockY, target.blockZ, target.sideHit);
+ effectRenderer,
+ this,
+ worldObj,
+ target.blockX,
+ target.blockY,
+ target.blockZ,
+ target.sideHit);
return true;
}
@@ -315,8 +308,8 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
aWorld.removeTileEntity(aX, aY, aZ);
}
- public abstract OrePrefixes[]
- getProcessingPrefix(); // Must have 8 entries; an entry can be null to disable automatic recipes.
+ public abstract OrePrefixes[] getProcessingPrefix(); // Must have 8 entries; an entry can be null to disable
+ // automatic recipes.
public abstract boolean[] getEnabledMetas(); // Must have 8 entries.
@@ -330,8 +323,7 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
if ((tTileEntity instanceof GT_TileEntity_Ores)) {
return ((GT_TileEntity_Ores) tTileEntity).getDrops(getDroppedBlock(), aFortune);
}
- return mTemporaryTileEntity.get() == null
- ? new ArrayList<>()
+ return mTemporaryTileEntity.get() == null ? new ArrayList<>()
: mTemporaryTileEntity.get().getDrops(getDroppedBlock(), aFortune);
}
@@ -342,7 +334,7 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements
public abstract ITexture[] getTextureSet(); // Must have 16 entries.
- @SuppressWarnings({"unchecked"})
+ @SuppressWarnings({ "unchecked" })
@Override
@SideOnly(Side.CLIENT)
public void getSubBlocks(Item aItem, CreativeTabs aTab, List aList) {
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB1.java b/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB1.java
index 73fe674fbe..4b730ef0ff 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB1.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB1.java
@@ -1,17 +1,19 @@
package gregtech.common.blocks;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.init.Blocks;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.common.registry.GameRegistry;
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
import gregtech.api.render.TextureFactory;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.init.Blocks;
-import net.minecraft.util.IIcon;
public class GT_Block_Ores_UB1 extends GT_Block_Ores_Abstract {
+
Block aUBBlock = GameRegistry.findBlock("UndergroundBiomes", "igneousStone");
public GT_Block_Ores_UB1() {
@@ -26,16 +28,8 @@ public class GT_Block_Ores_UB1 extends GT_Block_Ores_Abstract {
@Override
public OrePrefixes[] getProcessingPrefix() { // Must have 8 entries.
- return new OrePrefixes[] {
- OrePrefixes.oreRedgranite,
- OrePrefixes.oreBlackgranite,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.oreBasalt,
- OrePrefixes.ore,
- OrePrefixes.ore
- };
+ return new OrePrefixes[] { OrePrefixes.oreRedgranite, OrePrefixes.oreBlackgranite, OrePrefixes.ore,
+ OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.oreBasalt, OrePrefixes.ore, OrePrefixes.ore };
}
@Override
@@ -55,42 +49,22 @@ public class GT_Block_Ores_UB1 extends GT_Block_Ores_Abstract {
@Override
public Materials[] getDroppedDusts() { // Must have 8 entries; can be null.
- return new Materials[] {
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone
- };
+ return new Materials[] { Materials.Stone, Materials.Stone, Materials.Stone, Materials.Stone, Materials.Stone,
+ Materials.Stone, Materials.Stone, Materials.Stone };
}
@Override
public boolean[] getEnabledMetas() {
- return new boolean[] {true, true, true, true, true, true, true, true};
+ return new boolean[] { true, true, true, true, true, true, true, true };
}
@Override
public ITexture[] getTextureSet() { // Must have 16 entries.
- return new ITexture[] {
- TextureFactory.of(aUBBlock, 0),
- TextureFactory.of(aUBBlock, 1),
- TextureFactory.of(aUBBlock, 2),
- TextureFactory.of(aUBBlock, 3),
- TextureFactory.of(aUBBlock, 4),
- TextureFactory.of(aUBBlock, 5),
- TextureFactory.of(aUBBlock, 6),
- TextureFactory.of(aUBBlock, 7),
- TextureFactory.of(aUBBlock, 0),
- TextureFactory.of(aUBBlock, 1),
- TextureFactory.of(aUBBlock, 2),
- TextureFactory.of(aUBBlock, 3),
- TextureFactory.of(aUBBlock, 4),
- TextureFactory.of(aUBBlock, 5),
- TextureFactory.of(aUBBlock, 6),
- TextureFactory.of(aUBBlock, 7)
- };
+ return new ITexture[] { TextureFactory.of(aUBBlock, 0), TextureFactory.of(aUBBlock, 1),
+ TextureFactory.of(aUBBlock, 2), TextureFactory.of(aUBBlock, 3), TextureFactory.of(aUBBlock, 4),
+ TextureFactory.of(aUBBlock, 5), TextureFactory.of(aUBBlock, 6), TextureFactory.of(aUBBlock, 7),
+ TextureFactory.of(aUBBlock, 0), TextureFactory.of(aUBBlock, 1), TextureFactory.of(aUBBlock, 2),
+ TextureFactory.of(aUBBlock, 3), TextureFactory.of(aUBBlock, 4), TextureFactory.of(aUBBlock, 5),
+ TextureFactory.of(aUBBlock, 6), TextureFactory.of(aUBBlock, 7) };
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB2.java b/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB2.java
index 0d7e2c3428..890aed5a2c 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB2.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB2.java
@@ -1,17 +1,19 @@
package gregtech.common.blocks;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.init.Blocks;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.common.registry.GameRegistry;
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
import gregtech.api.render.TextureFactory;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.init.Blocks;
-import net.minecraft.util.IIcon;
public class GT_Block_Ores_UB2 extends GT_Block_Ores_Abstract {
+
Block aUBBlock = GameRegistry.findBlock("UndergroundBiomes", "metamorphicStone");
public GT_Block_Ores_UB2() {
@@ -25,18 +27,10 @@ public class GT_Block_Ores_UB2 extends GT_Block_Ores_Abstract {
}
@Override
- public OrePrefixes[]
- getProcessingPrefix() { // Must have 8 entries; an entry can be null to disable automatic recipes.
- return new OrePrefixes[] {
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.oreMarble,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore
- };
+ public OrePrefixes[] getProcessingPrefix() { // Must have 8 entries; an entry can be null to disable automatic
+ // recipes.
+ return new OrePrefixes[] { OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.oreMarble, OrePrefixes.ore,
+ OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.ore };
}
@Override
@@ -56,42 +50,22 @@ public class GT_Block_Ores_UB2 extends GT_Block_Ores_Abstract {
@Override
public Materials[] getDroppedDusts() { // Must have 8 entries; can be null.
- return new Materials[] {
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone
- };
+ return new Materials[] { Materials.Stone, Materials.Stone, Materials.Stone, Materials.Stone, Materials.Stone,
+ Materials.Stone, Materials.Stone, Materials.Stone };
}
@Override
public boolean[] getEnabledMetas() {
- return new boolean[] {true, true, true, true, true, true, true, true};
+ return new boolean[] { true, true, true, true, true, true, true, true };
}
@Override
public ITexture[] getTextureSet() { // Must have 16 entries.
- return new ITexture[] {
- TextureFactory.of(aUBBlock, 0),
- TextureFactory.of(aUBBlock, 1),
- TextureFactory.of(aUBBlock, 2),
- TextureFactory.of(aUBBlock, 3),
- TextureFactory.of(aUBBlock, 4),
- TextureFactory.of(aUBBlock, 5),
- TextureFactory.of(aUBBlock, 6),
- TextureFactory.of(aUBBlock, 7),
- TextureFactory.of(aUBBlock, 0),
- TextureFactory.of(aUBBlock, 1),
- TextureFactory.of(aUBBlock, 2),
- TextureFactory.of(aUBBlock, 3),
- TextureFactory.of(aUBBlock, 4),
- TextureFactory.of(aUBBlock, 5),
- TextureFactory.of(aUBBlock, 6),
- TextureFactory.of(aUBBlock, 7)
- };
+ return new ITexture[] { TextureFactory.of(aUBBlock, 0), TextureFactory.of(aUBBlock, 1),
+ TextureFactory.of(aUBBlock, 2), TextureFactory.of(aUBBlock, 3), TextureFactory.of(aUBBlock, 4),
+ TextureFactory.of(aUBBlock, 5), TextureFactory.of(aUBBlock, 6), TextureFactory.of(aUBBlock, 7),
+ TextureFactory.of(aUBBlock, 0), TextureFactory.of(aUBBlock, 1), TextureFactory.of(aUBBlock, 2),
+ TextureFactory.of(aUBBlock, 3), TextureFactory.of(aUBBlock, 4), TextureFactory.of(aUBBlock, 5),
+ TextureFactory.of(aUBBlock, 6), TextureFactory.of(aUBBlock, 7) };
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB3.java b/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB3.java
index 5754f87454..873902a344 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB3.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Ores_UB3.java
@@ -1,17 +1,19 @@
package gregtech.common.blocks;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.init.Blocks;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.common.registry.GameRegistry;
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
import gregtech.api.render.TextureFactory;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.init.Blocks;
-import net.minecraft.util.IIcon;
public class GT_Block_Ores_UB3 extends GT_Block_Ores_Abstract {
+
Block aUBBlock = GameRegistry.findBlock("UndergroundBiomes", "sedimentaryStone");
public GT_Block_Ores_UB3() {
@@ -25,18 +27,10 @@ public class GT_Block_Ores_UB3 extends GT_Block_Ores_Abstract {
}
@Override
- public OrePrefixes[]
- getProcessingPrefix() { // Must have 8 entries; an entry can be null to disable automatic recipes.
- return new OrePrefixes[] {
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore,
- OrePrefixes.ore
- };
+ public OrePrefixes[] getProcessingPrefix() { // Must have 8 entries; an entry can be null to disable automatic
+ // recipes.
+ return new OrePrefixes[] { OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.ore,
+ OrePrefixes.ore, OrePrefixes.ore, OrePrefixes.ore };
}
@Override
@@ -56,42 +50,22 @@ public class GT_Block_Ores_UB3 extends GT_Block_Ores_Abstract {
@Override
public Materials[] getDroppedDusts() { // Must have 8 entries; can be null.
- return new Materials[] {
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone,
- Materials.Stone
- };
+ return new Materials[] { Materials.Stone, Materials.Stone, Materials.Stone, Materials.Stone, Materials.Stone,
+ Materials.Stone, Materials.Stone, Materials.Stone };
}
@Override
public boolean[] getEnabledMetas() {
- return new boolean[] {true, true, true, true, true, true, true, true};
+ return new boolean[] { true, true, true, true, true, true, true, true };
}
@Override
public ITexture[] getTextureSet() { // Must have 16 entries.
- return new ITexture[] {
- TextureFactory.of(aUBBlock, 0),
- TextureFactory.of(aUBBlock, 1),
- TextureFactory.of(aUBBlock, 2),
- TextureFactory.of(aUBBlock, 3),
- TextureFactory.of(aUBBlock, 4),
- TextureFactory.of(aUBBlock, 5),
- TextureFactory.of(aUBBlock, 6),
- TextureFactory.of(aUBBlock, 7),
- TextureFactory.of(aUBBlock, 0),
- TextureFactory.of(aUBBlock, 1),
- TextureFactory.of(aUBBlock, 2),
- TextureFactory.of(aUBBlock, 3),
- TextureFactory.of(aUBBlock, 4),
- TextureFactory.of(aUBBlock, 5),
- TextureFactory.of(aUBBlock, 6),
- TextureFactory.of(aUBBlock, 7)
- };
+ return new ITexture[] { TextureFactory.of(aUBBlock, 0), TextureFactory.of(aUBBlock, 1),
+ TextureFactory.of(aUBBlock, 2), TextureFactory.of(aUBBlock, 3), TextureFactory.of(aUBBlock, 4),
+ TextureFactory.of(aUBBlock, 5), TextureFactory.of(aUBBlock, 6), TextureFactory.of(aUBBlock, 7),
+ TextureFactory.of(aUBBlock, 0), TextureFactory.of(aUBBlock, 1), TextureFactory.of(aUBBlock, 2),
+ TextureFactory.of(aUBBlock, 3), TextureFactory.of(aUBBlock, 4), TextureFactory.of(aUBBlock, 5),
+ TextureFactory.of(aUBBlock, 6), TextureFactory.of(aUBBlock, 7) };
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Reinforced.java b/src/main/java/gregtech/common/blocks/GT_Block_Reinforced.java
index 37887ac5f6..f446bc7518 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Reinforced.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Reinforced.java
@@ -2,16 +2,8 @@ package gregtech.common.blocks;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.*;
-import gregtech.api.items.GT_Generic_Block;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.WorldSpawnedEventBuilder;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
@@ -30,6 +22,16 @@ import net.minecraft.world.Explosion;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.*;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.WorldSpawnedEventBuilder;
+
public class GT_Block_Reinforced extends GT_Generic_Block {
public GT_Block_Reinforced(String aName) {
@@ -53,11 +55,9 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".11.name", "Neutronium Reinforced Block");
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".12.name", "Raw Deep Dark Portal Block");
ItemList.Block_BronzePlate.set(new ItemStack(this.setHardness(60.0f).setResistance(150.0f), 1, 0));
- ItemList.Block_IridiumTungstensteel.set(
- new ItemStack(this.setHardness(400.0f).setResistance(600.0f), 1, 1));
+ ItemList.Block_IridiumTungstensteel.set(new ItemStack(this.setHardness(400.0f).setResistance(600.0f), 1, 1));
ItemList.Block_Plascrete.set(new ItemStack(this.setHardness(5.0f).setResistance(6.0f), 1, 2));
- ItemList.Block_TungstenSteelReinforced.set(
- new ItemStack(this.setHardness(250.0f).setResistance(400.0f), 1, 3));
+ ItemList.Block_TungstenSteelReinforced.set(new ItemStack(this.setHardness(250.0f).setResistance(400.0f), 1, 3));
ItemList.Block_BrittleCharcoal.set(new ItemStack(this.setHardness(0.5f).setResistance(8.0f), 1, 4));
ItemList.Block_Powderbarrel.set(new ItemStack(this.setHardness(2.5f).setResistance(2.0f), 1, 5));
ItemList.Block_SSFUEL.set(new ItemStack(this.setHardness(2.5f).setResistance(2.0f), 1, 6));
@@ -65,24 +65,16 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
ItemList.Block_SteelPlate.set(new ItemStack(this.setHardness(150.0f).setResistance(200.0f), 1, 8));
ItemList.Block_TitaniumPlate.set(new ItemStack(this.setHardness(200.0f).setResistance(300.0f), 1, 9));
ItemList.Block_NaquadahPlate.set(new ItemStack(this.setHardness(500.0f).setResistance(1000.0f), 1, 10));
- ItemList.Block_NeutroniumPlate.set(
- new ItemStack(this.setHardness(750.0f).setResistance(2500.0f), 1, 11));
- ItemList.Block_BedrockiumCompressed.set(
- new ItemStack(this.setHardness(1500.0f).setResistance(5000.0f), 1, 12));
+ ItemList.Block_NeutroniumPlate.set(new ItemStack(this.setHardness(750.0f).setResistance(2500.0f), 1, 11));
+ ItemList.Block_BedrockiumCompressed.set(new ItemStack(this.setHardness(1500.0f).setResistance(5000.0f), 1, 12));
GT_ModHandler.addShapelessCraftingRecipe(
- new ItemStack(Items.coal, 1, 1), new Object[] {ItemList.Block_BrittleCharcoal.get(1)});
+ new ItemStack(Items.coal, 1, 1),
+ new Object[] { ItemList.Block_BrittleCharcoal.get(1) });
GT_ModHandler.addCraftingRecipe(
- ItemList.Block_Powderbarrel.get(1L), GT_ModHandler.RecipeBits.REVERSIBLE, new Object[] {
- "WSW",
- "GGG",
- "WGW",
- 'W',
- OrePrefixes.plate.get(Materials.Wood),
- 'G',
- new ItemStack(Items.gunpowder, 1),
- 'S',
- new ItemStack(Items.string, 1)
- });
+ ItemList.Block_Powderbarrel.get(1L),
+ GT_ModHandler.RecipeBits.REVERSIBLE,
+ new Object[] { "WSW", "GGG", "WGW", 'W', OrePrefixes.plate.get(Materials.Wood), 'G',
+ new ItemStack(Items.gunpowder, 1), 'S', new ItemStack(Items.string, 1) });
}
@Override
@@ -176,8 +168,8 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
}
@Override
- public float getExplosionResistance(
- Entity entity, World world, int x, int y, int z, double explosionX, double explosionY, double explosionZ) {
+ public float getExplosionResistance(Entity entity, World world, int x, int y, int z, double explosionX,
+ double explosionY, double explosionZ) {
if (world == null) {
return 0.0F;
}
@@ -251,8 +243,8 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
}
@Override
- public void dropBlockAsItemWithChance(
- World aWorld, int aX, int aY, int aZ, int aMetadata, float chance, int aFortune) {
+ public void dropBlockAsItemWithChance(World aWorld, int aX, int aY, int aZ, int aMetadata, float chance,
+ int aFortune) {
if (aMetadata == 4) {
this.dropBlockAsItem(aWorld, aX, aY, aZ, new ItemStack(Items.coal, XSTR_INSTANCE.nextInt(2) + 1, 1));
} else {
@@ -265,13 +257,8 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
if (!world.isRemote && world.getBlockMetadata(x, y, z) == 5) {
EntityTNTPrimed entitytntprimed = new EntityTNTPrimed(world, x + 0.5F, y + 0.5F, z + 0.5F, player);
world.spawnEntityInWorld(entitytntprimed);
- new WorldSpawnedEventBuilder.SoundAtEntityEventBuilder()
- .setPitch(1f)
- .setVolume(1f)
- .setIdentifier(SoundResource.GAME_TNT_PRIMED)
- .setEntity(entitytntprimed)
- .setWorld(world)
- .run();
+ new WorldSpawnedEventBuilder.SoundAtEntityEventBuilder().setPitch(1f).setVolume(1f)
+ .setIdentifier(SoundResource.GAME_TNT_PRIMED).setEntity(entitytntprimed).setWorld(world).run();
world.setBlockToAir(x, y, z);
return false;
}
@@ -296,8 +283,12 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
@Override
public void onBlockExploded(World world, int x, int y, int z, Explosion explosion) {
if (!world.isRemote && world.getBlockMetadata(x, y, z) == 5) {
- EntityTNTPrimed entitytntprimed =
- new EntityTNTPrimed(world, x + 0.5F, y + 0.5F, z + 0.5F, explosion.getExplosivePlacedBy());
+ EntityTNTPrimed entitytntprimed = new EntityTNTPrimed(
+ world,
+ x + 0.5F,
+ y + 0.5F,
+ z + 0.5F,
+ explosion.getExplosivePlacedBy());
entitytntprimed.fuse = (world.rand.nextInt(entitytntprimed.fuse / 4) + entitytntprimed.fuse / 8);
world.spawnEntityInWorld(entitytntprimed);
}
@@ -305,16 +296,8 @@ public class GT_Block_Reinforced extends GT_Generic_Block {
}
@Override
- public boolean onBlockActivated(
- World world,
- int x,
- int y,
- int z,
- EntityPlayer player,
- int side,
- float xOffset,
- float yOffset,
- float zOffset) {
+ public boolean onBlockActivated(World world, int x, int y, int z, EntityPlayer player, int side, float xOffset,
+ float yOffset, float zOffset) {
if ((player.getCurrentEquippedItem() != null)
&& (player.getCurrentEquippedItem().getItem() == Items.flint_and_steel)
&& world.getBlockMetadata(x, y, z) == 5) {
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Stones.java b/src/main/java/gregtech/common/blocks/GT_Block_Stones.java
index 1ee8e6df50..2f9e9e9d71 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Stones.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Stones.java
@@ -1,15 +1,17 @@
package gregtech.common.blocks;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_OreDictUnificator;
import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.world.World;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_OreDictUnificator;
+
public class GT_Block_Stones extends GT_Block_Stones_Abstract {
+
public GT_Block_Stones() {
super(GT_Item_Granites.class, "gt.blockstones");
setResistance(60.0F);
@@ -31,9 +33,13 @@ public class GT_Block_Stones extends GT_Block_Stones_Abstract {
GT_LanguageManager.addStringLocalization(getUnlocalizedName() + ".15.name", "Smooth Basalt");
for (int i = 0; i < 16; i++) {
GT_OreDictUnificator.registerOre(
- OrePrefixes.stone, i < 8 ? Materials.Marble : Materials.Basalt, new ItemStack(this, 1, i));
+ OrePrefixes.stone,
+ i < 8 ? Materials.Marble : Materials.Basalt,
+ new ItemStack(this, 1, i));
GT_OreDictUnificator.registerOre(
- OrePrefixes.block, i < 8 ? Materials.Marble : Materials.Basalt, new ItemStack(this, 1, i));
+ OrePrefixes.block,
+ i < 8 ? Materials.Marble : Materials.Basalt,
+ new ItemStack(this, 1, i));
GT_OreDictUnificator.registerOre(
(i < 8 ? Materials.Marble.mName.toLowerCase() : Materials.Basalt.mName.toLowerCase()),
new ItemStack(this, 1, i));
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java
index f40a6b8173..47e9fe250d 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Stones_Abstract.java
@@ -1,14 +1,7 @@
package gregtech.common.blocks;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.*;
-import gregtech.api.interfaces.IOreRecipeRegistrator;
-import gregtech.api.items.GT_Generic_Block;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
@@ -22,7 +15,17 @@ import net.minecraft.util.StatCollector;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.*;
+import gregtech.api.interfaces.IOreRecipeRegistrator;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+
public class GT_Block_Stones_Abstract extends GT_Generic_Block implements IOreRecipeRegistrator {
+
public GT_Block_Stones_Abstract(Class<? extends ItemBlock> aItemClass, String aName) {
super(aItemClass, aName, Material.rock);
OrePrefixes.crafting.add(this);
@@ -59,27 +62,27 @@ public class GT_Block_Stones_Abstract extends GT_Generic_Block implements IOreRe
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 1, 6),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"f", "X", 'X', new ItemStack(this, 1, 7)});
+ new Object[] { "f", "X", 'X', new ItemStack(this, 1, 7) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 1, 14),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"f", "X", 'X', new ItemStack(this, 1, 15)});
+ new Object[] { "f", "X", 'X', new ItemStack(this, 1, 15) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 1, 4),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"h", "X", 'X', new ItemStack(this, 1, 3)});
+ new Object[] { "h", "X", 'X', new ItemStack(this, 1, 3) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 1, 12),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"h", "X", 'X', new ItemStack(this, 1, 11)});
+ new Object[] { "h", "X", 'X', new ItemStack(this, 1, 11) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 1, 1),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"h", "X", 'X', new ItemStack(this, 1, 0)});
+ new Object[] { "h", "X", 'X', new ItemStack(this, 1, 0) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 1, 9),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"h", "X", 'X', new ItemStack(this, 1, 8)});
+ new Object[] { "h", "X", 'X', new ItemStack(this, 1, 8) });
GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 3), new ItemStack(this, 1, 4), 16, 10);
GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 11), new ItemStack(this, 1, 12), 16, 10);
GT_Values.RA.addForgeHammerRecipe(new ItemStack(this, 1, 0), new ItemStack(this, 1, 1), 16, 10);
@@ -87,34 +90,34 @@ public class GT_Block_Stones_Abstract extends GT_Generic_Block implements IOreRe
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 4, 3),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"XX", "XX", 'X', new ItemStack(this, 4, 0)});
+ new Object[] { "XX", "XX", 'X', new ItemStack(this, 4, 0) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 4, 11),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"XX", "XX", 'X', new ItemStack(this, 4, 8)});
+ new Object[] { "XX", "XX", 'X', new ItemStack(this, 4, 8) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 4, 3),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"XX", "XX", 'X', new ItemStack(this, 4, 7)});
+ new Object[] { "XX", "XX", 'X', new ItemStack(this, 4, 7) });
GT_ModHandler.addCraftingRecipe(
new ItemStack(this, 4, 11),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"XX", "XX", 'X', new ItemStack(this, 4, 15)});
+ new Object[] { "XX", "XX", 'X', new ItemStack(this, 4, 15) });
}
@Override
- public void registerOre(
- OrePrefixes aPrefix, Materials aMaterial, String aOreDictName, String aModName, ItemStack aStack) {
+ public void registerOre(OrePrefixes aPrefix, Materials aMaterial, String aOreDictName, String aModName,
+ ItemStack aStack) {
if (aOreDictName.equals(OreDictNames.craftingLensWhite.toString())) {
GT_Values.RA.addLaserEngraverRecipe(
new ItemStack(this, 1, 7),
- GT_Utility.copyAmount(0L, new Object[] {aStack}),
+ GT_Utility.copyAmount(0L, new Object[] { aStack }),
new ItemStack(this, 1, 6),
50,
16);
GT_Values.RA.addLaserEngraverRecipe(
new ItemStack(this, 1, 15),
- GT_Utility.copyAmount(0L, new Object[] {aStack}),
+ GT_Utility.copyAmount(0L, new Object[] { aStack }),
new ItemStack(this, 1, 14),
50,
16);
diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Storage.java b/src/main/java/gregtech/common/blocks/GT_Block_Storage.java
index f318eab8ff..967d98c080 100644
--- a/src/main/java/gregtech/common/blocks/GT_Block_Storage.java
+++ b/src/main/java/gregtech/common/blocks/GT_Block_Storage.java
@@ -1,10 +1,7 @@
package gregtech.common.blocks;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.items.GT_Generic_Block;
import java.util.List;
+
import net.minecraft.block.material.Material;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
@@ -18,6 +15,11 @@ import net.minecraft.util.StatCollector;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.items.GT_Generic_Block;
+
public class GT_Block_Storage extends GT_Generic_Block {
protected GT_Block_Storage(Class<? extends ItemBlock> aItemClass, String aName, Material aMaterial) {
diff --git a/src/main/java/gregtech/common/blocks/GT_Cyclotron_Coils.java b/src/main/java/gregtech/common/blocks/GT_Cyclotron_Coils.java
index 66d9ffe6e8..b42bbfa076 100644
--- a/src/main/java/gregtech/common/blocks/GT_Cyclotron_Coils.java
+++ b/src/main/java/gregtech/common/blocks/GT_Cyclotron_Coils.java
@@ -1,12 +1,13 @@
package gregtech.common.blocks;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Textures;
-import gregtech.api.util.GT_LanguageManager;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.world.IBlockAccess;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Textures;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Cyclotron_Coils extends GT_Block_Casings_Abstract {
public GT_Cyclotron_Coils() {
@@ -108,8 +109,7 @@ public class GT_Cyclotron_Coils extends GT_Block_Casings_Abstract {
@Override
public int colorMultiplier(IBlockAccess aWorld, int aX, int aY, int aZ) {
- return aWorld.getBlockMetadata(aX, aY, aZ) > 9
- ? super.colorMultiplier(aWorld, aX, aY, aZ)
+ return aWorld.getBlockMetadata(aX, aY, aZ) > 9 ? super.colorMultiplier(aWorld, aX, aY, aZ)
: gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[0] << 16
| gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[1] << 8
| gregtech.api.enums.Dyes.MACHINE_METAL.mRGBa[2];
diff --git a/src/main/java/gregtech/common/blocks/GT_Cyclotron_Item_Casings.java b/src/main/java/gregtech/common/blocks/GT_Cyclotron_Item_Casings.java
index a522b2bd3f..f1ca45a805 100644
--- a/src/main/java/gregtech/common/blocks/GT_Cyclotron_Item_Casings.java
+++ b/src/main/java/gregtech/common/blocks/GT_Cyclotron_Item_Casings.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Cyclotron_Item_Casings extends GT_Item_Casings_Abstract {
+
public GT_Cyclotron_Item_Casings(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java
index 70748d5f1a..cd2f818b37 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings1.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Casings1 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings1(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings2.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings2.java
index 5e77ace15d..4f126426cb 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings2.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings2.java
@@ -1,11 +1,13 @@
package gregtech.common.blocks;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
public class GT_Item_Casings2 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings2(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings3.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings3.java
index d80d88d2d1..fdcb5dbd86 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings3.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings3.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Casings3 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings3(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings4.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings4.java
index 7848398a0b..5665150407 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings4.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings4.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Casings4 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings4(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings5.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings5.java
index 7486d25ec5..b7fe3298ec 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings5.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings5.java
@@ -1,23 +1,26 @@
package gregtech.common.blocks;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.enums.HeatingCoilLevel;
-import gregtech.api.util.GT_LanguageManager;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.enums.HeatingCoilLevel;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Item_Casings5 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings5(Block block) {
super(block);
}
- protected static final String mCoilHeatTooltip =
- GT_LanguageManager.addStringLocalization("gt.coilheattooltip", "Base Heating Capacity = ");
- protected static final String mCoilUnitTooltip =
- GT_LanguageManager.addStringLocalization("gt.coilunittooltip", " Kelvin");
+ protected static final String mCoilHeatTooltip = GT_LanguageManager
+ .addStringLocalization("gt.coilheattooltip", "Base Heating Capacity = ");
+ protected static final String mCoilUnitTooltip = GT_LanguageManager
+ .addStringLocalization("gt.coilunittooltip", " Kelvin");
@Override
@SideOnly(Side.CLIENT)
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings6.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings6.java
index f4a8d38ba6..f5250e73da 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings6.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings6.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Casings6 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings6(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings8.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings8.java
index 0d87b5d906..3130006a50 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings8.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings8.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Casings8 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings8(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings9.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings9.java
index c5aee22cff..f413ffdfb8 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings9.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings9.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Casings9 extends GT_Item_Casings_Abstract {
+
public GT_Item_Casings9(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java
index bca2de6eb6..bd6b12c23a 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Casings_Abstract.java
@@ -1,38 +1,41 @@
package gregtech.common.blocks;
-import gregtech.api.GregTech_API;
-import gregtech.api.util.GT_LanguageManager;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
+import gregtech.api.GregTech_API;
+import gregtech.api.util.GT_LanguageManager;
+
public abstract class GT_Item_Casings_Abstract extends ItemBlock {
- protected final String mNoMobsToolTip =
- GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
- protected final String mNoTileEntityToolTip =
- GT_LanguageManager.addStringLocalization("gt.notileentityinthisblock", "This is NOT a TileEntity!");
- protected final String mCoil01Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil01tooltip", "Base Heating Capacity = 1800 Kelvin");
- protected final String mCoil02Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil02tooltip", "Base Heating Capacity = 2700 Kelvin");
- protected final String mCoil03Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil03tooltip", "Base Heating Capacity = 3600 Kelvin");
- protected final String mCoil04Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil04tooltip", "Base Heating Capacity = 4500 Kelvin");
- protected final String mCoil05Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil05tooltip", "Base Heating Capacity = 5400 Kelvin");
- protected final String mCoil06Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil06tooltip", "Base Heating Capacity = 7200 Kelvin");
- protected final String mCoil07Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil07tooltip", "Base Heating Capacity = 9001 Kelvin");
- protected final String mCoil08Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil08tooltip", "Base Heating Capacity = 9900 Kelvin");
- protected final String mCoil09Tooltip =
- GT_LanguageManager.addStringLocalization("gt.coil09tooltip", "Base Heating Capacity = 10800 Kelvin");
- protected final String mBlastProofTooltip =
- GT_LanguageManager.addStringLocalization("gt.blastprooftooltip", "This Block is Blast Proof");
+
+ protected final String mNoMobsToolTip = GT_LanguageManager
+ .addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
+ protected final String mNoTileEntityToolTip = GT_LanguageManager
+ .addStringLocalization("gt.notileentityinthisblock", "This is NOT a TileEntity!");
+ protected final String mCoil01Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil01tooltip", "Base Heating Capacity = 1800 Kelvin");
+ protected final String mCoil02Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil02tooltip", "Base Heating Capacity = 2700 Kelvin");
+ protected final String mCoil03Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil03tooltip", "Base Heating Capacity = 3600 Kelvin");
+ protected final String mCoil04Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil04tooltip", "Base Heating Capacity = 4500 Kelvin");
+ protected final String mCoil05Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil05tooltip", "Base Heating Capacity = 5400 Kelvin");
+ protected final String mCoil06Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil06tooltip", "Base Heating Capacity = 7200 Kelvin");
+ protected final String mCoil07Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil07tooltip", "Base Heating Capacity = 9001 Kelvin");
+ protected final String mCoil08Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil08tooltip", "Base Heating Capacity = 9900 Kelvin");
+ protected final String mCoil09Tooltip = GT_LanguageManager
+ .addStringLocalization("gt.coil09tooltip", "Base Heating Capacity = 10800 Kelvin");
+ protected final String mBlastProofTooltip = GT_LanguageManager
+ .addStringLocalization("gt.blastprooftooltip", "This Block is Blast Proof");
public GT_Item_Casings_Abstract(Block block) {
super(block);
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Concretes.java b/src/main/java/gregtech/common/blocks/GT_Item_Concretes.java
index 0ee92868e8..c659d153d9 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Concretes.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Concretes.java
@@ -1,14 +1,17 @@
package gregtech.common.blocks;
-import gregtech.api.util.GT_LanguageManager;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Item_Concretes extends GT_Item_Stones_Abstract {
- private final String mRunFasterToolTip =
- GT_LanguageManager.addStringLocalization("gt.runfastertooltip", "You can walk faster on this Block");
+
+ private final String mRunFasterToolTip = GT_LanguageManager
+ .addStringLocalization("gt.runfastertooltip", "You can walk faster on this Block");
public GT_Item_Concretes(Block block) {
super(block);
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Granites.java b/src/main/java/gregtech/common/blocks/GT_Item_Granites.java
index e0df50d07b..6e3eb8f12c 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Granites.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Granites.java
@@ -3,6 +3,7 @@ package gregtech.common.blocks;
import net.minecraft.block.Block;
public class GT_Item_Granites extends GT_Item_Stones_Abstract {
+
public GT_Item_Granites(Block block) {
super(block);
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_LongDistancePipe.java b/src/main/java/gregtech/common/blocks/GT_Item_LongDistancePipe.java
index eda3c9b01b..5ce04103ab 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_LongDistancePipe.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_LongDistancePipe.java
@@ -1,18 +1,21 @@
package gregtech.common.blocks;
-import gregtech.api.GregTech_API;
-import gregtech.api.util.GT_LanguageManager;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
+import gregtech.api.GregTech_API;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Item_LongDistancePipe extends ItemBlock {
- protected final String mNoMobsToolTip =
- GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
- protected final String mNoTileEntityToolTip =
- GT_LanguageManager.addStringLocalization("gt.notileentityinthisblock", "This is NOT a TileEntity!");
+
+ protected final String mNoMobsToolTip = GT_LanguageManager
+ .addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
+ protected final String mNoTileEntityToolTip = GT_LanguageManager
+ .addStringLocalization("gt.notileentityinthisblock", "This is NOT a TileEntity!");
public GT_Item_LongDistancePipe(Block block) {
super(block);
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Machines.java b/src/main/java/gregtech/common/blocks/GT_Item_Machines.java
index 7ca54ad115..87aa14342c 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Machines.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Machines.java
@@ -2,23 +2,10 @@ package gregtech.common.blocks;
import static gregtech.GT_Mod.GT_FML_LOGGER;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Materials;
-import gregtech.api.interfaces.ISecondaryDescribable;
-import gregtech.api.interfaces.metatileentity.IConnectable;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.metatileentity.CoverableTileEntity;
-import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Cable;
-import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Fluid;
-import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Frame;
-import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Item;
-import gregtech.api.util.GT_ItsNotMyFaultException;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.tileentities.storage.*;
import java.util.List;
+
import javax.annotation.Nullable;
+
import net.minecraft.block.Block;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
@@ -33,7 +20,24 @@ import net.minecraft.world.World;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidContainerItem;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+import gregtech.api.interfaces.ISecondaryDescribable;
+import gregtech.api.interfaces.metatileentity.IConnectable;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.metatileentity.CoverableTileEntity;
+import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Cable;
+import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Fluid;
+import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Frame;
+import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Item;
+import gregtech.api.util.GT_ItsNotMyFaultException;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.tileentities.storage.*;
+
public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
+
public GT_Item_Machines(Block block) {
super(block);
setMaxDamage(0);
@@ -61,82 +65,113 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
final IGregTechTileEntity tTileEntity = GregTech_API.METATILEENTITIES[tDamage].getBaseMetaTileEntity();
if (!GregTech_API.sPostloadFinished
&& tTileEntity.getMetaTileEntity() instanceof ISecondaryDescribable) {
- final String[] tSecondaryDescription =
- ((ISecondaryDescribable) tTileEntity.getMetaTileEntity()).getSecondaryDescription();
+ final String[] tSecondaryDescription = ((ISecondaryDescribable) tTileEntity.getMetaTileEntity())
+ .getSecondaryDescription();
addDescription(null, tSecondaryDescription, tDamage, "_Secondary", true);
}
{
final IMetaTileEntity tMetaTileEntity = tTileEntity.getMetaTileEntity();
final String tSuffix = (tMetaTileEntity instanceof ISecondaryDescribable
- && ((ISecondaryDescribable) tMetaTileEntity).isDisplaySecondaryDescription())
- ? "_Secondary"
- : "";
+ && ((ISecondaryDescribable) tMetaTileEntity).isDisplaySecondaryDescription()) ? "_Secondary"
+ : "";
addDescription(
- aList, tTileEntity.getDescription(), tDamage, tSuffix, !GregTech_API.sPostloadFinished);
+ aList,
+ tTileEntity.getDescription(),
+ tDamage,
+ tSuffix,
+ !GregTech_API.sPostloadFinished);
}
if (tTileEntity.getEUCapacity() > 0L) {
if (tTileEntity.getInputVoltage() > 0L) {
final byte inputTier = GT_Utility.getTier(tTileEntity.getInputVoltage());
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_EUp_IN", "Voltage IN: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(tTileEntity.getInputVoltage())
- + " (" + GT_Utility.getColoredTierNameFromTier(inputTier)
- + EnumChatFormatting.GREEN + ")" + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_EUp_IN",
+ "Voltage IN: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(tTileEntity.getInputVoltage())
+ + " ("
+ + GT_Utility.getColoredTierNameFromTier(inputTier)
+ + EnumChatFormatting.GREEN
+ + ")"
+ + EnumChatFormatting.GRAY);
}
if (tTileEntity.getOutputVoltage() > 0L) {
final byte outputTier = GT_Utility.getTier(tTileEntity.getOutputVoltage());
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_EUp_OUT", "Voltage OUT: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(tTileEntity.getOutputVoltage())
- + " (" + GT_Utility.getColoredTierNameFromTier(outputTier)
- + EnumChatFormatting.GREEN + ")" + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_EUp_OUT",
+ "Voltage OUT: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(tTileEntity.getOutputVoltage())
+ + " ("
+ + GT_Utility.getColoredTierNameFromTier(outputTier)
+ + EnumChatFormatting.GREEN
+ + ")"
+ + EnumChatFormatting.GRAY);
}
if (tTileEntity.getOutputAmperage() > 1L) {
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_EUp_AMOUNT", "Amperage: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(tTileEntity.getOutputAmperage())
- + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_EUp_AMOUNT",
+ "Amperage: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(tTileEntity.getOutputAmperage())
+ + EnumChatFormatting.GRAY);
}
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_EUp_STORE", "Capacity: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.BLUE + GT_Utility.formatNumbers(tTileEntity.getEUCapacity())
- + EnumChatFormatting.GRAY + " EU");
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_EUp_STORE",
+ "Capacity: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.BLUE
+ + GT_Utility.formatNumbers(tTileEntity.getEUCapacity())
+ + EnumChatFormatting.GRAY
+ + " EU");
}
if (GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaTileEntity_QuantumTank
|| GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaTileEntity_SuperTank) {
if (aStack.hasTagCompound() && aStack.stackTagCompound.hasKey("mFluid")) {
- final FluidStack tContents =
- FluidStack.loadFluidStackFromNBT(aStack.stackTagCompound.getCompoundTag("mFluid"));
+ final FluidStack tContents = FluidStack
+ .loadFluidStackFromNBT(aStack.stackTagCompound.getCompoundTag("mFluid"));
if (tContents != null && tContents.amount > 0) {
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_TANK_INFO", "Contains Fluid: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.YELLOW
- + tContents.getLocalizedName()
- + EnumChatFormatting.GRAY);
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_TANK_AMOUNT", "Fluid Amount: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(tContents.amount) + " L"
- + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_TANK_INFO",
+ "Contains Fluid: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.YELLOW
+ + tContents.getLocalizedName()
+ + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_TANK_AMOUNT",
+ "Fluid Amount: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(tContents.amount)
+ + " L"
+ + EnumChatFormatting.GRAY);
}
}
}
if (GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaTileEntity_DigitalChestBase) {
if (aStack.hasTagCompound() && aStack.stackTagCompound.hasKey("mItemStack")) {
- final ItemStack tContents =
- ItemStack.loadItemStackFromNBT(aStack.stackTagCompound.getCompoundTag("mItemStack"));
+ final ItemStack tContents = ItemStack
+ .loadItemStackFromNBT(aStack.stackTagCompound.getCompoundTag("mItemStack"));
final int tSize = aStack.stackTagCompound.getInteger("mItemCount");
if (tContents != null && tSize > 0) {
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_CHEST_INFO", "Contains Item: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.YELLOW
- + tContents.getDisplayName()
- + EnumChatFormatting.GRAY);
- aList.add(GT_LanguageManager.addStringLocalization(
- "TileEntity_CHEST_AMOUNT", "Item Amount: ", !GregTech_API.sPostloadFinished)
- + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(tSize)
- + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_CHEST_INFO",
+ "Contains Item: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.YELLOW
+ + tContents.getDisplayName()
+ + EnumChatFormatting.GRAY);
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "TileEntity_CHEST_AMOUNT",
+ "Item Amount: ",
+ !GregTech_API.sPostloadFinished) + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(tSize)
+ + EnumChatFormatting.GRAY);
}
}
}
@@ -144,20 +179,27 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
final NBTTagCompound aNBT = aStack.getTagCompound();
if (aNBT != null) {
if (aNBT.getBoolean("mMuffler")) {
- aList.add(GT_LanguageManager.addStringLocalization(
- "GT_TileEntity_MUFFLER", "has Muffler Upgrade", !GregTech_API.sPostloadFinished));
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "GT_TileEntity_MUFFLER",
+ "has Muffler Upgrade",
+ !GregTech_API.sPostloadFinished));
}
if (aNBT.getBoolean("mSteamConverter")) {
- aList.add(GT_LanguageManager.addStringLocalization(
- "GT_TileEntity_STEAMCONVERTER", "has Steam Upgrade", !GregTech_API.sPostloadFinished));
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ "GT_TileEntity_STEAMCONVERTER",
+ "has Steam Upgrade",
+ !GregTech_API.sPostloadFinished));
}
int tAmount = 0;
if ((tAmount = aNBT.getByte("mSteamTanks")) > 0) {
- aList.add(tAmount + " "
- + GT_LanguageManager.addStringLocalization(
- "GT_TileEntity_STEAMTANKS",
- "Steam Tank Upgrades",
- !GregTech_API.sPostloadFinished));
+ aList.add(
+ tAmount + " "
+ + GT_LanguageManager.addStringLocalization(
+ "GT_TileEntity_STEAMTANKS",
+ "Steam Tank Upgrades",
+ !GregTech_API.sPostloadFinished));
}
CoverableTileEntity.addInstalledCoversInformation(aNBT, aList);
@@ -167,12 +209,8 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
}
}
- private void addDescription(
- @Nullable List<String> aList,
- @Nullable String[] aDescription,
- int aDamage,
- String aSuffix,
- boolean aWriteIntoLangFile) {
+ private void addDescription(@Nullable List<String> aList, @Nullable String[] aDescription, int aDamage,
+ String aSuffix, boolean aWriteIntoLangFile) {
if (aDescription == null) return;
for (int i = 0, tLength = aDescription.length; i < tLength; i++) {
String tDescLine = aDescription[i];
@@ -183,12 +221,11 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
final String[] tSplitStrings = tDescLine.split("%%%");
final StringBuilder tBuffer = new StringBuilder();
final String[] tRep = new String[tSplitStrings.length / 2];
- for (int j = 0; j < tSplitStrings.length; j++)
- if (j % 2 == 0) tBuffer.append(tSplitStrings[j]);
- else {
- tBuffer.append(" %s");
- tRep[j / 2] = tSplitStrings[j];
- }
+ for (int j = 0; j < tSplitStrings.length; j++) if (j % 2 == 0) tBuffer.append(tSplitStrings[j]);
+ else {
+ tBuffer.append(" %s");
+ tRep[j / 2] = tSplitStrings[j];
+ }
final String tTranslated = String.format(
GT_LanguageManager.addStringLocalization(tKey, tBuffer.toString(), aWriteIntoLangFile),
(Object[]) tRep);
@@ -201,17 +238,8 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
}
@Override
- public boolean onItemUseFirst(
- ItemStack stack,
- EntityPlayer player,
- World world,
- int x,
- int y,
- int z,
- int side,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side,
+ float hitX, float hitY, float hitZ) {
return false;
}
@@ -231,8 +259,7 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
public String getItemStackDisplayName(ItemStack aStack) {
String aName = super.getItemStackDisplayName(aStack);
final short aDamage = (short) getDamage(aStack);
- if (aDamage >= 0
- && aDamage < GregTech_API.METATILEENTITIES.length
+ if (aDamage >= 0 && aDamage < GregTech_API.METATILEENTITIES.length
&& GregTech_API.METATILEENTITIES[aDamage] != null) {
Materials aMaterial = null;
if (GregTech_API.METATILEENTITIES[aDamage] instanceof GT_MetaPipeEntity_Item) {
@@ -255,26 +282,15 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
public void onCreated(ItemStack aStack, World aWorld, EntityPlayer aPlayer) {
super.onCreated(aStack, aWorld, aPlayer);
final short tDamage = (short) getDamage(aStack);
- if ((tDamage < 0)
- || ((tDamage >= GregTech_API.METATILEENTITIES.length)
- && (GregTech_API.METATILEENTITIES[tDamage] != null))) {
+ if ((tDamage < 0) || ((tDamage >= GregTech_API.METATILEENTITIES.length)
+ && (GregTech_API.METATILEENTITIES[tDamage] != null))) {
GregTech_API.METATILEENTITIES[tDamage].onCreated(aStack, aWorld, aPlayer);
}
}
@Override
- public boolean placeBlockAt(
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int side,
- float hitX,
- float hitY,
- float hitZ,
- int aMeta) {
+ public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side,
+ float hitX, float hitY, float hitZ, int aMeta) {
final short tDamage = (short) getDamage(aStack);
if (tDamage > 0) {
if (GregTech_API.METATILEENTITIES[tDamage] == null) {
@@ -336,9 +352,8 @@ public class GT_Item_Machines extends ItemBlock implements IFluidContainerItem {
aStack.setTagCompound(null);
return;
}
- if ((tNBT.hasKey("mItemCount") && tNBT.getInteger("mItemCount") > 0)
- || (tNBT.hasKey("mFluid")
- && FluidStack.loadFluidStackFromNBT(tNBT.getCompoundTag("mFluid")).amount > 64000)) {
+ if ((tNBT.hasKey("mItemCount") && tNBT.getInteger("mItemCount") > 0) || (tNBT.hasKey("mFluid")
+ && FluidStack.loadFluidStackFromNBT(tNBT.getCompoundTag("mFluid")).amount > 64000)) {
final FluidStack tFluid = FluidStack.loadFluidStackFromNBT(tNBT.getCompoundTag("mFluid"));
int tEffectDuration = 1200;
if (tFluid != null) {
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Ores.java b/src/main/java/gregtech/common/blocks/GT_Item_Ores.java
index 117e6ae1c6..e32558795c 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Ores.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Ores.java
@@ -1,17 +1,21 @@
package gregtech.common.blocks;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.Materials;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
+
import org.apache.commons.lang3.StringUtils;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.Materials;
+
public class GT_Item_Ores extends ItemBlock {
+
public GT_Item_Ores(Block block) {
super(block);
setMaxDamage(0);
@@ -20,17 +24,8 @@ public class GT_Item_Ores extends ItemBlock {
}
@Override
- public boolean onItemUseFirst(
- ItemStack stack,
- EntityPlayer player,
- World world,
- int x,
- int y,
- int z,
- int side,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side,
+ float hitX, float hitY, float hitZ) {
return false;
}
@@ -49,18 +44,8 @@ public class GT_Item_Ores extends ItemBlock {
}
@Override
- public boolean placeBlockAt(
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int side,
- float hitX,
- float hitY,
- float hitZ,
- int aMeta) {
+ public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side,
+ float hitX, float hitY, float hitZ, int aMeta) {
short tDamage = (short) getDamage(aStack);
if (tDamage > 0) {
if (!aWorld.setBlock(
@@ -89,8 +74,8 @@ public class GT_Item_Ores extends ItemBlock {
@Override
public void addInformation(ItemStack aStack, EntityPlayer aPlayer, List aList, boolean aF3_H) {
- String formula = StatCollector.translateToLocal(
- field_150939_a.getUnlocalizedName() + '.' + getDamage(aStack) + ".tooltip");
+ String formula = StatCollector
+ .translateToLocal(field_150939_a.getUnlocalizedName() + '.' + getDamage(aStack) + ".tooltip");
if (!StringUtils.isBlank(formula)) aList.add(formula);
}
}
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java
index b62c7c0232..db6356b173 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Stones_Abstract.java
@@ -1,16 +1,19 @@
package gregtech.common.blocks;
-import gregtech.api.GregTech_API;
-import gregtech.api.util.GT_LanguageManager;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
+import gregtech.api.GregTech_API;
+import gregtech.api.util.GT_LanguageManager;
+
public class GT_Item_Stones_Abstract extends ItemBlock {
- private final String mNoMobsToolTip =
- GT_LanguageManager.addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
+
+ private final String mNoMobsToolTip = GT_LanguageManager
+ .addStringLocalization("gt.nomobspawnsonthisblock", "Mobs cannot Spawn on this Block");
public GT_Item_Stones_Abstract(Block block) {
super(block);
diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Storage.java b/src/main/java/gregtech/common/blocks/GT_Item_Storage.java
index 55c19ae48c..fddf64163d 100644
--- a/src/main/java/gregtech/common/blocks/GT_Item_Storage.java
+++ b/src/main/java/gregtech/common/blocks/GT_Item_Storage.java
@@ -1,13 +1,16 @@
package gregtech.common.blocks;
-import gregtech.api.GregTech_API;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemBlock;
import net.minecraft.item.ItemStack;
+import gregtech.api.GregTech_API;
+
public class GT_Item_Storage extends ItemBlock {
+
public GT_Item_Storage(Block block) {
super(block);
setMaxDamage(0);
diff --git a/src/main/java/gregtech/common/blocks/GT_Material_Casings.java b/src/main/java/gregtech/common/blocks/GT_Material_Casings.java
index 3b6cd37f9c..2fc839768f 100644
--- a/src/main/java/gregtech/common/blocks/GT_Material_Casings.java
+++ b/src/main/java/gregtech/common/blocks/GT_Material_Casings.java
@@ -4,6 +4,7 @@ import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
public class GT_Material_Casings extends Material {
+
public static final Material INSTANCE = new GT_Material_Casings();
private GT_Material_Casings() {
diff --git a/src/main/java/gregtech/common/blocks/GT_Material_Machines.java b/src/main/java/gregtech/common/blocks/GT_Material_Machines.java
index d51e588522..df8b57226c 100644
--- a/src/main/java/gregtech/common/blocks/GT_Material_Machines.java
+++ b/src/main/java/gregtech/common/blocks/GT_Material_Machines.java
@@ -4,6 +4,7 @@ import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
public class GT_Material_Machines extends Material {
+
public GT_Material_Machines() {
super(MapColor.ironColor);
setRequiresTool();
diff --git a/src/main/java/gregtech/common/blocks/GT_Material_Reinforced.java b/src/main/java/gregtech/common/blocks/GT_Material_Reinforced.java
index 38de5dbee7..2e3301bb60 100644
--- a/src/main/java/gregtech/common/blocks/GT_Material_Reinforced.java
+++ b/src/main/java/gregtech/common/blocks/GT_Material_Reinforced.java
@@ -4,6 +4,7 @@ import net.minecraft.block.material.MapColor;
import net.minecraft.block.material.Material;
public class GT_Material_Reinforced extends Material {
+
public GT_Material_Reinforced() {
super(MapColor.stoneColor);
setRequiresTool();
diff --git a/src/main/java/gregtech/common/blocks/GT_Packet_Ores.java b/src/main/java/gregtech/common/blocks/GT_Packet_Ores.java
index 657ac9b934..d7ab28a19e 100644
--- a/src/main/java/gregtech/common/blocks/GT_Packet_Ores.java
+++ b/src/main/java/gregtech/common/blocks/GT_Packet_Ores.java
@@ -1,13 +1,16 @@
package gregtech.common.blocks;
-import com.google.common.io.ByteArrayDataInput;
-import gregtech.api.net.GT_Packet_New;
-import io.netty.buffer.ByteBuf;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
+import com.google.common.io.ByteArrayDataInput;
+
+import gregtech.api.net.GT_Packet_New;
+import io.netty.buffer.ByteBuf;
+
public class GT_Packet_Ores extends GT_Packet_New {
+
private int mX;
private int mZ;
private short mY;
diff --git a/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java b/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java
index 452e9db5d4..56a59e7ab3 100644
--- a/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java
+++ b/src/main/java/gregtech/common/blocks/GT_TileEntity_Ores.java
@@ -2,6 +2,17 @@ package gregtech.common.blocks;
import static gregtech.api.enums.TextureSet.SET_NONE;
+import java.util.ArrayList;
+import java.util.Random;
+
+import net.minecraft.block.Block;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.network.Packet;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.World;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
@@ -13,30 +24,20 @@ import gregtech.api.objects.XSTR;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.Random;
-import net.minecraft.block.Block;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.network.Packet;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntity {
+
public short mMetaData = 0;
public boolean mNatural = false;
public boolean mBlocked = true;
public static byte getHarvestData(short aMetaData, int aBaseBlockHarvestLevel) {
Materials aMaterial = GregTech_API.sGeneratedMaterials[(aMetaData % 1000)];
- byte tByte = aMaterial == null
- ? 0
- : (byte) Math.max(
- aBaseBlockHarvestLevel, Math.min(7, aMaterial.mToolQuality - (aMetaData < 16000 ? 0 : 1)));
+ byte tByte = aMaterial == null ? 0
+ : (byte) Math
+ .max(aBaseBlockHarvestLevel, Math.min(7, aMaterial.mToolQuality - (aMetaData < 16000 ? 0 : 1)));
if (GT_Mod.gregtechproxy.mChangeHarvestLevels) {
- tByte = aMaterial == null
- ? 0
+ tByte = aMaterial == null ? 0
: (byte) Math.max(
aBaseBlockHarvestLevel,
Math.min(
@@ -51,8 +52,8 @@ public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntit
return setOreBlock(aWorld, aX, aY, aZ, aMetaData, isSmallOre, true);
}
- public static boolean setOreBlock(
- World aWorld, int aX, int aY, int aZ, int aMetaData, boolean isSmallOre, boolean air) {
+ public static boolean setOreBlock(World aWorld, int aX, int aY, int aZ, int aMetaData, boolean isSmallOre,
+ boolean air) {
if (!air) {
aY = Math.min(aWorld.getActualHeight(), Math.max(aY, 1));
}
@@ -177,35 +178,45 @@ public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntit
public void overrideOreBlockMaterial(Block aOverridingStoneBlock, byte aOverridingStoneMeta) {
if (this.worldObj == null || blockType == null) return;
this.mMetaData = ((short) (int) (this.mMetaData % 1000L + this.mMetaData / 16000L * 16000L));
- if (aOverridingStoneBlock.isReplaceableOreGen(
- this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.netherrack)) {
+ if (aOverridingStoneBlock
+ .isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.netherrack)) {
this.mMetaData = ((short) (this.mMetaData + 1000));
- } else if (aOverridingStoneBlock.isReplaceableOreGen(
- this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.end_stone)) {
- this.mMetaData = ((short) (this.mMetaData + 2000));
- } else if (aOverridingStoneBlock.isReplaceableOreGen(
- this.worldObj, this.xCoord, this.yCoord, this.zCoord, GregTech_API.sBlockGranites)) {
- if (aOverridingStoneBlock == GregTech_API.sBlockGranites) {
- if (aOverridingStoneMeta < 8) {
- this.mMetaData = ((short) (this.mMetaData + 3000));
- } else {
- this.mMetaData = ((short) (this.mMetaData + 4000));
- }
- } else {
- this.mMetaData = ((short) (this.mMetaData + 3000));
- }
- } else if (aOverridingStoneBlock.isReplaceableOreGen(
- this.worldObj, this.xCoord, this.yCoord, this.zCoord, GregTech_API.sBlockStones)) {
- if (aOverridingStoneBlock == GregTech_API.sBlockStones) {
- if (aOverridingStoneMeta < 8) {
- this.mMetaData = ((short) (this.mMetaData + 5000));
- } else {
- this.mMetaData = ((short) (this.mMetaData + 6000));
- }
- } else {
- this.mMetaData = ((short) (this.mMetaData + 5000));
- }
- }
+ } else if (aOverridingStoneBlock
+ .isReplaceableOreGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, Blocks.end_stone)) {
+ this.mMetaData = ((short) (this.mMetaData + 2000));
+ } else
+ if (aOverridingStoneBlock.isReplaceableOreGen(
+ this.worldObj,
+ this.xCoord,
+ this.yCoord,
+ this.zCoord,
+ GregTech_API.sBlockGranites)) {
+ if (aOverridingStoneBlock == GregTech_API.sBlockGranites) {
+ if (aOverridingStoneMeta < 8) {
+ this.mMetaData = ((short) (this.mMetaData + 3000));
+ } else {
+ this.mMetaData = ((short) (this.mMetaData + 4000));
+ }
+ } else {
+ this.mMetaData = ((short) (this.mMetaData + 3000));
+ }
+ } else
+ if (aOverridingStoneBlock.isReplaceableOreGen(
+ this.worldObj,
+ this.xCoord,
+ this.yCoord,
+ this.zCoord,
+ GregTech_API.sBlockStones)) {
+ if (aOverridingStoneBlock == GregTech_API.sBlockStones) {
+ if (aOverridingStoneMeta < 8) {
+ this.mMetaData = ((short) (this.mMetaData + 5000));
+ } else {
+ this.mMetaData = ((short) (this.mMetaData + 6000));
+ }
+ } else {
+ this.mMetaData = ((short) (this.mMetaData + 5000));
+ }
+ }
this.worldObj.setBlockMetadataWithNotify(
this.xCoord,
this.yCoord,
@@ -267,14 +278,20 @@ public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntit
Materials aMaterial = aOreMaterial.mOreReplacement;
ItemStack tStack = GT_OreDictUnificator.get(
- OrePrefixes.gemExquisite, aMaterial, GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L), 1L);
+ OrePrefixes.gemExquisite,
+ aMaterial,
+ GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L),
+ 1L);
if (tStack != null) {
for (int i = 0; i < 1; i++) {
tSelector.add(tStack);
}
}
tStack = GT_OreDictUnificator.get(
- OrePrefixes.gemFlawless, aMaterial, GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L), 1L);
+ OrePrefixes.gemFlawless,
+ aMaterial,
+ GT_OreDictUnificator.get(OrePrefixes.gem, aMaterial, 1L),
+ 1L);
if (tStack != null) {
for (int i = 0; i < 2; i++) {
tSelector.add(tStack);
@@ -287,7 +304,10 @@ public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntit
}
}
tStack = GT_OreDictUnificator.get(
- OrePrefixes.gemFlawed, aMaterial, GT_OreDictUnificator.get(OrePrefixes.crushed, aMaterial, 1L), 1L);
+ OrePrefixes.gemFlawed,
+ aMaterial,
+ GT_OreDictUnificator.get(OrePrefixes.crushed, aMaterial, 1L),
+ 1L);
if (tStack != null) {
for (int i = 0; i < 5; i++) {
tSelector.add(tStack);
@@ -318,21 +338,19 @@ public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntit
if (!tSelector.isEmpty()) {
int i = 0;
for (int j = Math.max(
- 1,
- aMaterial.mOreMultiplier
- + (aFortune > 0 ? tRandom.nextInt(1 + aFortune * aMaterial.mOreMultiplier) : 0)
- / 2);
- i < j;
- i++) {
+ 1,
+ aMaterial.mOreMultiplier
+ + (aFortune > 0 ? tRandom.nextInt(1 + aFortune * aMaterial.mOreMultiplier) : 0) / 2); i
+ < j; i++) {
rList.add(GT_Utility.copyAmount(1L, tSelector.get(tRandom.nextInt(tSelector.size()))));
}
}
if (tRandom.nextInt(3 + aFortune) > 1) {
- Materials dustMat =
- ((GT_Block_Ores_Abstract) aDroppedOre).getDroppedDusts()[this.mMetaData / 1000 % 16];
- if (dustMat != null)
- rList.add(GT_OreDictUnificator.get(
- tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, dustMat, 1L));
+ Materials dustMat = ((GT_Block_Ores_Abstract) aDroppedOre).getDroppedDusts()[this.mMetaData / 1000
+ % 16];
+ if (dustMat != null) rList.add(
+ GT_OreDictUnificator
+ .get(tRandom.nextInt(3) > 0 ? OrePrefixes.dustImpure : OrePrefixes.dust, dustMat, 1L));
}
}
return rList;
@@ -343,27 +361,16 @@ public class GT_TileEntity_Ores extends TileEntity implements ITexturedTileEntit
Materials aMaterial = GregTech_API.sGeneratedMaterials[(this.mMetaData % 1000)];
if ((aMaterial != null) && (this.mMetaData < 32000)) {
ITexture iTexture = TextureFactory.builder()
- .addIcon(aMaterial
- .mIconSet
- .mTextures[
- this.mMetaData / 16000 == 0
- ? OrePrefixes.ore.mTextureIndex
+ .addIcon(
+ aMaterial.mIconSet.mTextures[this.mMetaData / 16000 == 0 ? OrePrefixes.ore.mTextureIndex
: OrePrefixes.oreSmall.mTextureIndex])
- .setRGBA(aMaterial.mRGBa)
- .stdOrient()
- .build();
+ .setRGBA(aMaterial.mRGBa).stdOrient().build();
if (aBlock instanceof GT_Block_Ores_Abstract) {
return new ITexture[] {
- ((GT_Block_Ores_Abstract) aBlock).getTextureSet()[((this.mMetaData / 1000) % 16)], iTexture
- };
+ ((GT_Block_Ores_Abstract) aBlock).getTextureSet()[((this.mMetaData / 1000) % 16)], iTexture };
}
}
- return new ITexture[] {
- TextureFactory.of(Blocks.stone, 0),
- TextureFactory.builder()
- .addIcon(SET_NONE.mTextures[OrePrefixes.ore.mTextureIndex])
- .stdOrient()
- .build()
- };
+ return new ITexture[] { TextureFactory.of(Blocks.stone, 0), TextureFactory.builder()
+ .addIcon(SET_NONE.mTextures[OrePrefixes.ore.mTextureIndex]).stdOrient().build() };
}
}
diff --git a/src/main/java/gregtech/common/covers/CoverInfo.java b/src/main/java/gregtech/common/covers/CoverInfo.java
index 58b1afe5ba..206a82ca2e 100644
--- a/src/main/java/gregtech/common/covers/CoverInfo.java
+++ b/src/main/java/gregtech/common/covers/CoverInfo.java
@@ -2,21 +2,25 @@ package gregtech.common.covers;
import static gregtech.api.enums.GT_Values.SIDE_UNKNOWN;
+import java.lang.ref.WeakReference;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
+
import gregtech.api.GregTech_API;
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.GT_CoverBehaviorBase;
import gregtech.api.util.ISerializableObject;
-import java.lang.ref.WeakReference;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.Fluid;
public final class CoverInfo {
+
private static final String NBT_SIDE = "s", NBT_ID = "id", NBT_DATA = "d";
public static final CoverInfo EMPTY_INFO = new CoverInfo(SIDE_UNKNOWN, null);
@@ -44,8 +48,7 @@ public final class CoverInfo {
coverSide = aNBT.getByte(NBT_SIDE);
coverID = aNBT.getInteger(NBT_ID);
coverBehavior = GregTech_API.getCoverBehaviorNew(coverID);
- coverData = aNBT.hasKey(NBT_DATA)
- ? coverBehavior.createDataObject(aNBT.getTag(NBT_DATA))
+ coverData = aNBT.hasKey(NBT_DATA) ? coverBehavior.createDataObject(aNBT.getTag(NBT_DATA))
: coverBehavior.createDataObject();
coveredTile = new WeakReference<>(aTile);
}
@@ -158,8 +161,12 @@ public final class CoverInfo {
}
public ModularWindow createWindow(EntityPlayer player) {
- final GT_CoverUIBuildContext buildContext =
- new GT_CoverUIBuildContext(player, coverID, coverSide, coveredTile.get(), true);
+ final GT_CoverUIBuildContext buildContext = new GT_CoverUIBuildContext(
+ player,
+ coverID,
+ coverSide,
+ coveredTile.get(),
+ true);
return getCoverBehavior().createWindow(buildContext);
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Arm.java b/src/main/java/gregtech/common/covers/GT_Cover_Arm.java
index 6a7711a242..845e74d1ab 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Arm.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Arm.java
@@ -1,10 +1,17 @@
package gregtech.common.covers;
+import net.minecraft.client.gui.GuiScreen;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.inventory.IInventory;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.BaseTextFieldWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -16,13 +23,9 @@ import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.client.gui.GuiScreen;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_Arm extends GT_CoverBehavior {
+
public final int mTickRate;
// msb converted, 2nd : direction (1=export)
// right 14 bits: internalSlot, next 14 bits adjSlot, 0 = all, slot = -1
@@ -49,14 +52,14 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if ((((aTileEntity instanceof IMachineProgress)) && (!((IMachineProgress) aTileEntity).isAllowedToWork()))) {
return aCoverVariable;
}
@@ -102,23 +105,31 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
if ((aCoverVariable & EXPORT_MASK) > 0) side = aSide;
else side = GT_Utility.getOppositeSide(aSide);
movedItems = GT_Utility.moveOneItemStackIntoSlot(
- fromTile, toTile, side, toSlot - 1, null, false, (byte) 64, (byte) 1, (byte) 64, (byte) 1);
+ fromTile,
+ toTile,
+ side,
+ toSlot - 1,
+ null,
+ false,
+ (byte) 64,
+ (byte) 1,
+ (byte) 64,
+ (byte) 1);
} else if (fromSlot > 0) {
byte toSide;
if ((aCoverVariable & EXPORT_MASK) > 0) toSide = aSide;
else toSide = GT_Utility.getOppositeSide(aSide);
- if (fromTile instanceof IInventory)
- movedItems = GT_Utility.moveFromSlotToSide(
- (IInventory) fromTile,
- toTile,
- fromSlot - 1,
- toSide,
- null,
- false,
- (byte) 64,
- (byte) 1,
- (byte) 64,
- (byte) 1);
+ if (fromTile instanceof IInventory) movedItems = GT_Utility.moveFromSlotToSide(
+ (IInventory) fromTile,
+ toTile,
+ fromSlot - 1,
+ toSide,
+ null,
+ false,
+ (byte) 64,
+ (byte) 1,
+ (byte) 64,
+ (byte) 1);
} else {
byte fromSide, toSide;
if ((aCoverVariable & EXPORT_MASK) > 0) {
@@ -129,22 +140,24 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
toSide = aSide;
}
movedItems = GT_Utility.moveOneItemStack(
- fromTile, toTile, fromSide, toSide, null, false, (byte) 64, (byte) 1, (byte) 64, (byte) 1);
+ fromTile,
+ toTile,
+ fromSide,
+ toSide,
+ null,
+ false,
+ (byte) 64,
+ (byte) 1,
+ (byte) 64,
+ (byte) 1);
}
return aCoverVariable;
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
int step = 0;
if (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) {
step += aPlayer.isSneaking() ? 256 : 16;
@@ -157,15 +170,9 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- ISerializableObject.LegacyCoverData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID,
+ ISerializableObject.LegacyCoverData aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX,
+ float aY, float aZ) {
int step = (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) ? 1 : -1;
int tCoverVariable = getNewVar(aCoverVariable.get(), step);
sendMessageToPlayer(aPlayer, tCoverVariable);
@@ -175,15 +182,8 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
@Override
@SuppressWarnings("deprecation")
- public boolean onCoverRightclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public boolean onCoverRightclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
int step = (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) ? 1 : -1;
aCoverVariable = getNewVar(aCoverVariable, step);
sendMessageToPlayer(aPlayer, aCoverVariable);
@@ -192,13 +192,12 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
}
private void sendMessageToPlayer(EntityPlayer aPlayer, int var) {
- if ((var & EXPORT_MASK) != 0)
- GT_Utility.sendChatToPlayer(
- aPlayer,
- GT_Utility.trans("001", "Puts out into adjacent Slot #") + (((var >> 14) & SLOT_ID_MASK) - 1));
- else
- GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("002", "Grabs in for own Slot #") + ((var & SLOT_ID_MASK) - 1));
+ if ((var & EXPORT_MASK) != 0) GT_Utility.sendChatToPlayer(
+ aPlayer,
+ GT_Utility.trans("001", "Puts out into adjacent Slot #") + (((var >> 14) & SLOT_ID_MASK) - 1));
+ else GT_Utility.sendChatToPlayer(
+ aPlayer,
+ GT_Utility.trans("002", "Grabs in for own Slot #") + ((var & SLOT_ID_MASK) - 1));
}
private int getNewVar(int var, int step) {
@@ -305,7 +304,8 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
maxSlot = getMaxSlot();
- builder.widget(new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_Arm.this)
+ builder.widget(
+ new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_Arm.this)
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofDisableable(),
coverData -> getFlagExport(convert(coverData)) > 0,
@@ -341,79 +341,73 @@ public class GT_Cover_Arm extends GT_CoverBehavior {
coverData -> getTextFieldContent(getFlagInternalSlot(convert(coverData)) - 1),
(coverData, state) -> {
final int coverVariable = convert(coverData);
- return new ISerializableObject.LegacyCoverData(getFlagExport(coverVariable)
- | ((getIntFromText(state) + 1) & SLOT_ID_MASK)
- | (getFlagAdjacentSlot(coverVariable) << 14)
- | CONVERTED_BIT);
+ return new ISerializableObject.LegacyCoverData(
+ getFlagExport(coverVariable)
+ | ((getIntFromText(state) + 1) & SLOT_ID_MASK)
+ | (getFlagAdjacentSlot(coverVariable) << 14)
+ | CONVERTED_BIT);
},
- widget -> widget.setOnScrollText()
- .setValidator(val -> {
- final int valSlot = getIntFromText(val);
- if (valSlot > -1) {
- return TextFieldWidget.format.format(Math.min(valSlot, maxSlot));
- } else {
- return ANY_TEXT;
- }
- })
- .setPattern(BaseTextFieldWidget.NATURAL_NUMS)
- .setFocusOnGuiOpen(true)
- .setPos(spaceX * 0, spaceY * 1 + 2)
- .setSize(spaceX * 2 + 5, 12))
+ widget -> widget.setOnScrollText().setValidator(val -> {
+ final int valSlot = getIntFromText(val);
+ if (valSlot > -1) {
+ return TextFieldWidget.format.format(Math.min(valSlot, maxSlot));
+ } else {
+ return ANY_TEXT;
+ }
+ }).setPattern(BaseTextFieldWidget.NATURAL_NUMS).setFocusOnGuiOpen(true)
+ .setPos(spaceX * 0, spaceY * 1 + 2).setSize(spaceX * 2 + 5, 12))
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
coverData -> getTextFieldContent(getFlagAdjacentSlot(convert(coverData)) - 1),
(coverData, state) -> {
final int coverVariable = convert(coverData);
- return new ISerializableObject.LegacyCoverData(getFlagExport(coverVariable)
- | getFlagInternalSlot(coverVariable)
- | (((getIntFromText(state) + 1) & SLOT_ID_MASK) << 14)
- | CONVERTED_BIT);
+ return new ISerializableObject.LegacyCoverData(
+ getFlagExport(coverVariable) | getFlagInternalSlot(coverVariable)
+ | (((getIntFromText(state) + 1) & SLOT_ID_MASK) << 14)
+ | CONVERTED_BIT);
},
widget -> widget.setValidator(val -> {
- final int valSlot = getIntFromText(val);
- final int adjacentMaxSlot;
- final ICoverable tile =
- getUIBuildContext().getTile();
- if (tile instanceof TileEntity && !tile.isDead()) {
- TileEntity adj = tile.getTileEntityAtSide(
- getUIBuildContext().getCoverSide());
- if (adj instanceof IInventory)
- adjacentMaxSlot = ((IInventory) adj).getSizeInventory() - 1;
- else adjacentMaxSlot = -1;
- } else {
- adjacentMaxSlot = -1;
- }
- if (valSlot > -1) {
- return TextFieldWidget.format.format(
- Math.min(valSlot, adjacentMaxSlot));
- } else {
- return ANY_TEXT;
- }
- })
- .setOnScroll((text, direction) -> {
- final int val = getIntFromText(text);
- int step = (GuiScreen.isShiftKeyDown()
- ? 50
- : GuiScreen.isCtrlKeyDown() ? 5 : 1)
- * direction;
- return TextFieldWidget.format.format(val + step);
- })
- .setPattern(BaseTextFieldWidget.NATURAL_NUMS)
- .setPos(spaceX * 0, spaceY * 2 + 2)
+ final int valSlot = getIntFromText(val);
+ final int adjacentMaxSlot;
+ final ICoverable tile = getUIBuildContext().getTile();
+ if (tile instanceof TileEntity && !tile.isDead()) {
+ TileEntity adj = tile
+ .getTileEntityAtSide(getUIBuildContext().getCoverSide());
+ if (adj instanceof IInventory)
+ adjacentMaxSlot = ((IInventory) adj).getSizeInventory() - 1;
+ else adjacentMaxSlot = -1;
+ } else {
+ adjacentMaxSlot = -1;
+ }
+ if (valSlot > -1) {
+ return TextFieldWidget.format.format(Math.min(valSlot, adjacentMaxSlot));
+ } else {
+ return ANY_TEXT;
+ }
+ }).setOnScroll((text, direction) -> {
+ final int val = getIntFromText(text);
+ int step = (GuiScreen.isShiftKeyDown() ? 50 : GuiScreen.isCtrlKeyDown() ? 5 : 1)
+ * direction;
+ return TextFieldWidget.format.format(val + step);
+ }).setPattern(BaseTextFieldWidget.NATURAL_NUMS).setPos(spaceX * 0, spaceY * 2 + 2)
.setSize(spaceX * 2 + 5, 12))
.setPos(startX, startY))
- .widget(TextWidget.dynamicString(() -> (convert(getCoverData()) & EXPORT_MASK) > 0
- ? GT_Utility.trans("006", "Export")
- : GT_Utility.trans("007", "Import"))
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("254.1", "Internal slot#"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("255", "Adjacent slot#"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY + spaceY * 2));
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> (convert(getCoverData()) & EXPORT_MASK) > 0
+ ? GT_Utility.trans("006", "Export")
+ : GT_Utility.trans("007", "Import"))
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("254.1", "Internal slot#"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("255", "Adjacent slot#"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY + spaceY * 2));
}
private int getMaxSlot() {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_ControlsWork.java b/src/main/java/gregtech/common/covers/GT_Cover_ControlsWork.java
index f45ffbf2e8..f3176896f8 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_ControlsWork.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_ControlsWork.java
@@ -2,8 +2,13 @@ package gregtech.common.covers;
import static gregtech.api.enums.GT_Values.ALL_VALID_SIDES;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -15,9 +20,6 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_ControlsWork extends GT_CoverBehavior implements IControlsWorkCover {
@@ -34,8 +36,8 @@ public class GT_Cover_ControlsWork extends GT_CoverBehavior implements IControls
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if (!makeSureOnlyOne(aSide, aTileEntity)) return 0;
if (aTileEntity instanceof IMachineProgress) {
IMachineProgress machine = (IMachineProgress) aTileEntity;
@@ -71,18 +73,15 @@ public class GT_Cover_ControlsWork extends GT_CoverBehavior implements IControls
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide,
- int aCoverID,
- ISerializableObject.LegacyCoverData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID,
+ ISerializableObject.LegacyCoverData aCoverVariable, ICoverable aTileEntity, long aTimer) {
return aCoverVariable.get() != 2; // always off, so no redstone needed either
}
/**
- * Make sure there is only one GT_Cover_ControlsWork on the aTileEntity
- * TODO this is a migration thing. Remove this after 2.3.0 is released.
+ * Make sure there is only one GT_Cover_ControlsWork on the aTileEntity TODO this is a migration thing. Remove this
+ * after 2.3.0 is released.
+ *
* @return true if the cover is the first (side) one
**/
private boolean makeSureOnlyOne(byte aSide, ICoverable aTileEntity) {
@@ -120,8 +119,8 @@ public class GT_Cover_ControlsWork extends GT_CoverBehavior implements IControls
}
@Override
- public boolean onCoverRemoval(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, boolean aForced) {
+ public boolean onCoverRemoval(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ boolean aForced) {
if ((aTileEntity instanceof IMachineProgress)) {
((IMachineProgress) aTileEntity).enableWorking();
((IMachineProgress) aTileEntity).setWorkDataValue((byte) 0);
@@ -130,15 +129,8 @@ public class GT_Cover_ControlsWork extends GT_CoverBehavior implements IControls
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 5;
if (aCoverVariable < 0) {
aCoverVariable = 2;
@@ -209,50 +201,58 @@ public class GT_Cover_ControlsWork extends GT_CoverBehavior implements IControls
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_ControlsWork.this,
+ (id, coverData) -> !getClickable(id, convert(coverData)),
+ (id, coverData) -> new ISerializableObject.LegacyCoverData(
+ getNewCoverVariable(id, convert(coverData)))).addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
+ .setPos(spaceX * 0, spaceY * 0))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
+ .setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CROSS)
+ .setPos(spaceX * 0, spaceY * 2))
+ .setPos(startX, startY))
+ .widget(
+ new CoverDataControllerWidget<>(
this::getCoverData,
this::setCoverData,
- GT_Cover_ControlsWork.this,
- (id, coverData) -> !getClickable(id, convert(coverData)),
- (id, coverData) -> new ISerializableObject.LegacyCoverData(
- getNewCoverVariable(id, convert(coverData))))
- .addToggleButton(
- 0,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
- .setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
- .setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CROSS)
- .setPos(spaceX * 0, spaceY * 2))
- .setPos(startX, startY))
- .widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_ControlsWork.this)
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
- coverData -> convert(coverData) > 2,
- (coverData, state) -> new ISerializableObject.LegacyCoverData(
- adjustCoverVariable(state, convert(coverData))),
- widget -> widget.setPos(spaceX * 0, spaceY * 3))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("243", "Enable with Redstone"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("244", "Disable with Redstone"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("245", "Disable machine"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 2))
- .widget(new TextWidget(GT_Utility.trans("507", "Safe Mode"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 3));
+ GT_Cover_ControlsWork.this)
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
+ coverData -> convert(coverData) > 2,
+ (coverData, state) -> new ISerializableObject.LegacyCoverData(
+ adjustCoverVariable(state, convert(coverData))),
+ widget -> widget.setPos(spaceX * 0, spaceY * 3))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("243", "Enable with Redstone"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("244", "Disable with Redstone"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("245", "Disable machine"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 2))
+ .widget(
+ new TextWidget(GT_Utility.trans("507", "Safe Mode")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 3));
}
private int getNewCoverVariable(int id, int coverVariable) {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Conveyor.java b/src/main/java/gregtech/common/covers/GT_Cover_Conveyor.java
index 54e9e50d8b..a2a0fcb8cf 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Conveyor.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Conveyor.java
@@ -2,8 +2,13 @@ package gregtech.common.covers;
import static gregtech.api.util.GT_Utility.moveMultipleItemStacks;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -14,11 +19,9 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_Conveyor extends GT_CoverBehavior {
+
public final int mTickRate;
private final int mMaxStacks;
@@ -45,14 +48,14 @@ public class GT_Cover_Conveyor extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if ((aCoverVariable % 6 > 1) && ((aTileEntity instanceof IMachineProgress))) {
if (((IMachineProgress) aTileEntity).isAllowedToWork() != aCoverVariable % 6 < 4) {
return aCoverVariable;
@@ -81,15 +84,8 @@ public class GT_Cover_Conveyor extends GT_CoverBehavior {
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 12;
if (aCoverVariable < 0) {
aCoverVariable = 11;
@@ -216,65 +212,80 @@ public class GT_Cover_Conveyor extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_Conveyor.this,
- (id, coverData) -> !getClickable(id, convert(coverData)),
- (id, coverData) -> new ISerializableObject.LegacyCoverData(
- getNewCoverVariable(id, convert(coverData))))
- .addToggleButton(
- 0,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
- .addTooltip(GT_Utility.trans("006", "Export"))
- .setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
- .addTooltip(GT_Utility.trans("007", "Import"))
- .setPos(spaceX * 1, spaceY * 0))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
- .addTooltip(GT_Utility.trans("224", "Always On"))
- .setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 3,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
- .addTooltip(GT_Utility.trans("225", "Active with Redstone Signal"))
- .setPos(spaceX * 1, spaceY * 1))
- .addToggleButton(
- 4,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
- .addTooltip(GT_Utility.trans("226", "Inactive with Redstone Signal"))
- .setPos(spaceX * 2, spaceY * 1))
- .addToggleButton(
- 5,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ALLOW_INPUT)
- .addTooltip(GT_Utility.trans("227", "Allow Input"))
- .setPos(spaceX * 0, spaceY * 2))
- .addToggleButton(
- 6,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLOCK_INPUT)
- .addTooltip(GT_Utility.trans("228", "Block Input"))
- .setPos(spaceX * 1, spaceY * 2))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("229", "Import/Export"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 3 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("230", "Conditional"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 3 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("231", "Enable Input"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 3 + startY + spaceY * 2));
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_Conveyor.this,
+ (id, coverData) -> !getClickable(id, convert(coverData)),
+ (id, coverData) -> new ISerializableObject.LegacyCoverData(
+ getNewCoverVariable(id, convert(coverData)))).addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
+ .addTooltip(GT_Utility.trans("006", "Export"))
+ .setPos(spaceX * 0, spaceY * 0))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
+ .addTooltip(GT_Utility.trans("007", "Import"))
+ .setPos(spaceX * 1, spaceY * 0))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
+ .addTooltip(GT_Utility.trans("224", "Always On"))
+ .setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 3,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
+ .addTooltip(
+ GT_Utility.trans(
+ "225",
+ "Active with Redstone Signal"))
+ .setPos(spaceX * 1, spaceY * 1))
+ .addToggleButton(
+ 4,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
+ .addTooltip(
+ GT_Utility.trans(
+ "226",
+ "Inactive with Redstone Signal"))
+ .setPos(spaceX * 2, spaceY * 1))
+ .addToggleButton(
+ 5,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ALLOW_INPUT)
+ .addTooltip(GT_Utility.trans("227", "Allow Input"))
+ .setPos(spaceX * 0, spaceY * 2))
+ .addToggleButton(
+ 6,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLOCK_INPUT)
+ .addTooltip(GT_Utility.trans("228", "Block Input"))
+ .setPos(spaceX * 1, spaceY * 2))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("229", "Import/Export"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 3 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("230", "Conditional"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 3 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("231", "Enable Input"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 3 + startY + spaceY * 2));
}
private int getNewCoverVariable(int id, int coverVariable) {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Crafting.java b/src/main/java/gregtech/common/covers/GT_Cover_Crafting.java
index 95d5236f60..bcbf07798b 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Crafting.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Crafting.java
@@ -1,13 +1,14 @@
package gregtech.common.covers;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.tileentity.ICoverable;
-import gregtech.api.util.GT_CoverBehavior;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.inventory.ContainerWorkbench;
import net.minecraft.network.play.server.S2DPacketOpenWindow;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.util.GT_CoverBehavior;
+
public class GT_Cover_Crafting extends GT_CoverBehavior {
/**
@@ -23,38 +24,30 @@ public class GT_Cover_Crafting extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public boolean onCoverRightclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public boolean onCoverRightclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
if ((aPlayer instanceof EntityPlayerMP)) {
((EntityPlayerMP) aPlayer).getNextWindowId();
- ((EntityPlayerMP) aPlayer)
- .playerNetServerHandler.sendPacket(new S2DPacketOpenWindow(
- ((EntityPlayerMP) aPlayer).currentWindowId, 1, "Crafting", 9, true));
- ((EntityPlayerMP) aPlayer).openContainer =
- new ContainerWorkbench(
- ((EntityPlayerMP) aPlayer).inventory,
- ((EntityPlayerMP) aPlayer).worldObj,
- aTileEntity.getXCoord(),
- aTileEntity.getYCoord(),
- aTileEntity.getZCoord()) {
- @Override
- public boolean canInteractWith(EntityPlayer player) {
- return true;
- }
- };
+ ((EntityPlayerMP) aPlayer).playerNetServerHandler.sendPacket(
+ new S2DPacketOpenWindow(((EntityPlayerMP) aPlayer).currentWindowId, 1, "Crafting", 9, true));
+ ((EntityPlayerMP) aPlayer).openContainer = new ContainerWorkbench(
+ ((EntityPlayerMP) aPlayer).inventory,
+ ((EntityPlayerMP) aPlayer).worldObj,
+ aTileEntity.getXCoord(),
+ aTileEntity.getYCoord(),
+ aTileEntity.getZCoord()) {
+
+ @Override
+ public boolean canInteractWith(EntityPlayer player) {
+ return true;
+ }
+ };
((EntityPlayerMP) aPlayer).openContainer.windowId = ((EntityPlayerMP) aPlayer).currentWindowId;
((EntityPlayerMP) aPlayer).openContainer.addCraftingToCrafters((EntityPlayerMP) aPlayer);
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_DoesWork.java b/src/main/java/gregtech/common/covers/GT_Cover_DoesWork.java
index d755a115c4..ff6741067c 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_DoesWork.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_DoesWork.java
@@ -1,7 +1,11 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -12,8 +16,6 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_DoesWork extends GT_CoverBehavior {
@@ -30,32 +32,30 @@ public class GT_Cover_DoesWork extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if ((aTileEntity instanceof IMachineProgress)) {
if (aCoverVariable < 2) {
int tScale = ((IMachineProgress) aTileEntity).getMaxProgress() / 15;
if ((tScale > 0) && (((IMachineProgress) aTileEntity).hasThingsToDo())) {
aTileEntity.setOutputRedstoneSignal(
aSide,
- aCoverVariable % 2 == 0
- ? (byte) (((IMachineProgress) aTileEntity).getProgress() / tScale)
+ aCoverVariable % 2 == 0 ? (byte) (((IMachineProgress) aTileEntity).getProgress() / tScale)
: (byte) (15 - ((IMachineProgress) aTileEntity).getProgress() / tScale));
} else {
aTileEntity.setOutputRedstoneSignal(aSide, (byte) (aCoverVariable % 2 == 0 ? 0 : 15));
}
} else {
- aTileEntity.setOutputRedstoneSignal(aSide, (byte)
- ((aCoverVariable % 2 == 0 ? 1 : 0)
- != (((IMachineProgress) aTileEntity).getMaxProgress() == 0 ? 1 : 0)
- ? 0
- : 15));
+ aTileEntity.setOutputRedstoneSignal(
+ aSide,
+ (byte) ((aCoverVariable % 2 == 0 ? 1 : 0)
+ != (((IMachineProgress) aTileEntity).getMaxProgress() == 0 ? 1 : 0) ? 0 : 15));
}
} else {
aTileEntity.setOutputRedstoneSignal(aSide, (byte) 0);
@@ -64,15 +64,8 @@ public class GT_Cover_DoesWork extends GT_CoverBehavior {
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 4;
if (aCoverVariable < 0) {
aCoverVariable = 3;
@@ -125,8 +118,8 @@ public class GT_Cover_DoesWork extends GT_CoverBehavior {
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -166,40 +159,45 @@ public class GT_Cover_DoesWork extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_DoesWork.this,
- (id, coverData) -> isEnabled(id, convert(coverData)),
- (id, coverData) -> new ISerializableObject.LegacyCoverData(
- getNewCoverVariable(id, convert(coverData))))
- .addToggleButton(
- 0,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_PROGRESS)
- .setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
- .setPos(spaceX * 1, spaceY * 0))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofRedstone(),
- widget -> widget.setPos(spaceX * 0, spaceY * 1))
- .setPos(startX, startY))
- .widget(TextWidget.dynamicString(() -> ((convert(getCoverData()) & 0x2) > 0)
- ? GT_Utility.trans("242", "Machine idle")
- : GT_Utility.trans("241", "Recipe progress"))
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY + spaceY * 0))
- .widget(TextWidget.dynamicString(() -> ((convert(getCoverData()) & 0x1) > 0)
- ? GT_Utility.trans("INVERTED", "Inverted")
- : GT_Utility.trans("NORMAL", "Normal"))
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY + spaceY * 1));
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_DoesWork.this,
+ (id, coverData) -> isEnabled(id, convert(coverData)),
+ (id, coverData) -> new ISerializableObject.LegacyCoverData(
+ getNewCoverVariable(id, convert(coverData)))).addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_PROGRESS)
+ .setPos(spaceX * 0, spaceY * 0))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
+ .setPos(spaceX * 1, spaceY * 0))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofRedstone(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 1))
+ .setPos(startX, startY))
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> ((convert(getCoverData()) & 0x2) > 0)
+ ? GT_Utility.trans("242", "Machine idle")
+ : GT_Utility.trans("241", "Recipe progress"))
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY + spaceY * 0))
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> ((convert(getCoverData()) & 0x1) > 0)
+ ? GT_Utility.trans("INVERTED", "Inverted")
+ : GT_Utility.trans("NORMAL", "Normal"))
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY + spaceY * 1));
}
private int getNewCoverVariable(int id, int coverVariable) {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Drain.java b/src/main/java/gregtech/common/covers/GT_Cover_Drain.java
index cb93df0bd2..a103234fea 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Drain.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Drain.java
@@ -1,11 +1,5 @@
package gregtech.common.covers;
-import gregtech.api.enums.Materials;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.tileentity.ICoverable;
-import gregtech.api.interfaces.tileentity.IMachineProgress;
-import gregtech.api.util.GT_CoverBehavior;
-import gregtech.api.util.GT_Utility;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
@@ -15,6 +9,13 @@ import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidBlock;
import net.minecraftforge.fluids.IFluidHandler;
+import gregtech.api.enums.Materials;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.interfaces.tileentity.IMachineProgress;
+import gregtech.api.util.GT_CoverBehavior;
+import gregtech.api.util.GT_Utility;
+
public class GT_Cover_Drain extends GT_CoverBehavior {
/**
@@ -30,14 +31,14 @@ public class GT_Cover_Drain extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if ((aCoverVariable % 3 > 1) && ((aTileEntity instanceof IMachineProgress))) {
if (((IMachineProgress) aTileEntity).isAllowedToWork() != aCoverVariable % 3 < 2) {
return aCoverVariable;
@@ -46,22 +47,16 @@ public class GT_Cover_Drain extends GT_CoverBehavior {
if (aSide != 6) {
Block tBlock = aTileEntity.getBlockAtSide(aSide);
if ((aCoverVariable < 3) && ((aTileEntity instanceof IFluidHandler))) {
- if ((aSide == 1)
- && (aTileEntity.getWorld().isRaining())
- && (aTileEntity
- .getWorld()
- .getPrecipitationHeight(
- aTileEntity.getXCoord(), aTileEntity.getZCoord())
- - 2
+ if ((aSide == 1) && (aTileEntity.getWorld().isRaining())
+ && (aTileEntity.getWorld()
+ .getPrecipitationHeight(aTileEntity.getXCoord(), aTileEntity.getZCoord()) - 2
< aTileEntity.getYCoord())) {
int tAmount = (int) (aTileEntity.getBiome().rainfall * 10.0F);
if (tAmount > 0) {
- ((IFluidHandler) aTileEntity)
- .fill(
- ForgeDirection.getOrientation(aSide),
- Materials.Water.getFluid(
- aTileEntity.getWorld().isThundering() ? tAmount * 2 : tAmount),
- true);
+ ((IFluidHandler) aTileEntity).fill(
+ ForgeDirection.getOrientation(aSide),
+ Materials.Water.getFluid(aTileEntity.getWorld().isThundering() ? tAmount * 2 : tAmount),
+ true);
}
}
FluidStack tLiquid = null;
@@ -71,64 +66,49 @@ public class GT_Cover_Drain extends GT_CoverBehavior {
tLiquid = Materials.Water.getFluid(1000L);
} else if (((tBlock == Blocks.lava) || (tBlock == Blocks.flowing_lava))
&& (aTileEntity.getMetaIDAtSide(aSide) == 0)) {
- tLiquid = Materials.Lava.getFluid(1000L);
- } else if ((tBlock instanceof IFluidBlock)) {
- tLiquid = ((IFluidBlock) tBlock)
- .drain(
- aTileEntity.getWorld(),
- aTileEntity.getOffsetX(aSide, 1),
- aTileEntity.getOffsetY(aSide, 1),
- aTileEntity.getOffsetZ(aSide, 1),
- false);
- }
- if ((tLiquid != null)
- && (tLiquid.getFluid() != null)
- && ((aSide > 1)
- || ((aSide == 0) && (tLiquid.getFluid().getDensity() <= 0))
+ tLiquid = Materials.Lava.getFluid(1000L);
+ } else
+ if ((tBlock instanceof IFluidBlock)) {
+ tLiquid = ((IFluidBlock) tBlock).drain(
+ aTileEntity.getWorld(),
+ aTileEntity.getOffsetX(aSide, 1),
+ aTileEntity.getOffsetY(aSide, 1),
+ aTileEntity.getOffsetZ(aSide, 1),
+ false);
+ }
+ if ((tLiquid != null) && (tLiquid.getFluid() != null)
+ && ((aSide > 1) || ((aSide == 0) && (tLiquid.getFluid().getDensity() <= 0))
|| ((aSide == 1) && (tLiquid.getFluid().getDensity() >= 0)))
&& (((IFluidHandler) aTileEntity).fill(ForgeDirection.getOrientation(aSide), tLiquid, false)
== tLiquid.amount)) {
((IFluidHandler) aTileEntity).fill(ForgeDirection.getOrientation(aSide), tLiquid, true);
- aTileEntity
- .getWorld()
- .setBlockToAir(
- aTileEntity.getXCoord() + ForgeDirection.getOrientation(aSide).offsetX,
- aTileEntity.getYCoord() + ForgeDirection.getOrientation(aSide).offsetY,
- aTileEntity.getZCoord() + ForgeDirection.getOrientation(aSide).offsetZ);
+ aTileEntity.getWorld().setBlockToAir(
+ aTileEntity.getXCoord() + ForgeDirection.getOrientation(aSide).offsetX,
+ aTileEntity.getYCoord() + ForgeDirection.getOrientation(aSide).offsetY,
+ aTileEntity.getZCoord() + ForgeDirection.getOrientation(aSide).offsetZ);
}
}
}
- if ((aCoverVariable >= 3)
- && (tBlock != null)
- && ((tBlock == Blocks.lava)
- || (tBlock == Blocks.flowing_lava)
+ if ((aCoverVariable >= 3) && (tBlock != null)
+ && ((tBlock == Blocks.lava) || (tBlock == Blocks.flowing_lava)
|| (tBlock == Blocks.water)
|| (tBlock == Blocks.flowing_water)
|| ((tBlock instanceof IFluidBlock)))) {
- aTileEntity
- .getWorld()
- .setBlock(
- aTileEntity.getOffsetX(aSide, 1),
- aTileEntity.getOffsetY(aSide, 1),
- aTileEntity.getOffsetZ(aSide, 1),
- Blocks.air,
- 0,
- 0);
+ aTileEntity.getWorld().setBlock(
+ aTileEntity.getOffsetX(aSide, 1),
+ aTileEntity.getOffsetY(aSide, 1),
+ aTileEntity.getOffsetZ(aSide, 1),
+ Blocks.air,
+ 0,
+ 0);
}
}
return aCoverVariable;
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 6;
if (aCoverVariable < 0) {
aCoverVariable = 5;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_EUMeter.java b/src/main/java/gregtech/common/covers/GT_Cover_EUMeter.java
index fbac598d19..53ce2bcbb3 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_EUMeter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_EUMeter.java
@@ -1,9 +1,21 @@
package gregtech.common.covers;
+import java.util.function.Function;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.Fluid;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -19,14 +31,6 @@ import gregtech.common.gui.modularui.widget.CoverDataFollower_CycleButtonWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.function.Function;
-import javax.annotation.Nonnull;
-import javax.annotation.Nullable;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMeterData> {
@@ -53,13 +57,8 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
}
@Override
- protected EUMeterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- EUMeterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected EUMeterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID, EUMeterData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
final long stored = aCoverVariable.type.getTileEntityStoredEnergy(aTileEntity);
final long capacity = aCoverVariable.type.getTileEntityEnergyCapacity(aTileEntity);
@@ -93,15 +92,8 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
}
@Override
- protected EUMeterData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- EUMeterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected EUMeterData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
int num = (aCoverVariable.getNum() + (aPlayer.isSneaking() ? -1 : 1) + EnergyType.values().length * 2)
% (EnergyType.values().length * 2);
switch (num) {
@@ -137,11 +129,13 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
break;
case 10:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("041", "Normal Electricity Storage(Including Batteries)"));
+ aPlayer,
+ GT_Utility.trans("041", "Normal Electricity Storage(Including Batteries)"));
break;
case 11:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("042", "Inverted Electricity Storage(Including Batteries)"));
+ aPlayer,
+ GT_Utility.trans("042", "Inverted Electricity Storage(Including Batteries)"));
break;
}
aCoverVariable.setNum(num);
@@ -150,8 +144,8 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
// region Static Result Methods
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, EUMeterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return false;
}
@@ -166,32 +160,32 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, EUMeterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, EUMeterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsInImpl(
- byte aSide, int aCoverID, EUMeterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsInImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsOutImpl(
- byte aSide, int aCoverID, EUMeterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsOutImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, EUMeterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, EUMeterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -234,8 +228,8 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
final String INVERTED = GT_Utility.trans("INVERTED", "Inverted");
final String NORMAL = GT_Utility.trans("NORMAL", "Normal");
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_EUMeter.this)
+ builder.widget(
+ new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_EUMeter.this)
.addFollower(
new CoverDataFollower_CycleButtonWidget<>(),
coverData -> coverData.type.ordinal(),
@@ -244,8 +238,7 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
return coverData;
},
widget -> widget.setLength(EnergyType.values().length)
- .addTooltip(state -> EnergyType.getEnergyType(state)
- .getTooltip())
+ .addTooltip(state -> EnergyType.getEnergyType(state).getTooltip())
.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
.setPos(spaceX * 0, spaceY * 0))
.addFollower(
@@ -255,8 +248,7 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
coverData.inverted = state;
return coverData;
},
- widget -> widget.addTooltip(0, NORMAL)
- .addTooltip(1, INVERTED)
+ widget -> widget.addTooltip(0, NORMAL).addTooltip(1, INVERTED)
.setPos(spaceX * 0, spaceY * 1))
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
@@ -266,30 +258,29 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
return coverData;
},
widget -> widget.setOnScrollNumbersLong(1000, 100, 100000)
- .setNumbersLong(() -> 0L, () -> Long.MAX_VALUE)
- .setFocusOnGuiOpen(true)
- .setPos(spaceX * 0, spaceY * 2 + 2)
- .setSize(spaceX * 8, 12))
+ .setNumbersLong(() -> 0L, () -> Long.MAX_VALUE).setFocusOnGuiOpen(true)
+ .setPos(spaceX * 0, spaceY * 2 + 2).setSize(spaceX * 8, 12))
.setPos(startX, startY))
- .widget(TextWidget.dynamicString(() ->
- getCoverData() != null ? getCoverData().type.getTitle() : "")
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX, 4 + startY))
- .widget(TextWidget.dynamicString(
+ .widget(
+ TextWidget.dynamicString(() -> getCoverData() != null ? getCoverData().type.getTitle() : "")
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get()).setPos(
+ startX + spaceX,
+ 4 + startY))
+ .widget(
+ TextWidget.dynamicString(
() -> getCoverData() != null ? getCoverData().inverted ? INVERTED : NORMAL : "")
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX, 4 + startY + spaceY))
- .widget(new TextWidget(GT_Utility.trans("222.1", "Energy threshold"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX, startY + spaceY * 3 + 4));
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX, 4 + startY + spaceY))
+ .widget(
+ new TextWidget(GT_Utility.trans("222.1", "Energy threshold"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get()).setPos(startX, startY + spaceY * 3 + 4));
}
}
// endregion
public static class EUMeterData implements ISerializableObject {
+
private EnergyType type;
private boolean inverted;
/**
@@ -368,35 +359,20 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
}
private enum EnergyType {
- UNIVERSAL_STORAGE(
- GT_Utility.trans("301", "Universal"),
- GT_Utility.trans("256", "Universal Storage"),
- ICoverable::getUniversalEnergyStored,
- ICoverable::getUniversalEnergyCapacity),
- ELECTRICITY_STORAGE(
- GT_Utility.trans("302", "Int. EU"),
- GT_Utility.trans("257", "Electricity Storage"),
- ICoverable::getStoredEU,
- ICoverable::getEUCapacity),
- STEAM_STORAGE(
- GT_Utility.trans("303", "Steam"),
- GT_Utility.trans("258", "Steam Storage"),
- ICoverable::getStoredSteam,
- ICoverable::getSteamCapacity),
- AVERAGE_ELECTRIC_INPUT(
- GT_Utility.trans("304", "Avg. Input"),
- GT_Utility.trans("259", "Average Electric Input"),
- ICoverable::getAverageElectricInput,
- (te) -> te.getInputVoltage() * te.getInputAmperage()),
- AVERAGE_ELECTRIC_OUTPUT(
- GT_Utility.trans("305", "Avg. Output"),
- GT_Utility.trans("260", "Average Electric Output"),
- ICoverable::getAverageElectricOutput,
+
+ UNIVERSAL_STORAGE(GT_Utility.trans("301", "Universal"), GT_Utility.trans("256", "Universal Storage"),
+ ICoverable::getUniversalEnergyStored, ICoverable::getUniversalEnergyCapacity),
+ ELECTRICITY_STORAGE(GT_Utility.trans("302", "Int. EU"), GT_Utility.trans("257", "Electricity Storage"),
+ ICoverable::getStoredEU, ICoverable::getEUCapacity),
+ STEAM_STORAGE(GT_Utility.trans("303", "Steam"), GT_Utility.trans("258", "Steam Storage"),
+ ICoverable::getStoredSteam, ICoverable::getSteamCapacity),
+ AVERAGE_ELECTRIC_INPUT(GT_Utility.trans("304", "Avg. Input"), GT_Utility.trans("259", "Average Electric Input"),
+ ICoverable::getAverageElectricInput, (te) -> te.getInputVoltage() * te.getInputAmperage()),
+ AVERAGE_ELECTRIC_OUTPUT(GT_Utility.trans("305", "Avg. Output"),
+ GT_Utility.trans("260", "Average Electric Output"), ICoverable::getAverageElectricOutput,
(te) -> te.getOutputVoltage() * te.getOutputAmperage()),
- ELECTRICITY_STORAGE_INCLUDING_BATTERIES(
- GT_Utility.trans("306", "EU stored"),
- GT_Utility.trans("261", "Electricity Storage(Including Batteries)"),
- (te) -> {
+ ELECTRICITY_STORAGE_INCLUDING_BATTERIES(GT_Utility.trans("306", "EU stored"),
+ GT_Utility.trans("261", "Electricity Storage(Including Batteries)"), (te) -> {
if (te instanceof IGregTechTileEntity) {
IMetaTileEntity mte = ((IGregTechTileEntity) te).getMetaTileEntity();
if (mte instanceof GT_MetaTileEntity_BasicBatteryBuffer) {
@@ -405,8 +381,7 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
}
}
return te.getStoredEU();
- },
- (te) -> {
+ }, (te) -> {
if (te instanceof IGregTechTileEntity) {
IMetaTileEntity mte = ((IGregTechTileEntity) te).getMetaTileEntity();
if (mte instanceof GT_MetaTileEntity_BasicBatteryBuffer) {
@@ -422,10 +397,7 @@ public class GT_Cover_EUMeter extends GT_CoverBehaviorBase<GT_Cover_EUMeter.EUMe
private final Function<ICoverable, Long> getTileEntityStoredEnergyFunc;
private final Function<ICoverable, Long> getTileEntityEnergyCapacityFunc;
- EnergyType(
- String title,
- String tooltip,
- Function<ICoverable, Long> getTileEntityStoredEnergyFunc,
+ EnergyType(String title, String tooltip, Function<ICoverable, Long> getTileEntityStoredEnergyFunc,
Function<ICoverable, Long> getTileEntityEnergyCapacityFunc) {
this.title = title;
this.tooltip = tooltip;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_FacadeAE.java b/src/main/java/gregtech/common/covers/GT_Cover_FacadeAE.java
index 5b9c66f637..da6c2c9cfa 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_FacadeAE.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_FacadeAE.java
@@ -1,11 +1,13 @@
package gregtech.common.covers;
-import appeng.facade.IFacadeItem;
import net.minecraft.block.Block;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
+import appeng.facade.IFacadeItem;
+
public class GT_Cover_FacadeAE extends GT_Cover_FacadeBase {
+
@Override
protected Block getTargetBlock(ItemStack aFacadeStack) {
if (aFacadeStack == null) return null;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_FacadeBase.java b/src/main/java/gregtech/common/covers/GT_Cover_FacadeBase.java
index 7c55a9dce8..0ac4a25fa1 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_FacadeBase.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_FacadeBase.java
@@ -2,10 +2,22 @@ package gregtech.common.covers;
import static gregtech.api.enums.GT_Values.ALL_VALID_SIDES;
+import javax.annotation.Nonnull;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.drawable.ItemDrawable;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import cpw.mods.fml.common.network.ByteBufUtils;
import gregtech.api.enums.Textures;
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
@@ -19,17 +31,9 @@ import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import javax.annotation.Nonnull;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_FacadeBase.FacadeData> {
+
/**
* This is the Dummy, if there is a generic Cover without behavior
*/
@@ -53,15 +57,8 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
}
@Override
- protected FacadeData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- FacadeData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected FacadeData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, FacadeData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable.mFlags = ((aCoverVariable.mFlags + 1) & 15);
GT_Utility.sendChatToPlayer(
aPlayer,
@@ -73,14 +70,14 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
}
@Override
- protected boolean letsRedstoneGoInImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsRedstoneGoInImpl(byte aSide, int aCoverID, FacadeData aCoverVariable,
+ ICoverable aTileEntity) {
return (aCoverVariable.mFlags & 1) != 0;
}
@Override
- protected boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, FacadeData aCoverVariable,
+ ICoverable aTileEntity) {
return (aCoverVariable.mFlags & 1) != 0;
}
@@ -95,42 +92,42 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, FacadeData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return (aCoverVariable.mFlags & 4) != 0;
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, FacadeData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return (aCoverVariable.mFlags & 4) != 0;
}
@Override
- protected boolean letsItemsInImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsInImpl(byte aSide, int aCoverID, FacadeData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return (aCoverVariable.mFlags & 8) != 0;
}
@Override
- protected boolean letsItemsOutImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsOutImpl(byte aSide, int aCoverID, FacadeData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return (aCoverVariable.mFlags & 8) != 0;
}
@Override
public void placeCover(byte aSide, ItemStack aCover, ICoverable aTileEntity) {
aTileEntity.setCoverIdAndDataAtSide(
- aSide, GT_Utility.stackToInt(aCover), new FacadeData(GT_Utility.copyAmount(1, aCover), 0));
-
- if (aTileEntity.isClientSide())
- GT_RenderingWorld.getInstance()
- .register(
- aTileEntity.getXCoord(),
- aTileEntity.getYCoord(),
- aTileEntity.getZCoord(),
- getTargetBlock(aCover),
- getTargetMeta(aCover));
+ aSide,
+ GT_Utility.stackToInt(aCover),
+ new FacadeData(GT_Utility.copyAmount(1, aCover), 0));
+
+ if (aTileEntity.isClientSide()) GT_RenderingWorld.getInstance().register(
+ aTileEntity.getXCoord(),
+ aTileEntity.getYCoord(),
+ aTileEntity.getZCoord(),
+ getTargetBlock(aCover),
+ getTargetMeta(aCover));
}
@Override
@@ -139,24 +136,21 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
}
@Override
- protected ITexture getSpecialCoverFGTextureImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity) {
+ protected ITexture getSpecialCoverFGTextureImpl(byte aSide, int aCoverID, FacadeData aCoverVariable,
+ ICoverable aTileEntity) {
return getSpecialCoverTextureImpl(aSide, aCoverID, aCoverVariable, aTileEntity);
}
@Override
- protected ITexture getSpecialCoverTextureImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity) {
+ protected ITexture getSpecialCoverTextureImpl(byte aSide, int aCoverID, FacadeData aCoverVariable,
+ ICoverable aTileEntity) {
if (GT_Utility.isStackInvalid(aCoverVariable.mStack)) return Textures.BlockIcons.ERROR_RENDERING[0];
Block block = getTargetBlock(aCoverVariable.mStack);
if (block == null) return Textures.BlockIcons.ERROR_RENDERING[0];
// TODO: change this when *someone* made the block render in both pass
if (block.getRenderBlockPass() != 0) return Textures.BlockIcons.ERROR_RENDERING[0];
- return TextureFactory.builder()
- .setFromBlock(block, getTargetMeta(aCoverVariable.mStack))
- .useWorldCoord()
- .setFromSide(ForgeDirection.getOrientation(aSide))
- .build();
+ return TextureFactory.builder().setFromBlock(block, getTargetMeta(aCoverVariable.mStack)).useWorldCoord()
+ .setFromSide(ForgeDirection.getOrientation(aSide)).build();
}
@Override
@@ -176,21 +170,19 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
protected abstract int getTargetMeta(ItemStack aFacadeStack);
@Override
- protected boolean isDataNeededOnClientImpl(
- byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean isDataNeededOnClientImpl(byte aSide, int aCoverID, FacadeData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
protected void onDataChangedImpl(byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity) {
- if (aTileEntity.isClientSide())
- GT_RenderingWorld.getInstance()
- .register(
- aTileEntity.getXCoord(),
- aTileEntity.getYCoord(),
- aTileEntity.getZCoord(),
- getTargetBlock(aCoverVariable.mStack),
- getTargetMeta(aCoverVariable.mStack));
+ if (aTileEntity.isClientSide()) GT_RenderingWorld.getInstance().register(
+ aTileEntity.getXCoord(),
+ aTileEntity.getYCoord(),
+ aTileEntity.getZCoord(),
+ getTargetBlock(aCoverVariable.mStack),
+ getTargetMeta(aCoverVariable.mStack));
}
@Override
@@ -203,26 +195,18 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
}
if (aCoverVariable.mStack != null)
// mStack == null -> cover removed before data reach client
- GT_RenderingWorld.getInstance()
- .unregister(
- aTileEntity.getXCoord(),
- aTileEntity.getYCoord(),
- aTileEntity.getZCoord(),
- getTargetBlock(aCoverVariable.mStack),
- getTargetMeta(aCoverVariable.mStack));
+ GT_RenderingWorld.getInstance().unregister(
+ aTileEntity.getXCoord(),
+ aTileEntity.getYCoord(),
+ aTileEntity.getZCoord(),
+ getTargetBlock(aCoverVariable.mStack),
+ getTargetMeta(aCoverVariable.mStack));
}
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- FacadeData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID, FacadeData aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
// in case cover data didn't hit client somehow. maybe he had a ridiculous view distance
aTileEntity.issueCoverUpdate(aSide);
return super.onCoverRightClickImpl(aSide, aCoverID, aCoverVariable, aTileEntity, aPlayer, aX, aY, aZ);
@@ -253,6 +237,7 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
}
public static class FacadeData implements ISerializableObject {
+
ItemStack mStack;
int mFlags;
@@ -331,54 +316,52 @@ public abstract class GT_Cover_FacadeBase extends GT_CoverBehaviorBase<GT_Cover_
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_FacadeBase.this,
- this::isEnabled,
- (id, coverData) -> {
- coverData.mFlags = getNewCoverVariable(id, coverData);
- return coverData;
- })
- .addToggleButton(
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_FacadeBase.this,
+ this::isEnabled,
+ (id, coverData) -> {
+ coverData.mFlags = getNewCoverVariable(id, coverData);
+ return coverData;
+ }).addToggleButton(
0,
CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
widget -> widget.setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
- widget -> widget.setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
- widget -> widget.setPos(spaceX * 0, spaceY * 2))
- .addToggleButton(
- 3,
- CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
- widget -> widget.setPos(spaceX * 0, spaceY * 3))
- .setPos(startX, startY))
- .widget(new ItemDrawable(() -> getCoverData() != null ? getCoverData().mStack : null)
- .asWidget()
- .setPos(5, 5)
- .setSize(16, 16))
- .widget(TextWidget.dynamicString(() -> getCoverData() != null
- ? getCoverData().mStack.getDisplayName()
- : "")
- .setSynced(false)
- .setDefaultColor(COLOR_TITLE.get())
- .setPos(25, 9))
- .widget(new TextWidget(GT_Utility.trans("128", "Redstone"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("129", "Energy"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("130", "Fluids"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 2))
- .widget(new TextWidget(GT_Utility.trans("131", "Items"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 3));
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 2))
+ .addToggleButton(
+ 3,
+ CoverDataFollower_ToggleButtonWidget.ofCheckAndCross(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 3))
+ .setPos(startX, startY))
+ .widget(
+ new ItemDrawable(() -> getCoverData() != null ? getCoverData().mStack : null).asWidget()
+ .setPos(5, 5).setSize(16, 16))
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> getCoverData() != null ? getCoverData().mStack.getDisplayName() : "")
+ .setSynced(false).setDefaultColor(COLOR_TITLE.get()).setPos(25, 9))
+ .widget(
+ new TextWidget(GT_Utility.trans("128", "Redstone")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("129", "Energy")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("130", "Fluids")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 2))
+ .widget(
+ new TextWidget(GT_Utility.trans("131", "Items")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 3));
}
@Override
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_FluidLimiter.java b/src/main/java/gregtech/common/covers/GT_Cover_FluidLimiter.java
index b8200aeac6..53eb3406d4 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_FluidLimiter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_FluidLimiter.java
@@ -1,9 +1,22 @@
package gregtech.common.covers;
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidTankInfo;
+import net.minecraftforge.fluids.IFluidHandler;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -13,16 +26,6 @@ import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import io.netty.buffer.ByteBuf;
-import javax.annotation.Nonnull;
-import javax.annotation.Nullable;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidTankInfo;
-import net.minecraftforge.fluids.IFluidHandler;
/***
* @author TrainerSnow#5086
@@ -42,15 +45,8 @@ public class GT_Cover_FluidLimiter extends GT_CoverBehaviorBase<GT_Cover_FluidLi
}
@Override
- protected FluidLimiterData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- FluidLimiterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected FluidLimiterData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, FluidLimiterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (aTileEntity instanceof IFluidHandler) {
adjustThreshold(aCoverVariable, !aPlayer.isSneaking());
GT_Utility.sendChatToPlayer(aPlayer, String.format("Threshold: %f", aCoverVariable.threshold));
@@ -59,19 +55,19 @@ public class GT_Cover_FluidLimiter extends GT_CoverBehaviorBase<GT_Cover_FluidLi
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, FluidLimiterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, FluidLimiterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return allowsFluidIn(aCoverVariable, aTileEntity);
}
@Override
- protected boolean alwaysLookConnectedImpl(
- byte aSide, int aCoverID, FluidLimiterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean alwaysLookConnectedImpl(byte aSide, int aCoverID, FluidLimiterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
/*
- Helpers
+ * Helpers
*/
private boolean allowsFluidIn(FluidLimiterData aCoverVariable, ICoverable c) {
@@ -114,7 +110,7 @@ public class GT_Cover_FluidLimiter extends GT_CoverBehaviorBase<GT_Cover_FluidLi
}
/*
- Data
+ * Data
*/
@Override
@@ -128,6 +124,7 @@ public class GT_Cover_FluidLimiter extends GT_CoverBehaviorBase<GT_Cover_FluidLi
}
public static class FluidLimiterData implements ISerializableObject {
+
private float threshold;
public FluidLimiterData(float threshold) {
@@ -199,8 +196,8 @@ public class GT_Cover_FluidLimiter extends GT_CoverBehaviorBase<GT_Cover_FluidLi
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_FluidLimiter.this)
+ builder.widget(
+ new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_FluidLimiter.this)
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
coverData -> String.valueOf(Math.round(coverData.threshold * 100)),
@@ -208,13 +205,11 @@ public class GT_Cover_FluidLimiter extends GT_CoverBehaviorBase<GT_Cover_FluidLi
coverData.threshold = (float) (MathExpression.parseMathExpression(val) / 100);
return coverData;
},
- widget -> widget.setNumbers(0, 100)
- .setFocusOnGuiOpen(true)
- .setPos(startX, startY + spaceY * 2 - 24)
- .setSize(spaceX * 4 - 3, 12)))
- .widget(new TextWidget("Percent threshold")
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX, startY + spaceY * 2 - 35));
+ widget -> widget.setNumbers(0, 100).setFocusOnGuiOpen(true)
+ .setPos(startX, startY + spaceY * 2 - 24).setSize(spaceX * 4 - 3, 12)))
+ .widget(
+ new TextWidget("Percent threshold").setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX, startY + spaceY * 2 - 35));
}
}
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_FluidRegulator.java b/src/main/java/gregtech/common/covers/GT_Cover_FluidRegulator.java
index ad8f5bb2de..df0b16c297 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_FluidRegulator.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_FluidRegulator.java
@@ -1,11 +1,26 @@
package gregtech.common.covers;
+import java.util.concurrent.atomic.AtomicBoolean;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.fluids.IFluidHandler;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.drawable.Text;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.BaseTextFieldWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -18,33 +33,25 @@ import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.concurrent.atomic.AtomicBoolean;
-import javax.annotation.Nonnull;
-import javax.annotation.Nullable;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.fluids.IFluidHandler;
/**
* Cover variable
+ *
* <pre>
* 1111 1111 1111 1111 1111 1111 1111 1111
* |- interval-| |- flow rate 2 compl. -|
* ^ export?
* </pre>
- * Concat export and flow rate 2 compl. together to get actual flow rate.
- * A positive actual flow rate is export, and vice versa.
+ *
+ * Concat export and flow rate 2 compl. together to get actual flow rate. A positive actual flow rate is export, and
+ * vice versa.
* <p>
- * Interval is an unsigned 11 bit integer minus 1, so the range is 1~2048.
- * The stored bits will be flipped bitwise if speed is negative.
- * This way, `0` means 1tick interval, while `-1` means 1 tick interval as well, preserving the legacy behavior.
+ * Interval is an unsigned 11 bit integer minus 1, so the range is 1~2048. The stored bits will be flipped bitwise if
+ * speed is negative. This way, `0` means 1tick interval, while `-1` means 1 tick interval as well, preserving the
+ * legacy behavior.
*/
public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_FluidRegulator.FluidRegulatorData> {
+
private static final int SPEED_LENGTH = 20;
private static final int TICK_RATE_LENGTH = Integer.SIZE - SPEED_LENGTH - 1;
private static final int TICK_RATE_MIN = 1;
@@ -86,19 +93,14 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return aCoverVariable.condition.isRedstoneSensitive();
}
@Override
- protected FluidRegulatorData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- FluidRegulatorData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected FluidRegulatorData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ FluidRegulatorData aCoverVariable, ICoverable aTileEntity, long aTimer) {
if (aCoverVariable.speed == 0 || !aCoverVariable.condition.isAllowedToWork(aSide, aCoverID, aTileEntity)) {
return aCoverVariable;
}
@@ -145,8 +147,7 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
if (tTickRate == 1) {
GT_Utility.sendChatToPlayer(
aPlayer,
- GT_Utility.trans("048", "Pump speed: ")
- + tSpeed
+ GT_Utility.trans("048", "Pump speed: ") + tSpeed
+ GT_Utility.trans("049", "L/tick ")
+ tSpeed * 20
+ GT_Utility.trans("050", "L/sec"));
@@ -162,15 +163,8 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
}
@Override
- public FluidRegulatorData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- FluidRegulatorData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public FluidRegulatorData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) {
adjustSpeed(aPlayer, aCoverVariable, aPlayer.isSneaking() ? 256 : 16);
} else {
@@ -180,15 +174,8 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- FluidRegulatorData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (GT_Utility.getClickedFacingCoords(aSide, aX, aY, aZ)[0] >= 0.5F) {
adjustSpeed(aPlayer, aCoverVariable, 1);
} else {
@@ -198,56 +185,56 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
}
@Override
- public boolean letsRedstoneGoInImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoInImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsEnergyInImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsEnergyInImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsEnergyOutImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsEnergyOutImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsItemsInImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ public boolean letsItemsInImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsItemsOutImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ public boolean letsItemsOutImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsFluidInImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ public boolean letsFluidInImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return allowFluid;
}
@Override
- public boolean letsFluidOutImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ public boolean letsFluidOutImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return allowFluid;
}
@Override
- protected boolean alwaysLookConnectedImpl(
- byte aSide, int aCoverID, FluidRegulatorData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean alwaysLookConnectedImpl(byte aSide, int aCoverID, FluidRegulatorData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -289,69 +276,72 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
protected void addUIWidgets(ModularWindow.Builder builder) {
AtomicBoolean warn = new AtomicBoolean(false);
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_FluidRegulator.this)
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- coverData -> coverData.speed >= 0,
- (coverData, state) -> {
- coverData.speed = Math.abs(coverData.speed);
- return coverData;
- },
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
- .addTooltip(GT_Utility.trans("006", "Export"))
- .setPos(spaceX * 0, spaceY * 0))
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- coverData -> coverData.speed <= 0,
- (coverData, state) -> {
- coverData.speed = -Math.abs(coverData.speed);
- return coverData;
- },
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
- .addTooltip(GT_Utility.trans("007", "Import"))
- .setPos(spaceX * 1, spaceY * 0))
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- coverData -> coverData.condition == Conditional.Always,
- (coverData, state) -> {
- coverData.condition = Conditional.Always;
- return coverData;
- },
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
- .addTooltip(GT_Utility.trans("224", "Always On"))
- .setPos(spaceX * 0, spaceY * 1))
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- coverData -> coverData.condition == Conditional.Conditional,
- (coverData, state) -> {
- coverData.condition = Conditional.Conditional;
- return coverData;
- },
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
- .addTooltip(GT_Utility.trans("225", "Active with Redstone Signal"))
- .setPos(spaceX * 1, spaceY * 1))
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- coverData -> coverData.condition == Conditional.Inverted,
- (coverData, state) -> {
- coverData.condition = Conditional.Inverted;
- return coverData;
- },
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
- .addTooltip(GT_Utility.trans("226", "Inactive with Redstone Signal"))
- .setPos(spaceX * 2, spaceY * 1))
- .addFollower(
- new CoverDataFollower_TextFieldWidget<>(),
- coverData -> String.valueOf(coverData.speed),
- (coverData, state) -> {
- coverData.speed = (int) MathExpression.parseMathExpression(state);
- return coverData;
- },
- widget -> widget.setOnScrollNumbersLong(1, 5, 50)
- .setNumbersLong(val -> {
- final int tickRate =
- getCoverData() != null ? getCoverData().tickRate : 0;
+ builder.widget(
+ new CoverDataControllerWidget<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_FluidRegulator.this)
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ coverData -> coverData.speed >= 0,
+ (coverData, state) -> {
+ coverData.speed = Math.abs(coverData.speed);
+ return coverData;
+ },
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
+ .addTooltip(GT_Utility.trans("006", "Export"))
+ .setPos(spaceX * 0, spaceY * 0))
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ coverData -> coverData.speed <= 0,
+ (coverData, state) -> {
+ coverData.speed = -Math.abs(coverData.speed);
+ return coverData;
+ },
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
+ .addTooltip(GT_Utility.trans("007", "Import"))
+ .setPos(spaceX * 1, spaceY * 0))
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ coverData -> coverData.condition == Conditional.Always,
+ (coverData, state) -> {
+ coverData.condition = Conditional.Always;
+ return coverData;
+ },
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
+ .addTooltip(GT_Utility.trans("224", "Always On"))
+ .setPos(spaceX * 0, spaceY * 1))
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ coverData -> coverData.condition == Conditional.Conditional,
+ (coverData, state) -> {
+ coverData.condition = Conditional.Conditional;
+ return coverData;
+ },
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
+ .addTooltip(GT_Utility.trans("225", "Active with Redstone Signal"))
+ .setPos(spaceX * 1, spaceY * 1))
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ coverData -> coverData.condition == Conditional.Inverted,
+ (coverData, state) -> {
+ coverData.condition = Conditional.Inverted;
+ return coverData;
+ },
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
+ .addTooltip(
+ GT_Utility.trans("226", "Inactive with Redstone Signal"))
+ .setPos(spaceX * 2, spaceY * 1))
+ .addFollower(
+ new CoverDataFollower_TextFieldWidget<>(),
+ coverData -> String.valueOf(coverData.speed),
+ (coverData, state) -> {
+ coverData.speed = (int) MathExpression.parseMathExpression(state);
+ return coverData;
+ },
+ widget -> widget.setOnScrollNumbersLong(1, 5, 50).setNumbersLong(val -> {
+ final int tickRate = getCoverData() != null ? getCoverData().tickRate
+ : 0;
final long maxFlow = (long) mTransferRate
* GT_Utility.clamp(tickRate, TICK_RATE_MIN, TICK_RATE_MAX);
warn.set(false);
@@ -363,20 +353,16 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
warn.set(true);
}
return val;
- })
- .setPattern(BaseTextFieldWidget.WHOLE_NUMS)
- .setFocusOnGuiOpen(true)
- .setPos(spaceX * 0, spaceY * 2 + 2)
- .setSize(spaceX * 4 - 3, 12))
- .addFollower(
- new CoverDataFollower_TextFieldWidget<>(),
- coverData -> String.valueOf(coverData.tickRate),
- (coverData, state) -> {
- coverData.tickRate = (int) MathExpression.parseMathExpression(state);
- return coverData;
- },
- widget -> widget.setOnScrollNumbersLong(1, 5, 50)
- .setNumbersLong(val -> {
+ }).setPattern(BaseTextFieldWidget.WHOLE_NUMS).setFocusOnGuiOpen(true)
+ .setPos(spaceX * 0, spaceY * 2 + 2).setSize(spaceX * 4 - 3, 12))
+ .addFollower(
+ new CoverDataFollower_TextFieldWidget<>(),
+ coverData -> String.valueOf(coverData.tickRate),
+ (coverData, state) -> {
+ coverData.tickRate = (int) MathExpression.parseMathExpression(state);
+ return coverData;
+ },
+ widget -> widget.setOnScrollNumbersLong(1, 5, 50).setNumbersLong(val -> {
final int speed = getCoverData() != null ? getCoverData().speed : 0;
warn.set(false);
if (val > TICK_RATE_MAX) {
@@ -391,52 +377,54 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
val = 1L;
}
return val;
- })
- .setPattern(BaseTextFieldWidget.WHOLE_NUMS)
- .setPos(spaceX * 5, spaceY * 2 + 2)
- .setSize(spaceX * 2 - 3, 12))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("229", "Import/Export"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 4, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("230", "Conditional"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 4, 4 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("208", " L"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 4, 4 + startY + spaceY * 2))
- .widget(new TextWidget(GT_Utility.trans("209", " ticks"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 7, 4 + startY + spaceY * 2))
+ }).setPattern(BaseTextFieldWidget.WHOLE_NUMS)
+ .setPos(spaceX * 5, spaceY * 2 + 2).setSize(spaceX * 2 - 3, 12))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("229", "Import/Export"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 4, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("230", "Conditional"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 4, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("208", " L")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 4, 4 + startY + spaceY * 2))
+ .widget(
+ new TextWidget(GT_Utility.trans("209", " ticks")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 7, 4 + startY + spaceY * 2))
.widget(TextWidget.dynamicText(() -> {
- FluidRegulatorData coverVariable = getCoverData();
- if (coverVariable == null) return new Text("");
- return new Text(String.format(
- GT_Utility.trans("210", "Average: %.2f L/sec"),
- coverVariable.tickRate == 0
- ? 0
- : coverVariable.speed * 20d / coverVariable.tickRate))
- .color(warn.get() ? COLOR_TEXT_WARN.get() : COLOR_TEXT_GRAY.get());
- })
- .setSynced(false)
- .setPos(startX + spaceX * 0, 4 + startY + spaceY * 3));
+ FluidRegulatorData coverVariable = getCoverData();
+ if (coverVariable == null) return new Text("");
+ return new Text(
+ String.format(
+ GT_Utility.trans("210", "Average: %.2f L/sec"),
+ coverVariable.tickRate == 0 ? 0
+ : coverVariable.speed * 20d / coverVariable.tickRate)).color(
+ warn.get() ? COLOR_TEXT_WARN.get() : COLOR_TEXT_GRAY.get());
+ }).setSynced(false).setPos(startX + spaceX * 0, 4 + startY + spaceY * 3));
}
}
public enum Conditional {
+
Always(false) {
+
@Override
boolean isAllowedToWork(byte aSide, int aCoverID, ICoverable aTileEntity) {
return true;
}
},
Conditional(true) {
+
@Override
boolean isAllowedToWork(byte aSide, int aCoverID, ICoverable aTileEntity) {
return !(aTileEntity instanceof IMachineProgress) || ((IMachineProgress) aTileEntity).isAllowedToWork();
}
},
Inverted(true) {
+
@Override
boolean isAllowedToWork(byte aSide, int aCoverID, ICoverable aTileEntity) {
return !(aTileEntity instanceof IMachineProgress)
@@ -459,6 +447,7 @@ public class GT_Cover_FluidRegulator extends GT_CoverBehaviorBase<GT_Cover_Fluid
}
public static class FluidRegulatorData implements ISerializableObject {
+
private int tickRate;
private int speed;
private Conditional condition;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_FluidStorageMonitor.java b/src/main/java/gregtech/common/covers/GT_Cover_FluidStorageMonitor.java
index 8f03f7fff9..184eb8705e 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_FluidStorageMonitor.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_FluidStorageMonitor.java
@@ -16,19 +16,11 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FLUID_STORAGE_MONIT
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FLUID_STORAGE_MONITOR8;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FLUID_STORAGE_MONITOR9;
-import com.google.common.io.ByteArrayDataInput;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.ITextureBuilder;
-import gregtech.api.interfaces.tileentity.ICoverable;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_CoverBehaviorBase;
-import gregtech.api.util.GT_Utility;
-import gregtech.api.util.ISerializableObject;
-import io.netty.buffer.ByteBuf;
import java.util.Optional;
+
import javax.annotation.Nonnull;
import javax.annotation.Nullable;
+
import net.minecraft.client.renderer.texture.TextureMap;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
@@ -45,28 +37,30 @@ import net.minecraftforge.fluids.FluidTankInfo;
import net.minecraftforge.fluids.IFluidContainerItem;
import net.minecraftforge.fluids.IFluidHandler;
+import com.google.common.io.ByteArrayDataInput;
+
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.ITextureBuilder;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_CoverBehaviorBase;
+import gregtech.api.util.GT_Utility;
+import gregtech.api.util.ISerializableObject;
+import io.netty.buffer.ByteBuf;
+
/**
* TODO: Implement overlay rendering only with
* {@link GT_CoverBehaviorBase#getSpecialCoverFGTextureImpl(byte, int, ISerializableObject, ICoverable)}
*/
public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_FluidStorageMonitor.FluidStorageData> {
- private static final IIconContainer[] icons = new IIconContainer[] {
- OVERLAY_FLUID_STORAGE_MONITOR0,
- OVERLAY_FLUID_STORAGE_MONITOR1,
- OVERLAY_FLUID_STORAGE_MONITOR2,
- OVERLAY_FLUID_STORAGE_MONITOR3,
- OVERLAY_FLUID_STORAGE_MONITOR4,
- OVERLAY_FLUID_STORAGE_MONITOR5,
- OVERLAY_FLUID_STORAGE_MONITOR6,
- OVERLAY_FLUID_STORAGE_MONITOR7,
- OVERLAY_FLUID_STORAGE_MONITOR8,
- OVERLAY_FLUID_STORAGE_MONITOR9,
- OVERLAY_FLUID_STORAGE_MONITOR10,
- OVERLAY_FLUID_STORAGE_MONITOR11,
- OVERLAY_FLUID_STORAGE_MONITOR12,
- OVERLAY_FLUID_STORAGE_MONITOR13,
- OVERLAY_FLUID_STORAGE_MONITOR14,
- };
+
+ private static final IIconContainer[] icons = new IIconContainer[] { OVERLAY_FLUID_STORAGE_MONITOR0,
+ OVERLAY_FLUID_STORAGE_MONITOR1, OVERLAY_FLUID_STORAGE_MONITOR2, OVERLAY_FLUID_STORAGE_MONITOR3,
+ OVERLAY_FLUID_STORAGE_MONITOR4, OVERLAY_FLUID_STORAGE_MONITOR5, OVERLAY_FLUID_STORAGE_MONITOR6,
+ OVERLAY_FLUID_STORAGE_MONITOR7, OVERLAY_FLUID_STORAGE_MONITOR8, OVERLAY_FLUID_STORAGE_MONITOR9,
+ OVERLAY_FLUID_STORAGE_MONITOR10, OVERLAY_FLUID_STORAGE_MONITOR11, OVERLAY_FLUID_STORAGE_MONITOR12,
+ OVERLAY_FLUID_STORAGE_MONITOR13, OVERLAY_FLUID_STORAGE_MONITOR14, };
public GT_Cover_FluidStorageMonitor() {
super(FluidStorageData.class);
@@ -83,13 +77,8 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
}
@Override
- protected FluidStorageData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- FluidStorageData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected FluidStorageData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ FluidStorageData aCoverVariable, ICoverable aTileEntity, long aTimer) {
final FluidTankInfo[] tanks = getValidFluidTankInfos(aTileEntity, aCoverVariable.side);
if (tanks == null) {
return aCoverVariable.disable().issueCoverUpdateIfNeeded(aTileEntity, aSide);
@@ -105,25 +94,24 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
return aCoverVariable.setNullTank().issueCoverUpdateIfNeeded(aTileEntity, aSide);
}
- return aCoverVariable
- .setFluid(tank.fluid)
- .setScale(getTankScale(tank))
+ return aCoverVariable.setFluid(tank.fluid).setScale(getTankScale(tank))
.issueCoverUpdateIfNeeded(aTileEntity, aSide);
}
@Override
- protected ITexture getSpecialCoverFGTextureImpl(
- byte aSide, int aCoverID, FluidStorageData aCoverVariable, ICoverable aTileEntity) {
+ protected ITexture getSpecialCoverFGTextureImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable,
+ ICoverable aTileEntity) {
return getSpecialCoverTextureImpl(aSide, aCoverID, aCoverVariable, aTileEntity);
}
@Override
- protected ITexture getSpecialCoverTextureImpl(
- byte aSide, int aCoverID, FluidStorageData aCoverVariable, ICoverable aTileEntity) {
+ protected ITexture getSpecialCoverTextureImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable,
+ ICoverable aTileEntity) {
if (aCoverVariable.slot == -1 || aCoverVariable.fluid == null || aCoverVariable.scale == 0) {
return TextureFactory.of(OVERLAY_FLUID_STORAGE_MONITOR0);
}
final IIconContainer fluidIcon = new IIconContainer() {
+
@Override
public IIcon getIcon() {
return aCoverVariable.fluid.getStillIcon();
@@ -141,22 +129,14 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
};
final short[] fluidRGBA = colorToRGBA(aCoverVariable.fluid.getColor());
- final ITextureBuilder fluidTextureBuilder =
- TextureFactory.builder().addIcon(fluidIcon).setRGBA(fluidRGBA);
+ final ITextureBuilder fluidTextureBuilder = TextureFactory.builder().addIcon(fluidIcon).setRGBA(fluidRGBA);
if (aCoverVariable.fluid.getLuminosity() > 0) fluidTextureBuilder.glow();
return TextureFactory.of(fluidTextureBuilder.build(), TextureFactory.of(icons[aCoverVariable.scale]));
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- FluidStorageData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (aPlayer == null || aPlayer.worldObj == null || aPlayer.worldObj.isRemote) {
return false;
}
@@ -196,8 +176,8 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
return false;
}
- protected static ItemStack fillToTank(
- @Nonnull ItemStack container, @Nonnull IFluidHandler tank, ForgeDirection side) {
+ protected static ItemStack fillToTank(@Nonnull ItemStack container, @Nonnull IFluidHandler tank,
+ ForgeDirection side) {
final FluidStack fluidToFill = GT_Utility.getFluidForFilledItem(container, true);
if (fluidToFill == null || fluidToFill.getFluid() == null || fluidToFill.amount <= 0) {
return null;
@@ -224,11 +204,8 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
}
}
- protected static ItemStack fillToContainer(
- @Nonnull ItemStack container,
- @Nonnull FluidTankInfo tankInfo,
- @Nonnull IFluidHandler tank,
- ForgeDirection side) {
+ protected static ItemStack fillToContainer(@Nonnull ItemStack container, @Nonnull FluidTankInfo tankInfo,
+ @Nonnull IFluidHandler tank, ForgeDirection side) {
if (tankInfo.fluid == null || tankInfo.fluid.getFluid() == null || tankInfo.fluid.amount <= 0) {
return null;
}
@@ -239,13 +216,12 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
if (container.getItem() instanceof IFluidContainerItem) {
final IFluidContainerItem containerItem = (IFluidContainerItem) container.getItem();
final int filled = Math.min(
- Optional.ofNullable(tank.drain(
+ Optional.ofNullable(
+ tank.drain(
side,
new FluidStack(tankInfo.fluid.getFluid(), containerItem.getCapacity(container)),
false))
- .filter(fs -> GT_Utility.areFluidsEqual(fs, tankInfo.fluid))
- .map(fs -> fs.amount)
- .orElse(0),
+ .filter(fs -> GT_Utility.areFluidsEqual(fs, tankInfo.fluid)).map(fs -> fs.amount).orElse(0),
containerItem.fill(
container,
new FluidStack(tankInfo.fluid.getFluid(), containerItem.getCapacity(container)),
@@ -266,9 +242,7 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
return null;
}
if (Optional.ofNullable(tank.drain(side, filledFluid, false))
- .filter(fs -> GT_Utility.areFluidsEqual(fs, filledFluid))
- .map(fs -> fs.amount)
- .orElse(0)
+ .filter(fs -> GT_Utility.areFluidsEqual(fs, filledFluid)).map(fs -> fs.amount).orElse(0)
!= filledFluid.amount) {
return null;
}
@@ -277,28 +251,19 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
}
}
- protected static void replaceHeldItemStack(
- @Nonnull EntityPlayer player, @Nonnull ItemStack heldItem, @Nonnull ItemStack result) {
+ protected static void replaceHeldItemStack(@Nonnull EntityPlayer player, @Nonnull ItemStack heldItem,
+ @Nonnull ItemStack result) {
heldItem.stackSize--;
GT_Utility.addItemToPlayerInventory(player, result);
player.inventoryContainer.detectAndSendChanges();
}
@Override
- protected FluidStorageData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- FluidStorageData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected FluidStorageData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (aPlayer.isSneaking()) {
- aCoverVariable
- .setSide(
- ForgeDirection.values()[
- (aCoverVariable.side.ordinal() + 1) % ForgeDirection.values().length])
+ aCoverVariable.setSide(
+ ForgeDirection.values()[(aCoverVariable.side.ordinal() + 1) % ForgeDirection.values().length])
.setSlot(0);
GT_Utility.sendChatToPlayer(aPlayer, GT_Utility.trans("SIDE", "Side: ") + aCoverVariable.side.name());
return aCoverVariable;
@@ -311,28 +276,28 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
if (aCoverVariable.slot < 0 || tanks.length <= aCoverVariable.slot) {
aCoverVariable.setSlot(0);
} else {
- aCoverVariable.setSlot(
- (aCoverVariable.slot + tanks.length + (aPlayer.isSneaking() ? -1 : 1)) % tanks.length);
+ aCoverVariable
+ .setSlot((aCoverVariable.slot + tanks.length + (aPlayer.isSneaking() ? -1 : 1)) % tanks.length);
}
GT_Utility.sendChatToPlayer(aPlayer, GT_Utility.trans("053", "Slot: ") + aCoverVariable.slot);
return aCoverVariable;
}
@Override
- protected boolean isDataNeededOnClientImpl(
- byte aSide, int aCoverID, FluidStorageData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean isDataNeededOnClientImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, FluidStorageData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, FluidStorageData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, FluidStorageData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@@ -341,8 +306,8 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
return 10;
}
- protected static FluidTankInfo[] getValidFluidTankInfos(
- @Nullable ICoverable tileEntity, @Nonnull ForgeDirection side) {
+ protected static FluidTankInfo[] getValidFluidTankInfos(@Nullable ICoverable tileEntity,
+ @Nonnull ForgeDirection side) {
if (tileEntity instanceof IFluidHandler) {
final FluidTankInfo[] tanks = ((IFluidHandler) tileEntity).getTankInfo(side);
if (tanks != null && 0 < tanks.length) {
@@ -360,12 +325,12 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
}
protected short[] colorToRGBA(int color) {
- return new short[] {
- (short) (color >> 16 & 0xFF), (short) (color >> 8 & 0xFF), (short) (color & 0xFF), (short) (0xFF)
- };
+ return new short[] { (short) (color >> 16 & 0xFF), (short) (color >> 8 & 0xFF), (short) (color & 0xFF),
+ (short) (0xFF) };
}
public static class FluidStorageData implements ISerializableObject {
+
private ForgeDirection side;
private int slot;
private Fluid fluid;
@@ -390,8 +355,7 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
}
/**
- * @param slot
- * 0-based index of the tank, -1 for no correct FluidTankInfo[] for the current side.
+ * @param slot 0-based index of the tank, -1 for no correct FluidTankInfo[] for the current side.
*/
public FluidStorageData setSlot(int slot) {
if (this.slot != slot) {
@@ -497,6 +461,7 @@ public class GT_Cover_FluidStorageMonitor extends GT_CoverBehaviorBase<GT_Cover_
}
protected static class Util {
+
public static int getFluidID(@Nullable Fluid fluid) {
return fluid == null ? -1 : fluid.getID();
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Fluidfilter.java b/src/main/java/gregtech/common/covers/GT_Cover_Fluidfilter.java
index 54872f849a..09239c0a07 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Fluidfilter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Fluidfilter.java
@@ -2,11 +2,24 @@ package gregtech.common.covers;
import static gregtech.api.enums.GT_Values.E;
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.Constants.NBT;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.ModularUITextures;
import com.gtnewhorizons.modularui.api.forge.ItemStackHandler;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -18,28 +31,18 @@ import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_SlotWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.Constants.NBT;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfilter.FluidFilterData> {
// Uses the lower 3 bits of the cover variable, so we have 8 options to work with (0-7)
- private final int FILTER_INPUT_DENY_OUTPUT = 0; // 000
- private final int INVERT_INPUT_DENY_OUTPUT = 1; // 001
- private final int FILTER_INPUT_ANY_OUTPUT = 2; // 010
- private final int INVERT_INPUT_ANY_OUTPUT = 3; // 011
- private final int DENY_INPUT_FILTER_OUTPUT = 4; // 100
- private final int DENY_INPUT_INVERT_OUTPUT = 5; // 101
- private final int ANY_INPUT_FILTER_OUTPUT = 6; // 110
- private final int ANY_INPUT_INVERT_OUTPUT = 7; // 111
+ private final int FILTER_INPUT_DENY_OUTPUT = 0; // 000
+ private final int INVERT_INPUT_DENY_OUTPUT = 1; // 001
+ private final int FILTER_INPUT_ANY_OUTPUT = 2; // 010
+ private final int INVERT_INPUT_ANY_OUTPUT = 3; // 011
+ private final int DENY_INPUT_FILTER_OUTPUT = 4; // 100
+ private final int DENY_INPUT_INVERT_OUTPUT = 5; // 101
+ private final int ANY_INPUT_FILTER_OUTPUT = 6; // 110
+ private final int ANY_INPUT_INVERT_OUTPUT = 7; // 111
/**
* @deprecated use {@link #GT_Cover_Fluidfilter(ITexture coverTexture)} instead
@@ -64,30 +67,27 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
@Override
- protected String getDescriptionImpl(
- byte aSide, int aCoverID, FluidFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected String getDescriptionImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable,
+ ICoverable aTileEntity) {
final Fluid fluid = FluidRegistry.getFluid(aCoverVariable.mFluidID);
if (fluid == null) return E;
final FluidStack sFluid = new FluidStack(fluid, 1000);
return (String.format(
- "Filtering Fluid: %s - %s", sFluid.getLocalizedName(), getFilterMode(aCoverVariable.mFilterMode)));
+ "Filtering Fluid: %s - %s",
+ sFluid.getLocalizedName(),
+ getFilterMode(aCoverVariable.mFilterMode)));
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, FluidFilterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return false;
}
@Override
- protected FluidFilterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- FluidFilterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected FluidFilterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ FluidFilterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
return aCoverVariable;
}
@@ -115,15 +115,8 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
@Override
- protected FluidFilterData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- FluidFilterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected FluidFilterData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable.mFilterMode = (aCoverVariable.mFilterMode + (aPlayer.isSneaking() ? -1 : 1)) % 8;
if (aCoverVariable.mFilterMode < 0) {
aCoverVariable.mFilterMode = 7;
@@ -135,17 +128,9 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- FluidFilterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
- if (((aX > 0.375D) && (aX < 0.625D))
- || ((aSide > 3) && ((aY > 0.375D) && (aY < 0.625D)))
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ if (((aX > 0.375D) && (aX < 0.625D)) || ((aSide > 3) && ((aY > 0.375D) && (aY < 0.625D)))
|| ((aSide < 2) && ((aZ > 0.375D) && (aZ < 0.625D)))
|| (aSide == 2)
|| (aSide == 3)) {
@@ -159,7 +144,8 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
aTileEntity.setCoverDataAtSide(aSide, aCoverVariable);
FluidStack sFluid = new FluidStack(FluidRegistry.getFluid(aFluid), 1000);
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("047", "Filter Fluid: ") + sFluid.getLocalizedName());
+ aPlayer,
+ GT_Utility.trans("047", "Filter Fluid: ") + sFluid.getLocalizedName());
}
return true;
}
@@ -167,52 +153,44 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
@Override
- protected boolean letsRedstoneGoInImpl(
- byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsRedstoneGoInImpl(byte aSide, int aCoverID,
+ GT_Cover_Fluidfilter.FluidFilterData aCoverVariable, ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID,
+ GT_Cover_Fluidfilter.FluidFilterData aCoverVariable, ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsEnergyInImpl(
- byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyInImpl(byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsEnergyOutImpl(
- byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyOutImpl(byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsItemsInImpl(
- byte aSide,
- int aCoverID,
- GT_Cover_Fluidfilter.FluidFilterData aCoverVariable,
- int aSlot,
- ICoverable aTileEntity) {
+ public boolean letsItemsInImpl(byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable,
+ int aSlot, ICoverable aTileEntity) {
return true;
}
@Override
- public boolean letsItemsOutImpl(
- byte aSide,
- int aCoverID,
- GT_Cover_Fluidfilter.FluidFilterData aCoverVariable,
- int aSlot,
- ICoverable aTileEntity) {
+ public boolean letsItemsOutImpl(byte aSide, int aCoverID, GT_Cover_Fluidfilter.FluidFilterData aCoverVariable,
+ int aSlot, ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, FluidFilterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
if (aFluid == null) return true;
int aFilterMode = aCoverVariable.mFilterMode;
@@ -226,8 +204,8 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, FluidFilterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
if (aFluid == null) return true;
int aFilterMode = aCoverVariable.mFilterMode;
@@ -241,8 +219,8 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
@Override
- protected boolean alwaysLookConnectedImpl(
- byte aSide, int aCoverID, FluidFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean alwaysLookConnectedImpl(byte aSide, int aCoverID, FluidFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -282,101 +260,106 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_Fluidfilter.this,
- (id, coverData) -> !getClickable(id, coverData),
- (id, coverData) -> {
- coverData.mFilterMode = getNewFilterMode(id, coverData);
- return coverData;
- })
- .addToggleButton(
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_Fluidfilter.this,
+ (id, coverData) -> !getClickable(id, coverData),
+ (id, coverData) -> {
+ coverData.mFilterMode = getNewFilterMode(id, coverData);
+ return coverData;
+ }).addToggleButton(
0,
CoverDataFollower_ToggleButtonWidget.ofDisableable(),
widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
.addTooltip(GT_Utility.trans("232", "Filter Input"))
.setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
- .addTooltip(GT_Utility.trans("233", "Filter Output"))
- .setPos(spaceX * 1, spaceY * 0))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLOCK_INPUT)
- .addTooltip(GT_Utility.trans("234", "Block Output"))
- .setPos(spaceX * 0, spaceY * 2))
- .addToggleButton(
- 3,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ALLOW_INPUT)
- .addTooltip(GT_Utility.trans("235", "Allow Output"))
- .setPos(spaceX * 1, spaceY * 2))
- .addToggleButton(
- 4,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_WHITELIST)
- .addTooltip(GT_Utility.trans("236", "Whitelist Fluid"))
- .setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 5,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLACKLIST)
- .addTooltip(GT_Utility.trans("237", "Blacklist Fluid"))
- .setPos(spaceX * 1, spaceY * 1))
- .addFollower(
- new CoverDataFollower_SlotWidget<FluidFilterData>(new ItemStackHandler(), 0, true) {
- @Override
- protected void putClickedStack(ItemStack stack, int mouseButton) {
- if (stack != null
- && GT_Utility.getFluidFromContainerOrFluidDisplay(stack) == null)
- return;
- super.putClickedStack(
- GT_Utility.getFluidDisplayStack(
- GT_Utility.getFluidFromContainerOrFluidDisplay(stack),
- false),
- mouseButton);
- }
- },
- this::getFluidDisplayItem,
- (coverData, stack) -> {
- if (stack == null) {
- coverData.mFluidID = -1;
- } else {
- FluidStack fluid = GT_Utility.getFluidFromDisplayStack(stack);
- if (fluid != null && fluid.getFluid() != null) {
- coverData.mFluidID =
- fluid.getFluid().getID();
- }
- }
- return coverData;
- },
- widget -> widget.setBackground(ModularUITextures.FLUID_SLOT)
- .setPos(0, spaceY * 3 + 2))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("238", "Filter Direction"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 2, 3 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("239", "Filter Type"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 2, 3 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("240", "Block Flow"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 2, 3 + startY + spaceY * 2))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
+ .addTooltip(GT_Utility.trans("233", "Filter Output"))
+ .setPos(spaceX * 1, spaceY * 0))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLOCK_INPUT)
+ .addTooltip(GT_Utility.trans("234", "Block Output"))
+ .setPos(spaceX * 0, spaceY * 2))
+ .addToggleButton(
+ 3,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ALLOW_INPUT)
+ .addTooltip(GT_Utility.trans("235", "Allow Output"))
+ .setPos(spaceX * 1, spaceY * 2))
+ .addToggleButton(
+ 4,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_WHITELIST)
+ .addTooltip(GT_Utility.trans("236", "Whitelist Fluid"))
+ .setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 5,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLACKLIST)
+ .addTooltip(GT_Utility.trans("237", "Blacklist Fluid"))
+ .setPos(spaceX * 1, spaceY * 1))
+ .addFollower(
+ new CoverDataFollower_SlotWidget<FluidFilterData>(
+ new ItemStackHandler(),
+ 0,
+ true) {
+
+ @Override
+ protected void putClickedStack(ItemStack stack, int mouseButton) {
+ if (stack != null
+ && GT_Utility.getFluidFromContainerOrFluidDisplay(stack)
+ == null)
+ return;
+ super.putClickedStack(
+ GT_Utility.getFluidDisplayStack(
+ GT_Utility
+ .getFluidFromContainerOrFluidDisplay(stack),
+ false),
+ mouseButton);
+ }
+ },
+ this::getFluidDisplayItem,
+ (coverData, stack) -> {
+ if (stack == null) {
+ coverData.mFluidID = -1;
+ } else {
+ FluidStack fluid = GT_Utility.getFluidFromDisplayStack(stack);
+ if (fluid != null && fluid.getFluid() != null) {
+ coverData.mFluidID = fluid.getFluid().getID();
+ }
+ }
+ return coverData;
+ },
+ widget -> widget.setBackground(ModularUITextures.FLUID_SLOT)
+ .setPos(0, spaceY * 3 + 2))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("238", "Filter Direction"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 2, 3 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("239", "Filter Type"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 2, 3 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("240", "Block Flow")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 2, 3 + startY + spaceY * 2))
.widget(TextWidget.dynamicString(() -> {
- if (getCoverData() != null) {
- ItemStack fluidDisplay = getFluidDisplayItem(getCoverData());
- if (fluidDisplay != null) {
- return fluidDisplay.getDisplayName();
- }
- }
- return GT_Utility.trans("315", "Filter Empty");
- })
- .setSynced(false)
- .setDefaultColor(COLOR_TITLE.get())
+ if (getCoverData() != null) {
+ ItemStack fluidDisplay = getFluidDisplayItem(getCoverData());
+ if (fluidDisplay != null) {
+ return fluidDisplay.getDisplayName();
+ }
+ }
+ return GT_Utility.trans("315", "Filter Empty");
+ }).setSynced(false).setDefaultColor(COLOR_TITLE.get())
.setPos(startX + spaceX + 3, 4 + startY + spaceY * 3));
}
@@ -420,6 +403,7 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
}
public static class FluidFilterData implements ISerializableObject {
+
private int mFluidID;
private int mFilterMode;
@@ -439,8 +423,7 @@ public class GT_Cover_Fluidfilter extends GT_CoverBehaviorBase<GT_Cover_Fluidfil
public NBTBase saveDataToNBT() {
NBTTagCompound tNBT = new NBTTagCompound();
tNBT.setInteger("mFilterMode", mFilterMode);
- if (mFluidID >= 0)
- tNBT.setString("mFluid", FluidRegistry.getFluid(mFluidID).getName());
+ if (mFluidID >= 0) tNBT.setString("mFluid", FluidRegistry.getFluid(mFluidID).getName());
return tNBT;
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_ItemFilter.java b/src/main/java/gregtech/common/covers/GT_Cover_ItemFilter.java
index 1580ac6ce5..a1378c9812 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_ItemFilter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_ItemFilter.java
@@ -3,10 +3,25 @@ package gregtech.common.covers;
import static gregtech.api.util.GT_Utility.intToStack;
import static gregtech.api.util.GT_Utility.moveMultipleItemStacks;
+import java.util.Collections;
+import java.util.List;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraftforge.common.util.Constants;
+import net.minecraftforge.fluids.Fluid;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.forge.ItemStackHandler;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import cpw.mods.fml.common.network.ByteBufUtils;
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
@@ -19,17 +34,6 @@ import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_SlotWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.Collections;
-import java.util.List;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.common.util.Constants;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilter.ItemFilterData> {
@@ -59,19 +63,14 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return false;
}
@Override
- protected ItemFilterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- ItemFilterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected ItemFilterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ ItemFilterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
TileEntity tTileEntity = aTileEntity.getTileEntityAtSide(aSide);
Object fromEntity = mExport ? aTileEntity : tTileEntity, toEntity = !mExport ? aTileEntity : tTileEntity;
byte fromSide = !mExport ? GT_Utility.getOppositeSide(aSide) : aSide,
@@ -96,15 +95,8 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- ItemFilterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
ItemStack tStack = aPlayer.inventory.getCurrentItem();
if (tStack != null) {
aCoverVariable.mFilter = tStack;
@@ -117,75 +109,67 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
}
@Override
- protected ItemFilterData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- ItemFilterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected ItemFilterData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable.mWhitelist = !aCoverVariable.mWhitelist;
GT_Utility.sendChatToPlayer(
aPlayer,
- aCoverVariable.mWhitelist
- ? GT_Utility.trans("125.1", "Whitelist Mode")
+ aCoverVariable.mWhitelist ? GT_Utility.trans("125.1", "Whitelist Mode")
: GT_Utility.trans("124.1", "Blacklist Mode"));
return aCoverVariable;
}
@Override
- protected boolean letsRedstoneGoInImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsRedstoneGoInImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsEnergyInImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyInImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsEnergyOutImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyOutImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return false;
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return false;
}
@Override
- protected boolean letsItemsInImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsInImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsOutImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsOutImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean alwaysLookConnectedImpl(
- byte aSide, int aCoverID, ItemFilterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean alwaysLookConnectedImpl(byte aSide, int aCoverID, ItemFilterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -229,8 +213,8 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
if (getCoverData() != null) {
filterInvHandler.setStackInSlot(0, setStackSize1(getCoverData().mFilter));
}
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_ItemFilter.this)
+ builder.widget(
+ new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_ItemFilter.this)
.addFollower(
new CoverDataFollower_ToggleButtonWidget<>(),
coverData -> coverData.mWhitelist,
@@ -238,7 +222,8 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
coverData.mWhitelist = state;
return coverData;
},
- widget -> widget.setToggleTexture(
+ widget -> widget
+ .setToggleTexture(
GT_UITextures.OVERLAY_BUTTON_WHITELIST,
GT_UITextures.OVERLAY_BUTTON_BLACKLIST)
.addTooltip(0, GT_Utility.trans("124.1", "Blacklist Mode"))
@@ -254,12 +239,12 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
widget -> widget.setBackground(GT_UITextures.SLOT_DARK_GRAY)
.setPos(spaceX * 0, spaceY * 2))
.setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("317", "Filter: "))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 0, 3 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("318", "Check Mode"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 2, 3 + startY + spaceY * 0));
+ .widget(
+ new TextWidget(GT_Utility.trans("317", "Filter: ")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 0, 3 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("318", "Check Mode")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 2, 3 + startY + spaceY * 0));
}
private ItemStack setStackSize1(ItemStack stack) {
@@ -271,6 +256,7 @@ public class GT_Cover_ItemFilter extends GT_CoverBehaviorBase<GT_Cover_ItemFilte
}
public static class ItemFilterData implements ISerializableObject {
+
private boolean mWhitelist;
private ItemStack mFilter;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_ItemMeter.java b/src/main/java/gregtech/common/covers/GT_Cover_ItemMeter.java
index 6724e36975..14607cdf09 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_ItemMeter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_ItemMeter.java
@@ -1,11 +1,22 @@
package gregtech.common.covers;
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraftforge.fluids.Fluid;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.BaseTextFieldWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
+
import gregtech.api.GregTech_API;
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
@@ -22,14 +33,6 @@ import gregtech.common.gui.modularui.widget.ItemWatcherSlotWidget;
import gregtech.common.tileentities.machines.GT_MetaTileEntity_Hatch_OutputBus_ME;
import gregtech.common.tileentities.storage.GT_MetaTileEntity_DigitalChestBase;
import io.netty.buffer.ByteBuf;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.ItemMeterData> {
@@ -53,10 +56,9 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
@Override
public ItemMeterData createDataObject(int aLegacyData) {
// Convert from ver. 5.09.33.50
- if ((CONVERTED_BIT & aLegacyData) == 0)
- if (aLegacyData == 0) aLegacyData = CONVERTED_BIT;
- else if (aLegacyData == 1) aLegacyData = CONVERTED_BIT | INVERT_BIT;
- else if (aLegacyData > 1) aLegacyData = CONVERTED_BIT | Math.min((aLegacyData - 2), SLOT_MASK);
+ if ((CONVERTED_BIT & aLegacyData) == 0) if (aLegacyData == 0) aLegacyData = CONVERTED_BIT;
+ else if (aLegacyData == 1) aLegacyData = CONVERTED_BIT | INVERT_BIT;
+ else if (aLegacyData > 1) aLegacyData = CONVERTED_BIT | Math.min((aLegacyData - 2), SLOT_MASK);
boolean invert = (aLegacyData & INVERT_BIT) == INVERT_BIT;
int slot = (aLegacyData & SLOT_MASK) - 1;
@@ -70,13 +72,13 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return false;
}
- public static byte computeSignalBasedOnItems(
- ICoverable tileEntity, boolean inverted, int threshold, int slot, int side) {
+ public static byte computeSignalBasedOnItems(ICoverable tileEntity, boolean inverted, int threshold, int slot,
+ int side) {
long max = 0;
long used = 0;
IMetaTileEntity mte = ((IGregTechTileEntity) tileEntity).getMetaTileEntity();
@@ -90,7 +92,7 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
used = 64;
}
} else {
- int[] slots = slot >= 0 ? new int[] {slot} : tileEntity.getAccessibleSlotsFromSide(side);
+ int[] slots = slot >= 0 ? new int[] { slot } : tileEntity.getAccessibleSlotsFromSide(side);
for (int i : slots) {
if (i >= 0 && i < tileEntity.getSizeInventory()) {
@@ -105,30 +107,22 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
}
@Override
- protected ItemMeterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- ItemMeterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected ItemMeterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ ItemMeterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
byte signal = computeSignalBasedOnItems(
- aTileEntity, aCoverVariable.inverted, aCoverVariable.threshold, aCoverVariable.slot, aSide);
+ aTileEntity,
+ aCoverVariable.inverted,
+ aCoverVariable.threshold,
+ aCoverVariable.slot,
+ aSide);
aTileEntity.setOutputRedstoneSignal(aSide, signal);
return aCoverVariable;
}
@Override
- protected ItemMeterData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- ItemMeterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected ItemMeterData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (aPlayer.isSneaking()) {
if (aCoverVariable.inverted) {
aCoverVariable.inverted = false;
@@ -141,9 +135,8 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
aCoverVariable.slot++;
if (aCoverVariable.slot > aTileEntity.getSizeInventory()) aCoverVariable.slot = -1;
- if (aCoverVariable.slot == -1)
- GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("053", "Slot: ") + GT_Utility.trans("ALL", "All"));
+ if (aCoverVariable.slot == -1) GT_Utility
+ .sendChatToPlayer(aPlayer, GT_Utility.trans("053", "Slot: ") + GT_Utility.trans("ALL", "All"));
else GT_Utility.sendChatToPlayer(aPlayer, GT_Utility.trans("053", "Slot: ") + aCoverVariable.slot);
}
@@ -156,38 +149,38 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
}
@Override
- protected boolean letsEnergyOutImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyOutImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsInImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsInImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsOutImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsOutImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, ItemMeterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, ItemMeterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -234,8 +227,8 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
maxSlot = getMaxSlot();
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_ItemMeter.this)
+ builder.widget(
+ new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_ItemMeter.this)
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofRedstone(),
coverData -> coverData.inverted,
@@ -243,9 +236,7 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
coverData.inverted = state;
return coverData;
},
- widget -> widget.addTooltip(0, NORMAL)
- .addTooltip(1, INVERTED)
- .setPos(0, 0))
+ widget -> widget.addTooltip(0, NORMAL).addTooltip(1, INVERTED).setPos(0, 0))
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
coverData -> getSlotTextFieldContent(coverData.slot),
@@ -253,19 +244,15 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
coverData.slot = getIntFromText(state);
return coverData;
},
- widget -> widget.setOnScrollText()
- .setValidator(val -> {
- final int valSlot = getIntFromText(val);
- if (valSlot > -1) {
- return TextFieldWidget.format.format(Math.min(valSlot, maxSlot));
- } else {
- return ALL_TEXT;
- }
- })
- .setPattern(BaseTextFieldWidget.NATURAL_NUMS)
- .setFocusOnGuiOpen(true)
- .setPos(0, spaceY + 2)
- .setSize(spaceX * 2 + 5, 12))
+ widget -> widget.setOnScrollText().setValidator(val -> {
+ final int valSlot = getIntFromText(val);
+ if (valSlot > -1) {
+ return TextFieldWidget.format.format(Math.min(valSlot, maxSlot));
+ } else {
+ return ALL_TEXT;
+ }
+ }).setPattern(BaseTextFieldWidget.NATURAL_NUMS).setFocusOnGuiOpen(true)
+ .setPos(0, spaceY + 2).setSize(spaceX * 2 + 5, 12))
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
coverData -> String.valueOf(coverData.threshold),
@@ -273,34 +260,35 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
coverData.threshold = (int) MathExpression.parseMathExpression(state);
return coverData;
},
- widget -> widget.setOnScrollNumbers(1, 10, 64)
- .setNumbers(0, getUpperBound())
- .setPos(0, spaceY * 2 + 2)
- .setSize(spaceX * 2 + 5, 12))
+ widget -> widget.setOnScrollNumbers(1, 10, 64).setNumbers(0, getUpperBound())
+ .setPos(0, spaceY * 2 + 2).setSize(spaceX * 2 + 5, 12))
.setPos(startX, startY))
- .widget(new ItemWatcherSlotWidget()
- .setGetter(this::getTargetItem)
- .setPos(startX + spaceX * 8 - 4, startY + spaceY))
- .widget(TextWidget.dynamicString(
+ .widget(
+ new ItemWatcherSlotWidget().setGetter(
+ this::getTargetItem).setPos(
+ startX + spaceX * 8 - 4,
+ startY + spaceY))
+ .widget(
+ TextWidget.dynamicString(
() -> getCoverData() != null ? getCoverData().inverted ? INVERTED : NORMAL : "")
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY))
- .widget(new TextWidget(GT_Utility.trans("254", "Detect slot#"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 4 + startY + spaceY))
- .widget(new TextWidget(GT_Utility.trans("221", "Item threshold"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, startY + spaceY * 2 + 4));
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("254", "Detect slot#"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 4 + startY + spaceY))
+ .widget(
+ new TextWidget(GT_Utility.trans("221", "Item threshold"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, startY + spaceY * 2 + 4));
}
private int getMaxSlot() {
final ICoverable tile = getUIBuildContext().getTile();
- if (tile instanceof TileEntity
- && !tile.isDead()
+ if (tile instanceof TileEntity && !tile.isDead()
&& tile instanceof IGregTechTileEntity
- && !(((IGregTechTileEntity) tile).getMetaTileEntity()
- instanceof GT_MetaTileEntity_DigitalChestBase))
+ && !(((IGregTechTileEntity) tile)
+ .getMetaTileEntity() instanceof GT_MetaTileEntity_DigitalChestBase))
return Math.min(tile.getSizeInventory() - 1, SLOT_MASK - 1);
else return -1;
}
@@ -337,6 +325,7 @@ public class GT_Cover_ItemMeter extends GT_CoverBehaviorBase<GT_Cover_ItemMeter.
}
public static class ItemMeterData implements ISerializableObject {
+
private boolean inverted;
/** The special value {@code -1} means all slots. */
private int slot;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Lens.java b/src/main/java/gregtech/common/covers/GT_Cover_Lens.java
index b8675bf1c2..1171a4717f 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Lens.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Lens.java
@@ -5,6 +5,7 @@ import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.GT_CoverBehavior;
public class GT_Cover_Lens extends GT_CoverBehavior {
+
private final byte mColor;
/**
@@ -21,8 +22,8 @@ public class GT_Cover_Lens extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java b/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java
index 62e560487b..4a3b96a769 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_LiquidMeter.java
@@ -1,9 +1,24 @@
package gregtech.common.covers;
+import java.util.Arrays;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.fluids.FluidTankInfo;
+import net.minecraftforge.fluids.IFluidHandler;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -16,17 +31,6 @@ import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import gregtech.common.tileentities.storage.GT_MetaTileEntity_DigitalTankBase;
import io.netty.buffer.ByteBuf;
-import java.util.Arrays;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.fluids.FluidTankInfo;
-import net.minecraftforge.fluids.IFluidHandler;
/**
* TODO: Implement overlay rendering only with
@@ -49,8 +53,8 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return false;
}
@@ -62,12 +66,10 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
if (tanks != null) {
for (FluidTankInfo tank : tanks) {
if (tank != null) {
- if (tileEntity instanceof BaseMetaTileEntity
- && ((BaseMetaTileEntity) tileEntity).getMetaTileEntity()
- instanceof GT_MetaTileEntity_DigitalTankBase) {
- max += ((GT_MetaTileEntity_DigitalTankBase)
- ((BaseMetaTileEntity) tileEntity).getMetaTileEntity())
- .getRealCapacity();
+ if (tileEntity instanceof BaseMetaTileEntity && ((BaseMetaTileEntity) tileEntity)
+ .getMetaTileEntity() instanceof GT_MetaTileEntity_DigitalTankBase) {
+ max += ((GT_MetaTileEntity_DigitalTankBase) ((BaseMetaTileEntity) tileEntity)
+ .getMetaTileEntity()).getRealCapacity();
} else max += tank.capacity;
FluidStack tLiquid = tank.fluid;
if (tLiquid != null) {
@@ -84,13 +86,8 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
}
@Override
- protected LiquidMeterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- LiquidMeterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected LiquidMeterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ LiquidMeterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
byte signal = computeSignalBasedOnFluid(aTileEntity, aCoverVariable.inverted, aCoverVariable.threshold);
aTileEntity.setOutputRedstoneSignal(aSide, signal);
@@ -98,15 +95,8 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
}
@Override
- protected LiquidMeterData onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- LiquidMeterData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected LiquidMeterData onCoverScrewdriverClickImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable,
+ ICoverable aTileEntity, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (aCoverVariable.inverted) {
aCoverVariable.inverted = false;
GT_Utility.sendChatToPlayer(aPlayer, GT_Utility.trans("055", "Normal"));
@@ -118,44 +108,44 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
}
@Override
- protected boolean letsEnergyInImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyInImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsEnergyOutImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean letsEnergyOutImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidInImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidInImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsFluidOutImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
+ protected boolean letsFluidOutImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable, Fluid aFluid,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsInImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsInImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean letsItemsOutImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, int aSlot, ICoverable aTileEntity) {
+ protected boolean letsItemsOutImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable, int aSlot,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, LiquidMeterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, LiquidMeterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -200,16 +190,15 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
final int maxCapacity;
if (getUIBuildContext().getTile() instanceof IFluidHandler) {
- FluidTankInfo[] tanks =
- ((IFluidHandler) getUIBuildContext().getTile()).getTankInfo(ForgeDirection.UNKNOWN);
- maxCapacity =
- Arrays.stream(tanks).mapToInt(tank -> tank.capacity).sum();
+ FluidTankInfo[] tanks = ((IFluidHandler) getUIBuildContext().getTile())
+ .getTankInfo(ForgeDirection.UNKNOWN);
+ maxCapacity = Arrays.stream(tanks).mapToInt(tank -> tank.capacity).sum();
} else {
maxCapacity = -1;
}
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_LiquidMeter.this)
+ builder.widget(
+ new CoverDataControllerWidget<>(this::getCoverData, this::setCoverData, GT_Cover_LiquidMeter.this)
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofRedstone(),
coverData -> coverData.inverted,
@@ -217,8 +206,7 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
coverData.inverted = state;
return coverData;
},
- widget -> widget.addTooltip(0, NORMAL)
- .addTooltip(1, INVERTED)
+ widget -> widget.addTooltip(0, NORMAL).addTooltip(1, INVERTED)
.setPos(spaceX * 0, spaceY * 0))
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
@@ -229,22 +217,23 @@ public class GT_Cover_LiquidMeter extends GT_CoverBehaviorBase<GT_Cover_LiquidMe
},
widget -> widget.setOnScrollNumbers(1000, 100, 100000)
.setNumbers(0, maxCapacity > 0 ? maxCapacity : Integer.MAX_VALUE)
- .setFocusOnGuiOpen(true)
- .setPos(spaceX * 0, spaceY * 1 + 2)
+ .setFocusOnGuiOpen(true).setPos(spaceX * 0, spaceY * 1 + 2)
.setSize(spaceX * 4 + 5, 12))
.setPos(startX, startY))
- .widget(TextWidget.dynamicString(
+ .widget(
+ TextWidget.dynamicString(
() -> getCoverData() != null ? getCoverData().inverted ? INVERTED : NORMAL : "")
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("222", "Fluid threshold"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5 - 10, startY + spaceY * 1 + 4));
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("222", "Fluid threshold"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5 - 10, startY + spaceY * 1 + 4));
}
}
public static class LiquidMeterData implements ISerializableObject {
+
private boolean inverted;
/** The special value {@code 0} means threshold check is disabled. */
private int threshold;
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_NeedMaintainance.java b/src/main/java/gregtech/common/covers/GT_Cover_NeedMaintainance.java
index 5dfb837499..cb8c4e691e 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_NeedMaintainance.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_NeedMaintainance.java
@@ -1,7 +1,12 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -14,9 +19,6 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
@@ -33,21 +35,20 @@ public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
}
public static boolean isRotor(ItemStack rotor) {
- return (rotor != null
- && rotor.getItem() instanceof GT_MetaGenerated_Tool
+ return (rotor != null && rotor.getItem() instanceof GT_MetaGenerated_Tool
&& rotor.getItemDamage() >= 170
&& rotor.getItemDamage() <= 176);
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
boolean needsRepair = false;
if (aTileEntity instanceof IGregTechTileEntity) {
IGregTechTileEntity tTileEntity = (IGregTechTileEntity) aTileEntity;
@@ -67,8 +68,10 @@ public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
if (coverVar == 5) {
needsRepair = (tCur >= tMax * 8 / 10);
} else {
- long mExpectedDamage = Math.round(Math.min(
- multi.mEUt / multi.damageFactorLow, Math.pow(multi.mEUt, multi.damageFactorHigh)));
+ long mExpectedDamage = Math.round(
+ Math.min(
+ multi.mEUt / multi.damageFactorLow,
+ Math.pow(multi.mEUt, multi.damageFactorHigh)));
needsRepair = tCur + mExpectedDamage * 2 >= tMax;
}
} else {
@@ -87,15 +90,8 @@ public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 14;
if (aCoverVariable < 0) {
aCoverVariable = 13;
@@ -133,15 +129,18 @@ public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
break;
case 10:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("066", "Emit if rotor needs maintenance low accuracy mod"));
+ aPlayer,
+ GT_Utility.trans("066", "Emit if rotor needs maintenance low accuracy mod"));
break;
case 11:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("067", "Emit if rotor needs maintenance low accuracy mod(inverted)"));
+ aPlayer,
+ GT_Utility.trans("067", "Emit if rotor needs maintenance low accuracy mod(inverted)"));
break;
case 12:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("068", "Emit if rotor needs maintenance high accuracy mod"));
+ aPlayer,
+ GT_Utility.trans("068", "Emit if rotor needs maintenance high accuracy mod"));
break;
case 13:
GT_Utility.sendChatToPlayer(
@@ -183,8 +182,8 @@ public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -224,94 +223,93 @@ public class GT_Cover_NeedMaintainance extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- final String[] tooltipText = {
- GT_Utility.trans("056", "Emit if 1 Maintenance Needed"),
- GT_Utility.trans("058", "Emit if 2 Maintenance Needed"),
- GT_Utility.trans("060", "Emit if 3 Maintenance Needed"),
- GT_Utility.trans("062", "Emit if 4 Maintenance Needed"),
- GT_Utility.trans("064", "Emit if 5 Maintenance Needed"),
- GT_Utility.trans("066", "Emit if rotor needs maintenance low accuracy mod"),
- GT_Utility.trans("068", "Emit if rotor needs maintenance high accuracy mod"),
- };
+ final String[] tooltipText = { GT_Utility.trans("056", "Emit if 1 Maintenance Needed"),
+ GT_Utility.trans("058", "Emit if 2 Maintenance Needed"),
+ GT_Utility.trans("060", "Emit if 3 Maintenance Needed"),
+ GT_Utility.trans("062", "Emit if 4 Maintenance Needed"),
+ GT_Utility.trans("064", "Emit if 5 Maintenance Needed"),
+ GT_Utility.trans("066", "Emit if rotor needs maintenance low accuracy mod"),
+ GT_Utility.trans("068", "Emit if rotor needs maintenance high accuracy mod"), };
- final String[] buttonText = {
- GT_Utility.trans("247", "1 Issue"),
- GT_Utility.trans("248", "2 Issues"),
- GT_Utility.trans("249", "3 Issues"),
- GT_Utility.trans("250", "4 Issues"),
- GT_Utility.trans("251", "5 Issues"),
- GT_Utility.trans("252", "Rotor < 80%"),
- GT_Utility.trans("253", "Rotor < 100%"),
- GT_Utility.trans("INVERTED", "Inverted"),
- GT_Utility.trans("NORMAL", "Normal"),
- };
+ final String[] buttonText = { GT_Utility.trans("247", "1 Issue"), GT_Utility.trans("248", "2 Issues"),
+ GT_Utility.trans("249", "3 Issues"), GT_Utility.trans("250", "4 Issues"),
+ GT_Utility.trans("251", "5 Issues"), GT_Utility.trans("252", "Rotor < 80%"),
+ GT_Utility.trans("253", "Rotor < 100%"), GT_Utility.trans("INVERTED", "Inverted"),
+ GT_Utility.trans("NORMAL", "Normal"), };
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_NeedMaintainance.this,
- (index, coverData) -> isEnabled(index, convert(coverData)),
- (index, coverData) -> new ISerializableObject.LegacyCoverData(
- getNewCoverVariable(index, convert(coverData))))
- .addToggleButton(
- 0,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[0]).setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[1]).setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[2]).setPos(spaceX * 0, spaceY * 2))
- .addToggleButton(
- 3,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[3]).setPos(spaceX * 0, spaceY * 3))
- .addToggleButton(
- 4,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[4]).setPos(spaceX * 4 + 4, spaceY * 0))
- .addToggleButton(
- 5,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[5]).setPos(spaceX * 4 + 4, spaceY * 1))
- .addToggleButton(
- 6,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.addTooltip(tooltipText[6]).setPos(spaceX * 4 + 4, spaceY * 2))
- .addToggleButton(
- 7,
- CoverDataFollower_ToggleButtonWidget.ofRedstone(),
- widget -> widget.setPos(spaceX * 4 + 4, spaceY * 3))
- .setPos(startX, startY))
- .widget(new TextWidget(buttonText[0])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 0))
- .widget(new TextWidget(buttonText[1])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 1))
- .widget(new TextWidget(buttonText[2])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 2))
- .widget(new TextWidget(buttonText[3])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 3))
- .widget(new TextWidget(buttonText[4])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 0))
- .widget(new TextWidget(buttonText[5])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 1))
- .widget(new TextWidget(buttonText[6])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 2))
- .widget(TextWidget.dynamicString(
- () -> isEnabled(7, convert(getCoverData())) ? buttonText[7] : buttonText[8])
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 3));
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_NeedMaintainance.this,
+ (index, coverData) -> isEnabled(index, convert(coverData)),
+ (index, coverData) -> new ISerializableObject.LegacyCoverData(
+ getNewCoverVariable(index, convert(coverData)))).addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[0]).setPos(spaceX * 0, spaceY * 0))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[1])
+ .setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[2])
+ .setPos(spaceX * 0, spaceY * 2))
+ .addToggleButton(
+ 3,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[3])
+ .setPos(spaceX * 0, spaceY * 3))
+ .addToggleButton(
+ 4,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[4])
+ .setPos(spaceX * 4 + 4, spaceY * 0))
+ .addToggleButton(
+ 5,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[5])
+ .setPos(spaceX * 4 + 4, spaceY * 1))
+ .addToggleButton(
+ 6,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.addTooltip(tooltipText[6])
+ .setPos(spaceX * 4 + 4, spaceY * 2))
+ .addToggleButton(
+ 7,
+ CoverDataFollower_ToggleButtonWidget.ofRedstone(),
+ widget -> widget.setPos(spaceX * 4 + 4, spaceY * 3))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(buttonText[0]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(buttonText[1]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(buttonText[2]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 2))
+ .widget(
+ new TextWidget(buttonText[3]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 3))
+ .widget(
+ new TextWidget(buttonText[4]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(buttonText[5]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(buttonText[6]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 2))
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> isEnabled(7, convert(getCoverData())) ? buttonText[7] : buttonText[8])
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5 + 4, 4 + startY + spaceY * 3));
}
private int getNewCoverVariable(int id, int coverVariable) {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_PlayerDetector.java b/src/main/java/gregtech/common/covers/GT_Cover_PlayerDetector.java
index 7f9e2ae5b0..5746807247 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_PlayerDetector.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_PlayerDetector.java
@@ -1,7 +1,12 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -11,9 +16,6 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_PlayerDetector extends GT_CoverBehavior {
@@ -33,14 +35,14 @@ public class GT_Cover_PlayerDetector extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
boolean playerDetected = false;
if (aTileEntity instanceof IGregTechTileEntity) {
@@ -55,10 +57,12 @@ public class GT_Cover_PlayerDetector extends GT_CoverBehavior {
for (Object tObject : aTileEntity.getWorld().playerEntities) {
if ((tObject instanceof EntityPlayerMP)) {
EntityPlayerMP tEntity = (EntityPlayerMP) tObject;
- int dist = Math.max(1, (int) tEntity.getDistance(
- aTileEntity.getXCoord() + 0.5D,
- aTileEntity.getYCoord() + 0.5D,
- aTileEntity.getZCoord() + 0.5D));
+ int dist = Math.max(
+ 1,
+ (int) tEntity.getDistance(
+ aTileEntity.getXCoord() + 0.5D,
+ aTileEntity.getYCoord() + 0.5D,
+ aTileEntity.getZCoord() + 0.5D));
if (dist < range) {
if (aCoverVariable == 0) {
playerDetected = true;
@@ -82,15 +86,8 @@ public class GT_Cover_PlayerDetector extends GT_CoverBehavior {
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 3;
if (aCoverVariable < 0) {
aCoverVariable = 2;
@@ -140,8 +137,8 @@ public class GT_Cover_PlayerDetector extends GT_CoverBehavior {
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@@ -181,34 +178,42 @@ public class GT_Cover_PlayerDetector extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_PlayerDetector.this,
- (index, coverData) -> index == convert(coverData),
- (index, coverData) -> new ISerializableObject.LegacyCoverData(index))
- .addToggleButton(
- 0, CoverDataFollower_ToggleButtonWidget.ofCheck(), widget -> widget.addTooltip(
- GT_Utility.trans("068.1", "Emit if any Player is close"))
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_PlayerDetector.this,
+ (index, coverData) -> index == convert(coverData),
+ (index, coverData) -> new ISerializableObject.LegacyCoverData(index)).addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget
+ .addTooltip(GT_Utility.trans("068.1", "Emit if any Player is close"))
.setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1, CoverDataFollower_ToggleButtonWidget.ofCheck(), widget -> widget.addTooltip(
- GT_Utility.trans("069.1", "Emit if other Player is close"))
- .setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 2, CoverDataFollower_ToggleButtonWidget.ofCheck(), widget -> widget.addTooltip(
- GT_Utility.trans("070", "Emit if you are close"))
- .setPos(spaceX * 0, spaceY * 2))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("319", "Any player"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("320", "Other players"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("321", "Only owner"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, 4 + startY + spaceY * 2));
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget
+ .addTooltip(
+ GT_Utility.trans("069.1", "Emit if other Player is close"))
+ .setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget
+ .addTooltip(GT_Utility.trans("070", "Emit if you are close"))
+ .setPos(spaceX * 0, spaceY * 2))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("319", "Any player")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("320", "Other players"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("321", "Only owner")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, 4 + startY + spaceY * 2));
}
}
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Pump.java b/src/main/java/gregtech/common/covers/GT_Cover_Pump.java
index c15f7aec38..57f39d4ba6 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Pump.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Pump.java
@@ -1,7 +1,14 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.fluids.IFluidHandler;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -12,13 +19,9 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.fluids.IFluidHandler;
public class GT_Cover_Pump extends GT_CoverBehavior {
+
public final int mTransferRate;
/**
@@ -35,14 +38,14 @@ public class GT_Cover_Pump extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if ((aCoverVariable % 6 > 1) && ((aTileEntity instanceof IMachineProgress))) {
if (((IMachineProgress) aTileEntity).isAllowedToWork() != aCoverVariable % 6 < 4) {
return aCoverVariable;
@@ -57,8 +60,8 @@ public class GT_Cover_Pump extends GT_CoverBehavior {
FluidStack tLiquid = tTank1.drain(ForgeDirection.getOrientation(aSide), this.mTransferRate, false);
if (tLiquid != null) {
tLiquid = tLiquid.copy();
- tLiquid.amount =
- tTank2.fill(ForgeDirection.getOrientation(aSide).getOpposite(), tLiquid, false);
+ tLiquid.amount = tTank2
+ .fill(ForgeDirection.getOrientation(aSide).getOpposite(), tLiquid, false);
if (tLiquid.amount > 0 && canTransferFluid(tLiquid)) {
tTank2.fill(
ForgeDirection.getOrientation(aSide).getOpposite(),
@@ -67,8 +70,8 @@ public class GT_Cover_Pump extends GT_CoverBehavior {
}
}
} else {
- FluidStack tLiquid =
- tTank2.drain(ForgeDirection.getOrientation(aSide).getOpposite(), this.mTransferRate, false);
+ FluidStack tLiquid = tTank2
+ .drain(ForgeDirection.getOrientation(aSide).getOpposite(), this.mTransferRate, false);
if (tLiquid != null) {
tLiquid = tLiquid.copy();
tLiquid.amount = tTank1.fill(ForgeDirection.getOrientation(aSide), tLiquid, false);
@@ -76,7 +79,9 @@ public class GT_Cover_Pump extends GT_CoverBehavior {
tTank1.fill(
ForgeDirection.getOrientation(aSide),
tTank2.drain(
- ForgeDirection.getOrientation(aSide).getOpposite(), tLiquid.amount, true),
+ ForgeDirection.getOrientation(aSide).getOpposite(),
+ tLiquid.amount,
+ true),
true);
}
}
@@ -91,15 +96,8 @@ public class GT_Cover_Pump extends GT_CoverBehavior {
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 12;
if (aCoverVariable < 0) {
aCoverVariable = 11;
@@ -236,65 +234,80 @@ public class GT_Cover_Pump extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_Pump.this,
- (id, coverData) -> !getClickable(id, convert(coverData)),
- (id, coverData) -> new ISerializableObject.LegacyCoverData(
- getNewCoverVariable(id, convert(coverData))))
- .addToggleButton(
- 0,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
- .addTooltip(GT_Utility.trans("006", "Export"))
- .setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
- .addTooltip(GT_Utility.trans("007", "Import"))
- .setPos(spaceX * 1, spaceY * 0))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
- .addTooltip(GT_Utility.trans("224", "Always On"))
- .setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 3,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
- .addTooltip(GT_Utility.trans("225", "Active with Redstone Signal"))
- .setPos(spaceX * 1, spaceY * 1))
- .addToggleButton(
- 4,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
- .addTooltip(GT_Utility.trans("226", "Inactive with Redstone Signal"))
- .setPos(spaceX * 2, spaceY * 1))
- .addToggleButton(
- 5,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ALLOW_INPUT)
- .addTooltip(GT_Utility.trans("227", "Allow Input"))
- .setPos(spaceX * 0, spaceY * 2))
- .addToggleButton(
- 6,
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLOCK_INPUT)
- .addTooltip(GT_Utility.trans("228", "Block Input"))
- .setPos(spaceX * 1, spaceY * 2))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("229", "Import/Export"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 3 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("230", "Conditional"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 3 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("231", "Enable Input"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 3, 3 + startY + spaceY * 2));
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_Pump.this,
+ (id, coverData) -> !getClickable(id, convert(coverData)),
+ (id, coverData) -> new ISerializableObject.LegacyCoverData(
+ getNewCoverVariable(id, convert(coverData)))).addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_EXPORT)
+ .addTooltip(GT_Utility.trans("006", "Export"))
+ .setPos(spaceX * 0, spaceY * 0))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_IMPORT)
+ .addTooltip(GT_Utility.trans("007", "Import"))
+ .setPos(spaceX * 1, spaceY * 0))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK)
+ .addTooltip(GT_Utility.trans("224", "Always On"))
+ .setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 3,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_ON)
+ .addTooltip(
+ GT_Utility.trans(
+ "225",
+ "Active with Redstone Signal"))
+ .setPos(spaceX * 1, spaceY * 1))
+ .addToggleButton(
+ 4,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_REDSTONE_OFF)
+ .addTooltip(
+ GT_Utility.trans(
+ "226",
+ "Inactive with Redstone Signal"))
+ .setPos(spaceX * 2, spaceY * 1))
+ .addToggleButton(
+ 5,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ALLOW_INPUT)
+ .addTooltip(GT_Utility.trans("227", "Allow Input"))
+ .setPos(spaceX * 0, spaceY * 2))
+ .addToggleButton(
+ 6,
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ widget -> widget
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BLOCK_INPUT)
+ .addTooltip(GT_Utility.trans("228", "Block Input"))
+ .setPos(spaceX * 1, spaceY * 2))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("229", "Import/Export"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 3 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("230", "Conditional"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 3 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("231", "Enable Input"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 3, 3 + startY + spaceY * 2));
}
private int getNewCoverVariable(int id, int coverVariable) {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneConductor.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneConductor.java
index 4be44136e6..733376f6e2 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneConductor.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneConductor.java
@@ -1,46 +1,42 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.fluids.Fluid;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.GT_CoverBehavior;
import gregtech.api.util.GT_Utility;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.fluids.Fluid;
@SuppressWarnings("unused") // Legacy from GT4. TODO: Consider re-enable registration
public class GT_Cover_RedstoneConductor extends GT_CoverBehavior {
+
GT_Cover_RedstoneConductor(ITexture coverTexture) {
super(coverTexture);
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if (aCoverVariable == 0) {
aTileEntity.setOutputRedstoneSignal(aSide, aTileEntity.getStrongestRedstone());
} else if (aCoverVariable < 7) {
aTileEntity.setOutputRedstoneSignal(
- aSide, aTileEntity.getInternalInputRedstoneSignal((byte) (aCoverVariable - 1)));
+ aSide,
+ aTileEntity.getInternalInputRedstoneSignal((byte) (aCoverVariable - 1)));
}
return aCoverVariable;
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 7;
if (aCoverVariable < 0) {
aCoverVariable = 6;
@@ -102,8 +98,8 @@ public class GT_Cover_RedstoneConductor extends GT_CoverBehavior {
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverExternal.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverExternal.java
index 17d6b2e1c9..9cd9f7f5fb 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverExternal.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverExternal.java
@@ -19,25 +19,24 @@ public class GT_Cover_RedstoneReceiverExternal extends GT_Cover_RedstoneWireless
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
aTileEntity.setOutputRedstoneSignal(
aSide,
- GregTech_API.sWirelessRedstone.get(Integer.valueOf(aCoverVariable)) == null
- ? 0
+ GregTech_API.sWirelessRedstone.get(Integer.valueOf(aCoverVariable)) == null ? 0
: ((Byte) GregTech_API.sWirelessRedstone.get(Integer.valueOf(aCoverVariable))).byteValue());
return aCoverVariable;
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverInternal.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverInternal.java
index 1e0a5f0593..8dec852149 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverInternal.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneReceiverInternal.java
@@ -21,32 +21,27 @@ public class GT_Cover_RedstoneReceiverInternal extends GT_Cover_RedstoneWireless
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if (aTileEntity instanceof IMachineProgress) {
if (getRedstoneInput(aSide, aInputRedstone, aCoverID, aCoverVariable, aTileEntity) > 0)
((IMachineProgress) aTileEntity).enableWorking();
- else ((IMachineProgress) aTileEntity).disableWorking();
+ else((IMachineProgress) aTileEntity).disableWorking();
((IMachineProgress) aTileEntity).setWorkDataValue(aInputRedstone);
}
return aCoverVariable;
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide,
- int aCoverID,
- ISerializableObject.LegacyCoverData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID,
+ ISerializableObject.LegacyCoverData aCoverVariable, ICoverable aTileEntity, long aTimer) {
return true;
}
@Override
- public byte getRedstoneInput(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
- return GregTech_API.sWirelessRedstone.get(aCoverVariable) == null
- ? 0
+ public byte getRedstoneInput(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
+ return GregTech_API.sWirelessRedstone.get(aCoverVariable) == null ? 0
: GregTech_API.sWirelessRedstone.get(aCoverVariable);
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneSignalizer.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneSignalizer.java
index 31a542a924..d596b4ec15 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneSignalizer.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneSignalizer.java
@@ -1,35 +1,30 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.fluids.Fluid;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.interfaces.tileentity.IMachineProgress;
import gregtech.api.util.GT_CoverBehavior;
import gregtech.api.util.GT_Utility;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.fluids.Fluid;
@SuppressWarnings("unused") // TODO: Consider re-registering this
public class GT_Cover_RedstoneSignalizer extends GT_CoverBehavior {
+
GT_Cover_RedstoneSignalizer(ITexture coverTexture) {
super(coverTexture);
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + 1) % 48;
switch (aCoverVariable / 16) {
case 0:
@@ -37,11 +32,13 @@ public class GT_Cover_RedstoneSignalizer extends GT_CoverBehavior {
break;
case 1:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("079", "Conditional Signal = ") + (aCoverVariable & 0xF));
+ aPlayer,
+ GT_Utility.trans("079", "Conditional Signal = ") + (aCoverVariable & 0xF));
break;
case 2:
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("080", "Inverted Conditional Signal = ") + (aCoverVariable & 0xF));
+ aPlayer,
+ GT_Utility.trans("080", "Inverted Conditional Signal = ") + (aCoverVariable & 0xF));
break;
}
return aCoverVariable;
@@ -83,8 +80,8 @@ public class GT_Cover_RedstoneSignalizer extends GT_CoverBehavior {
}
@Override
- public byte getRedstoneInput(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public byte getRedstoneInput(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
if (aCoverVariable < 16) {
return (byte) (aCoverVariable & 0xF);
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterExternal.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterExternal.java
index 984e817665..4f3a8367d3 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterExternal.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterExternal.java
@@ -2,12 +2,13 @@ package gregtech.common.covers;
import static gregtech.api.enums.GT_Values.ALL_VALID_SIDES;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.covers.IControlsWorkCover;
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.ISerializableObject;
-import net.minecraft.item.ItemStack;
public class GT_Cover_RedstoneTransmitterExternal extends GT_Cover_RedstoneWirelessBase {
@@ -24,8 +25,8 @@ public class GT_Cover_RedstoneTransmitterExternal extends GT_Cover_RedstoneWirel
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
// TODO remove next line after 2.3.0
if (!IControlsWorkCover.makeSureOnlyOne(aSide, aTileEntity)) return aCoverVariable;
GregTech_API.sWirelessRedstone.put(aCoverVariable, aInputRedstone);
@@ -33,12 +34,8 @@ public class GT_Cover_RedstoneTransmitterExternal extends GT_Cover_RedstoneWirel
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide,
- int aCoverID,
- ISerializableObject.LegacyCoverData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID,
+ ISerializableObject.LegacyCoverData aCoverVariable, ICoverable aTileEntity, long aTimer) {
return true;
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterInternal.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterInternal.java
index a1f020c40c..f4b7f5fa80 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterInternal.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneTransmitterInternal.java
@@ -19,16 +19,16 @@ public class GT_Cover_RedstoneTransmitterInternal extends GT_Cover_RedstoneWirel
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
- GregTech_API.sWirelessRedstone.put(
- Integer.valueOf(aCoverVariable), Byte.valueOf(aTileEntity.getOutputRedstoneSignal(aSide)));
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
+ GregTech_API.sWirelessRedstone
+ .put(Integer.valueOf(aCoverVariable), Byte.valueOf(aTileEntity.getOutputRedstoneSignal(aSide)));
return aCoverVariable;
}
@@ -43,8 +43,8 @@ public class GT_Cover_RedstoneTransmitterInternal extends GT_Cover_RedstoneWirel
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneWirelessBase.java b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneWirelessBase.java
index f6e5381c74..441201af08 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_RedstoneWirelessBase.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_RedstoneWirelessBase.java
@@ -1,8 +1,12 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.GregTech_API;
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
@@ -13,8 +17,6 @@ import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.fluids.Fluid;
public abstract class GT_Cover_RedstoneWirelessBase extends GT_CoverBehavior {
@@ -36,26 +38,22 @@ public abstract class GT_Cover_RedstoneWirelessBase extends GT_CoverBehavior {
}
@Override
- public boolean onCoverRemoval(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, boolean aForced) {
+ public boolean onCoverRemoval(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ boolean aForced) {
GregTech_API.sWirelessRedstone.put(aCoverVariable, (byte) 0);
return true;
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- ISerializableObject.LegacyCoverData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID,
+ ISerializableObject.LegacyCoverData aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX,
+ float aY, float aZ) {
if (((aX > 0.375D) && (aX < 0.625D)) || ((aSide > 3) && ((aY > 0.375D) && (aY < 0.625D)))) {
GregTech_API.sWirelessRedstone.put(aCoverVariable.get(), (byte) 0);
- aCoverVariable.set((aCoverVariable.get() & (PRIVATE_MASK | CHECKBOX_MASK))
- | (((Integer) GT_Utility.stackToInt(aPlayer.inventory.getCurrentItem())).hashCode() & PUBLIC_MASK));
+ aCoverVariable.set(
+ (aCoverVariable.get() & (PRIVATE_MASK | CHECKBOX_MASK))
+ | (((Integer) GT_Utility.stackToInt(aPlayer.inventory.getCurrentItem())).hashCode()
+ & PUBLIC_MASK));
GT_Utility.sendChatToPlayer(aPlayer, GT_Utility.trans("081", "Frequency: ") + aCoverVariable);
return true;
}
@@ -64,15 +62,8 @@ public abstract class GT_Cover_RedstoneWirelessBase extends GT_CoverBehavior {
@Override
@SuppressWarnings("deprecation")
- public boolean onCoverRightclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public boolean onCoverRightclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (((aX > 0.375D) && (aX < 0.625D)) || ((aSide > 3) && ((aY > 0.375D) && (aY < 0.625D)))) {
GregTech_API.sWirelessRedstone.put(aCoverVariable, (byte) 0);
@@ -82,23 +73,16 @@ public abstract class GT_Cover_RedstoneWirelessBase extends GT_CoverBehavior {
aCoverVariable = (aCoverVariable & (PRIVATE_MASK | CHECKBOX_MASK)) | (val & PUBLIC_MASK);
aTileEntity.setCoverDataAtSide(aSide, aCoverVariable);
- GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("081", "Frequency: ") + (aCoverVariable & PUBLIC_MASK));
+ GT_Utility
+ .sendChatToPlayer(aPlayer, GT_Utility.trans("081", "Frequency: ") + (aCoverVariable & PUBLIC_MASK));
return true;
}
return false;
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (((aX > 0.375D) && (aX < 0.625D))
|| ((aSide <= 3) || (((aY > 0.375D) && (aY < 0.625D)) || ((((aZ <= 0.375D) || (aZ >= 0.625D))))))) {
GregTech_API.sWirelessRedstone.put(aCoverVariable, (byte) 0);
@@ -210,32 +194,34 @@ public abstract class GT_Cover_RedstoneWirelessBase extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_RedstoneWirelessBase.this)
- .addFollower(
- new CoverDataFollower_TextFieldWidget<>(),
- coverData -> String.valueOf(getFlagFrequency(convert(coverData))),
- (coverData, text) -> new ISerializableObject.LegacyCoverData(
- (int) MathExpression.parseMathExpression(text)
- | getFlagCheckbox(convert(coverData))),
- widget -> widget.setOnScrollNumbers()
- .setNumbers(0, MAX_CHANNEL)
- .setFocusOnGuiOpen(true)
- .setPos(spaceX * 0, spaceY * 0 + 2)
- .setSize(spaceX * 4 - 3, 12))
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- coverData -> getFlagCheckbox(convert(coverData)) > 0,
- (coverData, state) -> new ISerializableObject.LegacyCoverData(
- getFlagFrequency(convert(coverData)) | (state ? CHECKBOX_MASK : 0)),
- widget -> widget.setPos(spaceX * 0, spaceY * 2))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("246", "Frequency"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 4, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("602", "Use Private Frequency"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 1, startY + spaceY * 2 + 4));
+ builder.widget(
+ new CoverDataControllerWidget<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_RedstoneWirelessBase.this)
+ .addFollower(
+ new CoverDataFollower_TextFieldWidget<>(),
+ coverData -> String.valueOf(getFlagFrequency(convert(coverData))),
+ (coverData, text) -> new ISerializableObject.LegacyCoverData(
+ (int) MathExpression.parseMathExpression(text)
+ | getFlagCheckbox(convert(coverData))),
+ widget -> widget.setOnScrollNumbers().setNumbers(0, MAX_CHANNEL)
+ .setFocusOnGuiOpen(true).setPos(spaceX * 0, spaceY * 0 + 2)
+ .setSize(spaceX * 4 - 3, 12))
+ .addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ coverData -> getFlagCheckbox(convert(coverData)) > 0,
+ (coverData, state) -> new ISerializableObject.LegacyCoverData(
+ getFlagFrequency(convert(coverData)) | (state ? CHECKBOX_MASK : 0)),
+ widget -> widget.setPos(spaceX * 0, spaceY * 2))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("246", "Frequency")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 4, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("602", "Use Private Frequency"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 1, startY + spaceY * 2 + 4));
}
private int getFlagFrequency(int coverVariable) {
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Screen.java b/src/main/java/gregtech/common/covers/GT_Cover_Screen.java
index 84fc84d820..8f26c112ae 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Screen.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Screen.java
@@ -1,10 +1,11 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.fluids.Fluid;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.GT_CoverBehavior;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_Screen extends GT_CoverBehavior {
@@ -21,8 +22,8 @@ public class GT_Cover_Screen extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@@ -77,33 +78,26 @@ public class GT_Cover_Screen extends GT_CoverBehavior {
}
@Override
- public boolean manipulatesSidedRedstoneOutput(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
+ public boolean manipulatesSidedRedstoneOutput(byte aSide, int aCoverID, int aCoverVariable,
+ ICoverable aTileEntity) {
return false;
}
@Override
- public boolean onCoverRightclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public boolean onCoverRightclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
return false;
}
@Override
- public boolean onCoverRemoval(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, boolean aForced) {
+ public boolean onCoverRemoval(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ boolean aForced) {
return true;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return 0;
}
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Shutter.java b/src/main/java/gregtech/common/covers/GT_Cover_Shutter.java
index 6a3df96c5a..f1e977efad 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Shutter.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Shutter.java
@@ -1,7 +1,11 @@
package gregtech.common.covers;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraftforge.fluids.Fluid;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -12,8 +16,6 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraftforge.fluids.Fluid;
public class GT_Cover_Shutter extends GT_CoverBehavior {
@@ -30,27 +32,20 @@ public class GT_Cover_Shutter extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return aCoverVariable;
}
@Override
- public int onCoverScrewdriverclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public int onCoverScrewdriverclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable = (aCoverVariable + (aPlayer.isSneaking() ? -1 : 1)) % 4;
if (aCoverVariable < 0) {
aCoverVariable = 3;
@@ -77,64 +72,56 @@ public class GT_Cover_Shutter extends GT_CoverBehavior {
@Override
public boolean letsRedstoneGoIn(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 3
+ return aCoverVariable >= 2 ? aCoverVariable == 3
: !(aTileEntity instanceof IMachineProgress)
|| (((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0));
}
@Override
public boolean letsRedstoneGoOut(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 2
+ return aCoverVariable >= 2 ? aCoverVariable == 2
: !(aTileEntity instanceof IMachineProgress)
|| (((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0));
}
@Override
public boolean letsEnergyIn(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 3
+ return aCoverVariable >= 2 ? aCoverVariable == 3
: !(aTileEntity instanceof IMachineProgress)
|| (((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0));
}
@Override
public boolean letsEnergyOut(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 2
+ return aCoverVariable >= 2 ? aCoverVariable == 2
: !(aTileEntity instanceof IMachineProgress)
|| ((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0);
}
@Override
public boolean letsFluidIn(byte aSide, int aCoverID, int aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 3
+ return aCoverVariable >= 2 ? aCoverVariable == 3
: !(aTileEntity instanceof IMachineProgress)
|| ((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0);
}
@Override
public boolean letsFluidOut(byte aSide, int aCoverID, int aCoverVariable, Fluid aFluid, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 2
+ return aCoverVariable >= 2 ? aCoverVariable == 2
: !(aTileEntity instanceof IMachineProgress)
|| ((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0);
}
@Override
public boolean letsItemsIn(byte aSide, int aCoverID, int aCoverVariable, int aSlot, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 3
+ return aCoverVariable >= 2 ? aCoverVariable == 3
: !(aTileEntity instanceof IMachineProgress)
|| ((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0);
}
@Override
public boolean letsItemsOut(byte aSide, int aCoverID, int aCoverVariable, int aSlot, ICoverable aTileEntity) {
- return aCoverVariable >= 2
- ? aCoverVariable == 2
+ return aCoverVariable >= 2 ? aCoverVariable == 2
: !(aTileEntity instanceof IMachineProgress)
|| ((IMachineProgress) aTileEntity).isAllowedToWork() == (aCoverVariable % 2 == 0);
}
@@ -180,41 +167,46 @@ public class GT_Cover_Shutter extends GT_CoverBehavior {
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
- builder.widget(new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
- this::getCoverData,
- this::setCoverData,
- GT_Cover_Shutter.this,
- (index, coverData) -> index == convert(coverData),
- (index, coverData) -> new ISerializableObject.LegacyCoverData(index))
- .addToggleButton(
- 0,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.setPos(spaceX * 0, spaceY * 0))
- .addToggleButton(
- 1,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.setPos(spaceX * 0, spaceY * 1))
- .addToggleButton(
- 2,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.setPos(spaceX * 0, spaceY * 2))
- .addToggleButton(
- 3,
- CoverDataFollower_ToggleButtonWidget.ofCheck(),
- widget -> widget.setPos(spaceX * 0, spaceY * 3))
- .setPos(startX, startY))
- .widget(new TextWidget(GT_Utility.trans("082", "Open if work enabled"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 0))
- .widget(new TextWidget(GT_Utility.trans("083", "Open if work disabled"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 1))
- .widget(new TextWidget(GT_Utility.trans("084", "Only Output allowed"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 2))
- .widget(new TextWidget(GT_Utility.trans("085", "Only Input allowed"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 3));
+ builder.widget(
+ new CoverDataControllerWidget.CoverDataIndexedControllerWidget_ToggleButtons<>(
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_Shutter.this,
+ (index, coverData) -> index == convert(coverData),
+ (index, coverData) -> new ISerializableObject.LegacyCoverData(index))
+ .addToggleButton(
+ 0,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 0))
+ .addToggleButton(
+ 1,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 1))
+ .addToggleButton(
+ 2,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 2))
+ .addToggleButton(
+ 3,
+ CoverDataFollower_ToggleButtonWidget.ofCheck(),
+ widget -> widget.setPos(spaceX * 0, spaceY * 3))
+ .setPos(startX, startY))
+ .widget(
+ new TextWidget(GT_Utility.trans("082", "Open if work enabled"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 0))
+ .widget(
+ new TextWidget(GT_Utility.trans("083", "Open if work disabled"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 1))
+ .widget(
+ new TextWidget(GT_Utility.trans("084", "Only Output allowed"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 2))
+ .widget(
+ new TextWidget(GT_Utility.trans("085", "Only Input allowed"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(3 + startX + spaceX * 1, 4 + startY + spaceY * 3));
}
}
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_SolarPanel.java b/src/main/java/gregtech/common/covers/GT_Cover_SolarPanel.java
index de1a0c7617..7bd0503214 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_SolarPanel.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_SolarPanel.java
@@ -2,15 +2,17 @@ package gregtech.common.covers;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.GT_CoverBehavior;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.ISerializableObject;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
public class GT_Cover_SolarPanel extends GT_CoverBehavior {
+
private final int mVoltage;
public GT_Cover_SolarPanel(int aVoltage) {
@@ -18,14 +20,14 @@ public class GT_Cover_SolarPanel extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if (aSide != 1) return 0;
int coverState = aCoverVariable & 0x3;
int coverNum = aCoverVariable >> 2;
@@ -61,15 +63,9 @@ public class GT_Cover_SolarPanel extends GT_CoverBehavior {
}
@Override
- protected boolean onCoverRightClickImpl(
- byte aSide,
- int aCoverID,
- ISerializableObject.LegacyCoverData aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected boolean onCoverRightClickImpl(byte aSide, int aCoverID,
+ ISerializableObject.LegacyCoverData aCoverVariable, ICoverable aTileEntity, EntityPlayer aPlayer, float aX,
+ float aY, float aZ) {
if (aPlayer.capabilities.isCreativeMode) {
GT_Utility.sendChatToPlayer(aPlayer, "Cleaned solar panel from " + (aCoverVariable.get() >> 2) + "% dirt");
aCoverVariable.set(aCoverVariable.get() & 0x3);
@@ -82,7 +78,8 @@ public class GT_Cover_SolarPanel extends GT_CoverBehavior {
aPlayer.inventory.mainInventory[i] = new ItemStack(Items.bucket);
if (aPlayer.inventoryContainer != null) aPlayer.inventoryContainer.detectAndSendChanges();
GT_Utility.sendChatToPlayer(
- aPlayer, "Cleaned solar panel from " + (aCoverVariable.get() >> 2) + "% dirt");
+ aPlayer,
+ "Cleaned solar panel from " + (aCoverVariable.get() >> 2) + "% dirt");
aCoverVariable.set(aCoverVariable.get() & 0x3);
return true;
}
@@ -93,15 +90,8 @@ public class GT_Cover_SolarPanel extends GT_CoverBehavior {
@Override
@SuppressWarnings("deprecation")
- public boolean onCoverRightclick(
- byte aSide,
- int aCoverID,
- int aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ public boolean onCoverRightclick(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (aPlayer.capabilities.isCreativeMode) {
GT_Utility.sendChatToPlayer(aPlayer, "Cleaned solar panel from " + (aCoverVariable >> 2) + "% dirt");
aTileEntity.setCoverDataAtSide(aSide, (aCoverVariable & 0x3));
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_SteamValve.java b/src/main/java/gregtech/common/covers/GT_Cover_SteamValve.java
index 30c48fdf56..916f5ed75e 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_SteamValve.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_SteamValve.java
@@ -1,9 +1,10 @@
package gregtech.common.covers;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
import gregtech.api.util.GT_ModHandler;
-import net.minecraftforge.fluids.FluidStack;
public class GT_Cover_SteamValve extends GT_Cover_Pump {
@@ -20,8 +21,8 @@ public class GT_Cover_SteamValve extends GT_Cover_Pump {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
diff --git a/src/main/java/gregtech/common/covers/GT_Cover_Vent.java b/src/main/java/gregtech/common/covers/GT_Cover_Vent.java
index 1208816d7d..184ac5bb57 100644
--- a/src/main/java/gregtech/common/covers/GT_Cover_Vent.java
+++ b/src/main/java/gregtech/common/covers/GT_Cover_Vent.java
@@ -3,10 +3,6 @@ package gregtech.common.covers;
import static gregtech.api.enums.GT_Values.SIDE_UNKNOWN;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
-import gregtech.api.interfaces.tileentity.ICoverable;
-import gregtech.api.interfaces.tileentity.IMachineProgress;
-import gregtech.api.util.GT_CoverBehavior;
-import gregtech.api.util.GT_Utility;
import net.minecraft.block.Block;
import net.minecraft.init.Blocks;
import net.minecraft.world.World;
@@ -16,7 +12,13 @@ import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidHandler;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.interfaces.tileentity.IMachineProgress;
+import gregtech.api.util.GT_CoverBehavior;
+import gregtech.api.util.GT_Utility;
+
public class GT_Cover_Vent extends GT_CoverBehavior {
+
private final int mEfficiency;
private final Fluid IC2_HOT_COOLANT = FluidRegistry.getFluid("ic2hotcoolant");
private final Fluid IC2_COOLANT = FluidRegistry.getFluid("ic2coolant");
@@ -26,14 +28,14 @@ public class GT_Cover_Vent extends GT_CoverBehavior {
}
@Override
- public boolean isRedstoneSensitive(
- byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public boolean isRedstoneSensitive(byte aSide, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
return false;
}
@Override
- public int doCoverThings(
- byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ public int doCoverThings(byte aSide, byte aInputRedstone, int aCoverID, int aCoverVariable, ICoverable aTileEntity,
+ long aTimer) {
if (aSide == SIDE_UNKNOWN) return 0;
int ret = 0;
if (aTileEntity instanceof IFluidHandler) {
@@ -60,8 +62,7 @@ public class GT_Cover_Vent extends GT_CoverBehavior {
final int offsetY = aTileEntity.getOffsetY(aSide, 1);
final int offsetZ = aTileEntity.getOffsetZ(aSide, 1);
final World world = aTileEntity.getWorld();
- if (aTileEntity.hasThingsToDo()
- && aCoverVariable != aTileEntity.getProgress()
+ if (aTileEntity.hasThingsToDo() && aCoverVariable != aTileEntity.getProgress()
&& !GT_Utility.hasBlockHitBox(world, offsetX, offsetY, offsetZ)) {
aTileEntity.increaseProgress(this.mEfficiency);
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverBase.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverBase.java
index 6b7c7f282e..e296785cd8 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverBase.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverBase.java
@@ -1,8 +1,18 @@
package gregtech.common.covers.redstone;
+import java.util.Arrays;
+import java.util.UUID;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -11,12 +21,6 @@ import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.Arrays;
-import java.util.UUID;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
public abstract class GT_Cover_AdvancedRedstoneReceiverBase
extends GT_Cover_AdvancedWirelessRedstoneBase<GT_Cover_AdvancedRedstoneReceiverBase.ReceiverData> {
@@ -66,26 +70,24 @@ public abstract class GT_Cover_AdvancedRedstoneReceiverBase
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
super.addUIWidgets(builder);
- builder.widget(new TextWidget(GT_Utility.trans("335", "Gate Mode"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5, 4 + startY + spaceY * 2));
+ builder.widget(
+ new TextWidget(GT_Utility.trans("335", "Gate Mode")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5, 4 + startY + spaceY * 2));
}
@SuppressWarnings("PointlessArithmeticExpression")
@Override
protected void addUIForDataController(CoverDataControllerWidget<ReceiverData> controller) {
super.addUIForDataController(controller);
- controller
- .addFollower(
- CoverDataFollower_ToggleButtonWidget.ofDisableable(),
- coverData -> coverData.mode == GateMode.AND,
- (coverData, state) -> {
- coverData.mode = GateMode.AND;
- return coverData;
- },
- widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_GATE_AND)
- .addTooltip(GT_Utility.trans("331", "AND Gate"))
- .setPos(spaceX * 0, spaceY * 2))
+ controller.addFollower(
+ CoverDataFollower_ToggleButtonWidget.ofDisableable(),
+ coverData -> coverData.mode == GateMode.AND,
+ (coverData, state) -> {
+ coverData.mode = GateMode.AND;
+ return coverData;
+ },
+ widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_GATE_AND)
+ .addTooltip(GT_Utility.trans("331", "AND Gate")).setPos(spaceX * 0, spaceY * 2))
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofDisableable(),
coverData -> coverData.mode == GateMode.NAND,
@@ -94,8 +96,7 @@ public abstract class GT_Cover_AdvancedRedstoneReceiverBase
return coverData;
},
widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_GATE_NAND)
- .addTooltip(GT_Utility.trans("332", "NAND Gate"))
- .setPos(spaceX * 1, spaceY * 2))
+ .addTooltip(GT_Utility.trans("332", "NAND Gate")).setPos(spaceX * 1, spaceY * 2))
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofDisableable(),
coverData -> coverData.mode == GateMode.OR,
@@ -104,8 +105,7 @@ public abstract class GT_Cover_AdvancedRedstoneReceiverBase
return coverData;
},
widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_GATE_OR)
- .addTooltip(GT_Utility.trans("333", "OR Gate"))
- .setPos(spaceX * 2, spaceY * 2))
+ .addTooltip(GT_Utility.trans("333", "OR Gate")).setPos(spaceX * 2, spaceY * 2))
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofDisableable(),
coverData -> coverData.mode == GateMode.NOR,
@@ -114,8 +114,7 @@ public abstract class GT_Cover_AdvancedRedstoneReceiverBase
return coverData;
},
widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_GATE_NOR)
- .addTooltip(GT_Utility.trans("334", "NOR Gate"))
- .setPos(spaceX * 3, spaceY * 2))
+ .addTooltip(GT_Utility.trans("334", "NOR Gate")).setPos(spaceX * 3, spaceY * 2))
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofDisableable(),
coverData -> coverData.mode == GateMode.SINGLE_SOURCE,
@@ -124,10 +123,11 @@ public abstract class GT_Cover_AdvancedRedstoneReceiverBase
return coverData;
},
widget -> widget.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_ANALOG)
- .addTooltips(Arrays.asList(
- "ANALOG Mode",
- "Only use this mode with ONE transmitter in total,",
- "no logic involved"))
+ .addTooltips(
+ Arrays.asList(
+ "ANALOG Mode",
+ "Only use this mode with ONE transmitter in total,",
+ "no logic involved"))
.setPos(spaceX * 4, spaceY * 2));
}
}
@@ -141,6 +141,7 @@ public abstract class GT_Cover_AdvancedRedstoneReceiverBase
}
public static class ReceiverData extends GT_Cover_AdvancedWirelessRedstoneBase.WirelessData {
+
private GateMode mode;
public ReceiverData(int frequency, UUID uuid, GateMode mode) {
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverExternal.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverExternal.java
index 56b7fadd24..caf4b6bdcd 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverExternal.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverExternal.java
@@ -10,13 +10,8 @@ public class GT_Cover_AdvancedRedstoneReceiverExternal extends GT_Cover_Advanced
}
@Override
- public ReceiverData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- ReceiverData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ public ReceiverData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID, ReceiverData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
aTileEntity.setOutputRedstoneSignal(
aSide,
getSignalAt(aCoverVariable.getUuid(), aCoverVariable.getFrequency(), aCoverVariable.getGateMode()));
@@ -25,14 +20,14 @@ public class GT_Cover_AdvancedRedstoneReceiverExternal extends GT_Cover_Advanced
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, ReceiverData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, ReceiverData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return false;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, ReceiverData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, ReceiverData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverInternal.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverInternal.java
index 61dbb7859c..f80fdc8e65 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverInternal.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneReceiverInternal.java
@@ -11,13 +11,8 @@ public class GT_Cover_AdvancedRedstoneReceiverInternal extends GT_Cover_Advanced
}
@Override
- public ReceiverData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- ReceiverData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ public ReceiverData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID, ReceiverData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
if (aTileEntity instanceof IMachineProgress) {
IMachineProgress machine = ((IMachineProgress) aTileEntity);
if (getRedstoneInput(aSide, aInputRedstone, aCoverID, aCoverVariable, aTileEntity) > 0) {
@@ -33,14 +28,14 @@ public class GT_Cover_AdvancedRedstoneReceiverInternal extends GT_Cover_Advanced
}
@Override
- protected byte getRedstoneInputImpl(
- byte aSide, byte aInputRedstone, int aCoverID, ReceiverData aCoverVariable, ICoverable aTileEntity) {
+ protected byte getRedstoneInputImpl(byte aSide, byte aInputRedstone, int aCoverID, ReceiverData aCoverVariable,
+ ICoverable aTileEntity) {
return getSignalAt(aCoverVariable.getUuid(), aCoverVariable.getFrequency(), aCoverVariable.getGateMode());
}
@Override
- protected boolean isRedstoneSensitiveImpl(
- byte aSide, int aCoverID, ReceiverData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ protected boolean isRedstoneSensitiveImpl(byte aSide, int aCoverID, ReceiverData aCoverVariable,
+ ICoverable aTileEntity, long aTimer) {
return true;
}
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterBase.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterBase.java
index c065c085b2..f39b573742 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterBase.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterBase.java
@@ -1,8 +1,19 @@
package gregtech.common.covers.redstone;
+import java.util.Objects;
+import java.util.UUID;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -11,16 +22,8 @@ import gregtech.api.util.ISerializableObject;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.Objects;
-import java.util.UUID;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-public abstract class GT_Cover_AdvancedRedstoneTransmitterBase<
- T extends GT_Cover_AdvancedRedstoneTransmitterBase.TransmitterData>
+public abstract class GT_Cover_AdvancedRedstoneTransmitterBase<T extends GT_Cover_AdvancedRedstoneTransmitterBase.TransmitterData>
extends GT_Cover_AdvancedWirelessRedstoneBase<T> {
public GT_Cover_AdvancedRedstoneTransmitterBase(Class<T> typeToken, ITexture coverTexture) {
@@ -33,28 +36,21 @@ public abstract class GT_Cover_AdvancedRedstoneTransmitterBase<
}
@Override
- public boolean onCoverRemovalImpl(
- byte aSide, int aCoverID, TransmitterData aCoverVariable, ICoverable aTileEntity, boolean aForced) {
+ public boolean onCoverRemovalImpl(byte aSide, int aCoverID, TransmitterData aCoverVariable, ICoverable aTileEntity,
+ boolean aForced) {
unregisterSignal(aSide, aCoverVariable, aTileEntity);
return true;
}
@Override
- protected void onBaseTEDestroyedImpl(
- byte aSide, int aCoverID, TransmitterData aCoverVariable, ICoverable aTileEntity) {
+ protected void onBaseTEDestroyedImpl(byte aSide, int aCoverID, TransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
unregisterSignal(aSide, aCoverVariable, aTileEntity);
}
@Override
- protected T onCoverScrewdriverClickImpl(
- byte aSide,
- int aCoverID,
- T aCoverVariable,
- ICoverable aTileEntity,
- EntityPlayer aPlayer,
- float aX,
- float aY,
- float aZ) {
+ protected T onCoverScrewdriverClickImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity,
+ EntityPlayer aPlayer, float aX, float aY, float aZ) {
aCoverVariable.invert = !aCoverVariable.invert;
GT_Utility.sendChatToPlayer(
aPlayer,
@@ -64,8 +60,8 @@ public abstract class GT_Cover_AdvancedRedstoneTransmitterBase<
}
@Override
- protected void preDataChangedImpl(
- byte aSide, int aCoverID, int aNewCoverId, T aCoverVariable, T aNewCoverVariable, ICoverable aTileEntity) {
+ protected void preDataChangedImpl(byte aSide, int aCoverID, int aNewCoverId, T aCoverVariable, T aNewCoverVariable,
+ ICoverable aTileEntity) {
if (aCoverVariable.frequency != aNewCoverVariable.frequency
|| !Objects.equals(aCoverVariable.uuid, aNewCoverVariable.uuid)) {
unregisterSignal(aSide, aCoverVariable, aTileEntity);
@@ -73,6 +69,7 @@ public abstract class GT_Cover_AdvancedRedstoneTransmitterBase<
}
public static class TransmitterData extends GT_Cover_AdvancedWirelessRedstoneBase.WirelessData {
+
protected boolean invert;
public TransmitterData(int frequency, UUID uuid, boolean invert) {
@@ -159,17 +156,14 @@ public abstract class GT_Cover_AdvancedRedstoneTransmitterBase<
protected void addUIWidgets(ModularWindow.Builder builder) {
super.addUIWidgets(builder);
builder.widget(TextWidget.dynamicString(() -> {
- T coverData = getCoverData();
- if (coverData != null) {
- return getCoverData().invert
- ? GT_Utility.trans("INVERTED", "Inverted")
- : GT_Utility.trans("NORMAL", "Normal");
- } else {
- return "";
- }
- })
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
+ T coverData = getCoverData();
+ if (coverData != null) {
+ return getCoverData().invert ? GT_Utility.trans("INVERTED", "Inverted")
+ : GT_Utility.trans("NORMAL", "Normal");
+ } else {
+ return "";
+ }
+ }).setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get())
.setPos(startX + spaceX * 10, 4 + startY + spaceY * getButtonRow()));
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterExternal.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterExternal.java
index aaa526e565..05c4105eb4 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterExternal.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterExternal.java
@@ -21,13 +21,8 @@ public class GT_Cover_AdvancedRedstoneTransmitterExternal
}
@Override
- public TransmitterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- TransmitterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ public TransmitterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ TransmitterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
byte outputRedstone = aInputRedstone;
if (aCoverVariable.isInvert()) {
if (outputRedstone > 0) outputRedstone = 0;
@@ -41,8 +36,8 @@ public class GT_Cover_AdvancedRedstoneTransmitterExternal
}
@Override
- public boolean letsRedstoneGoInImpl(
- byte aSide, int aCoverID, TransmitterData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoInImpl(byte aSide, int aCoverID, TransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterInternal.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterInternal.java
index 1d21b7060f..8cd288f8e2 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterInternal.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedRedstoneTransmitterInternal.java
@@ -21,13 +21,8 @@ public class GT_Cover_AdvancedRedstoneTransmitterInternal
}
@Override
- public TransmitterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- TransmitterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ public TransmitterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ TransmitterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
byte outputRedstone = aTileEntity.getOutputRedstoneSignal(aSide);
if (aCoverVariable.isInvert()) {
if (outputRedstone > 0) outputRedstone = 0;
@@ -40,14 +35,14 @@ public class GT_Cover_AdvancedRedstoneTransmitterInternal
}
@Override
- public boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, TransmitterData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, TransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, TransmitterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, TransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedWirelessRedstoneBase.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedWirelessRedstoneBase.java
index b62d086cb2..50302bade0 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedWirelessRedstoneBase.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_AdvancedWirelessRedstoneBase.java
@@ -1,9 +1,21 @@
package gregtech.common.covers.redstone;
+import java.util.Map;
+import java.util.UUID;
+import java.util.concurrent.ConcurrentHashMap;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.Fluid;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.GregTech_API;
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
@@ -15,17 +27,8 @@ import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.Map;
-import java.util.UUID;
-import java.util.concurrent.ConcurrentHashMap;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.Fluid;
-public abstract class GT_Cover_AdvancedWirelessRedstoneBase<
- T extends GT_Cover_AdvancedWirelessRedstoneBase.WirelessData>
+public abstract class GT_Cover_AdvancedWirelessRedstoneBase<T extends GT_Cover_AdvancedWirelessRedstoneBase.WirelessData>
extends GT_CoverBehaviorBase<T> {
public GT_Cover_AdvancedWirelessRedstoneBase(Class<T> typeToken, ITexture coverTexture) {
@@ -41,33 +44,17 @@ public abstract class GT_Cover_AdvancedWirelessRedstoneBase<
switch (mode) {
case AND:
- return (byte)
- (signals.values().stream()
- .map(signal -> signal > 0)
- .reduce(true, (signalA, signalB) -> signalA && signalB)
- ? 15
- : 0);
+ return (byte) (signals.values().stream().map(signal -> signal > 0)
+ .reduce(true, (signalA, signalB) -> signalA && signalB) ? 15 : 0);
case NAND:
- return (byte)
- (signals.values().stream()
- .map(signal -> signal > 0)
- .reduce(true, (signalA, signalB) -> signalA && signalB)
- ? 0
- : 15);
+ return (byte) (signals.values().stream().map(signal -> signal > 0)
+ .reduce(true, (signalA, signalB) -> signalA && signalB) ? 0 : 15);
case OR:
- return (byte)
- (signals.values().stream()
- .map(signal -> signal > 0)
- .reduce(false, (signalA, signalB) -> signalA || signalB)
- ? 15
- : 0);
+ return (byte) (signals.values().stream().map(signal -> signal > 0)
+ .reduce(false, (signalA, signalB) -> signalA || signalB) ? 15 : 0);
case NOR:
- return (byte)
- (signals.values().stream()
- .map(signal -> signal > 0)
- .reduce(false, (signalA, signalB) -> signalA || signalB)
- ? 0
- : 15);
+ return (byte) (signals.values().stream().map(signal -> signal > 0)
+ .reduce(false, (signalA, signalB) -> signalA || signalB) ? 0 : 15);
case SINGLE_SOURCE:
if (signals.values().isEmpty()) {
return 0;
@@ -89,24 +76,19 @@ public abstract class GT_Cover_AdvancedWirelessRedstoneBase<
}
public static void setSignalAt(UUID uuid, int frequency, long hash, byte value) {
- Map<Integer, Map<Long, Byte>> frequencies = GregTech_API.sAdvancedWirelessRedstone.computeIfAbsent(
- String.valueOf(uuid), k -> new ConcurrentHashMap<>());
+ Map<Integer, Map<Long, Byte>> frequencies = GregTech_API.sAdvancedWirelessRedstone
+ .computeIfAbsent(String.valueOf(uuid), k -> new ConcurrentHashMap<>());
Map<Long, Byte> signals = frequencies.computeIfAbsent(frequency, k -> new ConcurrentHashMap<>());
signals.put(hash, value);
}
/**
- * x hashed into first 20 bytes
- * y hashed into second 20 bytes
- * z hashed into fifth 10 bytes
- * dim hashed into sixth 10 bytes
- * side hashed into last 4 bytes
+ * x hashed into first 20 bytes y hashed into second 20 bytes z hashed into fifth 10 bytes dim hashed into sixth 10
+ * bytes side hashed into last 4 bytes
*/
public static long hashCoverCoords(ICoverable tile, byte side) {
return (((((long) tile.getXCoord() << 20) + tile.getZCoord() << 10) + tile.getYCoord() << 10)
- + tile.getWorld().provider.dimensionId
- << 4)
- + side;
+ + tile.getWorld().provider.dimensionId << 4) + side;
}
@Override
@@ -141,7 +123,8 @@ public abstract class GT_Cover_AdvancedWirelessRedstoneBase<
@Override
public String getDescriptionImpl(byte aSide, int aCoverID, T aCoverVariable, ICoverable aTileEntity) {
- return GT_Utility.trans("081", "Frequency: ") + aCoverVariable.frequency + ", Transmission: "
+ return GT_Utility.trans("081", "Frequency: ") + aCoverVariable.frequency
+ + ", Transmission: "
+ (aCoverVariable.uuid == null ? "Public" : "Private");
}
@@ -151,6 +134,7 @@ public abstract class GT_Cover_AdvancedWirelessRedstoneBase<
}
public abstract static class WirelessData implements ISerializableObject {
+
protected int frequency;
/**
@@ -247,40 +231,39 @@ public abstract class GT_Cover_AdvancedWirelessRedstoneBase<
final int privateExtraColumn = isShiftPrivateLeft() ? 1 : 5;
CoverDataControllerWidget<T> dataController = new CoverDataControllerWidget<>(
- this::getCoverData, this::setCoverData, GT_Cover_AdvancedWirelessRedstoneBase.this);
+ this::getCoverData,
+ this::setCoverData,
+ GT_Cover_AdvancedWirelessRedstoneBase.this);
dataController.setPos(startX, startY);
addUIForDataController(dataController);
builder.widget(dataController)
- .widget(new TextWidget(GT_Utility.trans("246", "Frequency"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5, 4 + startY + spaceY * getFrequencyRow()))
- .widget(new TextWidget(GT_Utility.trans("602", "Use Private Frequency"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * privateExtraColumn, 4 + startY + spaceY * getButtonRow()));
+ .widget(
+ new TextWidget(GT_Utility.trans("246", "Frequency")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5, 4 + startY + spaceY * getFrequencyRow()))
+ .widget(
+ new TextWidget(GT_Utility.trans("602", "Use Private Frequency"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get()).setPos(
+ startX + spaceX * privateExtraColumn,
+ 4 + startY + spaceY * getButtonRow()));
}
protected void addUIForDataController(CoverDataControllerWidget<T> controller) {
- controller
- .addFollower(
- new CoverDataFollower_TextFieldWidget<>(),
- coverData -> String.valueOf(coverData.frequency),
- (coverData, state) -> {
- coverData.frequency = (int) MathExpression.parseMathExpression(state);
- return coverData;
- },
- widget -> widget.setOnScrollNumbers()
- .setNumbers(0, Integer.MAX_VALUE)
- .setFocusOnGuiOpen(true)
- .setPos(1, 2 + spaceY * getFrequencyRow())
- .setSize(spaceX * 5 - 4, 12))
+ controller.addFollower(
+ new CoverDataFollower_TextFieldWidget<>(),
+ coverData -> String.valueOf(coverData.frequency),
+ (coverData, state) -> {
+ coverData.frequency = (int) MathExpression.parseMathExpression(state);
+ return coverData;
+ },
+ widget -> widget.setOnScrollNumbers().setNumbers(0, Integer.MAX_VALUE).setFocusOnGuiOpen(true)
+ .setPos(1, 2 + spaceY * getFrequencyRow()).setSize(spaceX * 5 - 4, 12))
.addFollower(
CoverDataFollower_ToggleButtonWidget.ofCheck(),
coverData -> coverData.uuid != null,
(coverData, state) -> {
if (state) {
- coverData.uuid =
- getUIBuildContext().getPlayer().getUniqueID();
+ coverData.uuid = getUIBuildContext().getPlayer().getUniqueID();
} else {
coverData.uuid = null;
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessFluidDetector.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessFluidDetector.java
index 67b931dd99..06388602c0 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessFluidDetector.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessFluidDetector.java
@@ -1,9 +1,18 @@
package gregtech.common.covers.redstone;
+import java.util.UUID;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -13,11 +22,6 @@ import gregtech.common.covers.GT_Cover_LiquidMeter;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import io.netty.buffer.ByteBuf;
-import java.util.UUID;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
public class GT_Cover_WirelessFluidDetector
extends GT_Cover_AdvancedRedstoneTransmitterBase<GT_Cover_WirelessFluidDetector.FluidTransmitterData> {
@@ -37,15 +41,10 @@ public class GT_Cover_WirelessFluidDetector
}
@Override
- public FluidTransmitterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- FluidTransmitterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
- byte signal = GT_Cover_LiquidMeter.computeSignalBasedOnFluid(
- aTileEntity, aCoverVariable.invert, aCoverVariable.threshold);
+ public FluidTransmitterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ FluidTransmitterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
+ byte signal = GT_Cover_LiquidMeter
+ .computeSignalBasedOnFluid(aTileEntity, aCoverVariable.invert, aCoverVariable.threshold);
long hash = hashCoverCoords(aTileEntity, aSide);
setSignalAt(aCoverVariable.getUuid(), aCoverVariable.getFrequency(), hash, signal);
@@ -53,18 +52,19 @@ public class GT_Cover_WirelessFluidDetector
}
@Override
- public boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, FluidTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, FluidTransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, FluidTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, FluidTransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
public static class FluidTransmitterData extends GT_Cover_AdvancedRedstoneTransmitterBase.TransmitterData {
+
/** The special value {@code 0} means threshold check is disabled. */
private int threshold;
@@ -143,9 +143,9 @@ public class GT_Cover_WirelessFluidDetector
@Override
protected void addUIWidgets(ModularWindow.Builder builder) {
super.addUIWidgets(builder);
- builder.widget(new TextWidget(GT_Utility.trans("222", "Fluid threshold"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5, 4 + startY));
+ builder.widget(
+ new TextWidget(GT_Utility.trans("222", "Fluid threshold")).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5, 4 + startY));
}
@Override
@@ -158,9 +158,7 @@ public class GT_Cover_WirelessFluidDetector
coverData.threshold = (int) MathExpression.parseMathExpression(state);
return coverData;
},
- widget -> widget.setOnScrollNumbers()
- .setNumbers(0, Integer.MAX_VALUE)
- .setPos(1, 2)
+ widget -> widget.setOnScrollNumbers().setNumbers(0, Integer.MAX_VALUE).setPos(1, 2)
.setSize(spaceX * 5 - 4, 12));
}
}
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessItemDetector.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessItemDetector.java
index 620f0bc35e..0b69150e86 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessItemDetector.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessItemDetector.java
@@ -1,5 +1,15 @@
package gregtech.common.covers.redstone;
+import java.util.UUID;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.forge.ItemStackHandler;
import com.gtnewhorizons.modularui.api.math.MathExpression;
@@ -7,6 +17,7 @@ import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.BaseTextFieldWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.ICoverable;
@@ -19,13 +30,6 @@ import gregtech.common.gui.modularui.widget.CoverDataFollower_TextFieldWidget;
import gregtech.common.gui.modularui.widget.ItemWatcherSlotWidget;
import gregtech.common.tileentities.storage.GT_MetaTileEntity_DigitalChestBase;
import io.netty.buffer.ByteBuf;
-import java.util.UUID;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
public class GT_Cover_WirelessItemDetector
extends GT_Cover_AdvancedRedstoneTransmitterBase<GT_Cover_WirelessItemDetector.ItemTransmitterData> {
@@ -45,15 +49,14 @@ public class GT_Cover_WirelessItemDetector
}
@Override
- public ItemTransmitterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- ItemTransmitterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ public ItemTransmitterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ ItemTransmitterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
byte signal = GT_Cover_ItemMeter.computeSignalBasedOnItems(
- aTileEntity, aCoverVariable.invert, aCoverVariable.threshold, aCoverVariable.slot, aSide);
+ aTileEntity,
+ aCoverVariable.invert,
+ aCoverVariable.threshold,
+ aCoverVariable.slot,
+ aSide);
long hash = hashCoverCoords(aTileEntity, aSide);
setSignalAt(aCoverVariable.getUuid(), aCoverVariable.getFrequency(), hash, signal);
@@ -61,18 +64,19 @@ public class GT_Cover_WirelessItemDetector
}
@Override
- public boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, ItemTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, ItemTransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, ItemTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID, ItemTransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
public static class ItemTransmitterData extends GT_Cover_AdvancedRedstoneTransmitterBase.TransmitterData {
+
/**
* The special value {@code -1} means all slots.
*/
@@ -169,32 +173,31 @@ public class GT_Cover_WirelessItemDetector
protected void addUIWidgets(ModularWindow.Builder builder) {
maxSlot = getMaxSlot();
super.addUIWidgets(builder);
- builder.widget(new ItemWatcherSlotWidget()
- .setGetter(this::getTargetItem)
+ builder.widget(
+ new ItemWatcherSlotWidget().setGetter(this::getTargetItem)
.setPos(startX + spaceX * 4 - 1, startY + spaceY * 3))
- .widget(new TextWidget(GT_Utility.trans("221", "Item threshold"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5, 4 + startY + spaceY * 2))
- .widget(new TextWidget(GT_Utility.trans("254.0", "Detect Slot"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * 5, 4 + startY + spaceY * 3));
+ .widget(
+ new TextWidget(GT_Utility.trans("221", "Item threshold"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5, 4 + startY + spaceY * 2))
+ .widget(
+ new TextWidget(GT_Utility.trans("254.0", "Detect Slot"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * 5, 4 + startY + spaceY * 3));
}
@Override
protected void addUIForDataController(CoverDataControllerWidget<ItemTransmitterData> controller) {
super.addUIForDataController(controller);
- controller
- .addFollower(
- new CoverDataFollower_TextFieldWidget<>(),
- coverData -> String.valueOf(coverData.threshold),
- (coverData, state) -> {
- coverData.threshold = (int) MathExpression.parseMathExpression(state);
- return coverData;
- },
- widget -> widget.setOnScrollNumbers(1, 10, 64)
- .setNumbers(() -> 0, this::getMaxItemCount)
- .setPos(1, 2 + spaceY * 2)
- .setSize(spaceX * 5 - 4, 12))
+ controller.addFollower(
+ new CoverDataFollower_TextFieldWidget<>(),
+ coverData -> String.valueOf(coverData.threshold),
+ (coverData, state) -> {
+ coverData.threshold = (int) MathExpression.parseMathExpression(state);
+ return coverData;
+ },
+ widget -> widget.setOnScrollNumbers(1, 10, 64).setNumbers(() -> 0, this::getMaxItemCount)
+ .setPos(1, 2 + spaceY * 2).setSize(spaceX * 5 - 4, 12))
.addFollower(
new CoverDataFollower_TextFieldWidget<>(),
coverData -> getSlotTextFieldContent(coverData.slot),
@@ -202,27 +205,23 @@ public class GT_Cover_WirelessItemDetector
coverData.slot = getIntFromText(state);
return coverData;
},
- widget -> widget.setOnScrollText()
- .setValidator(val -> {
- final int valSlot = getIntFromText(val);
- if (valSlot > -1) {
- return TextFieldWidget.format.format(Math.min(valSlot, maxSlot));
- } else {
- return ALL_TEXT;
- }
- })
- .setPattern(BaseTextFieldWidget.NATURAL_NUMS)
- .setPos(1, 2 + spaceY * 3)
+ widget -> widget.setOnScrollText().setValidator(val -> {
+ final int valSlot = getIntFromText(val);
+ if (valSlot > -1) {
+ return TextFieldWidget.format.format(Math.min(valSlot, maxSlot));
+ } else {
+ return ALL_TEXT;
+ }
+ }).setPattern(BaseTextFieldWidget.NATURAL_NUMS).setPos(1, 2 + spaceY * 3)
.setSize(spaceX * 4 - 8, 12));
}
private int getMaxSlot() {
final ICoverable tile = getUIBuildContext().getTile();
- if (tile instanceof TileEntity
- && !tile.isDead()
+ if (tile instanceof TileEntity && !tile.isDead()
&& tile instanceof IGregTechTileEntity
- && !(((IGregTechTileEntity) tile).getMetaTileEntity()
- instanceof GT_MetaTileEntity_DigitalChestBase)) {
+ && !(((IGregTechTileEntity) tile)
+ .getMetaTileEntity() instanceof GT_MetaTileEntity_DigitalChestBase)) {
return tile.getSizeInventory() - 1;
} else {
return -1;
@@ -248,8 +247,7 @@ public class GT_Cover_WirelessItemDetector
private ItemStack getTargetItem() {
final ICoverable tile = getUIBuildContext().getTile();
final ItemTransmitterData coverVariable = getCoverData();
- if (coverVariable != null
- && coverVariable.slot >= 0
+ if (coverVariable != null && coverVariable.slot >= 0
&& tile instanceof TileEntity
&& !tile.isDead()
&& tile.getSizeInventory() >= coverVariable.slot) {
diff --git a/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessMaintenanceDetector.java b/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessMaintenanceDetector.java
index 598e289c66..085a7e1f4d 100644
--- a/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessMaintenanceDetector.java
+++ b/src/main/java/gregtech/common/covers/redstone/GT_Cover_WirelessMaintenanceDetector.java
@@ -1,8 +1,18 @@
package gregtech.common.covers.redstone;
+import java.util.UUID;
+
+import javax.annotation.Nonnull;
+
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.google.common.io.ByteArrayDataInput;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_CoverUIBuildContext;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -16,16 +26,9 @@ import gregtech.common.covers.GT_Cover_NeedMaintainance;
import gregtech.common.gui.modularui.widget.CoverDataControllerWidget;
import gregtech.common.gui.modularui.widget.CoverDataFollower_ToggleButtonWidget;
import io.netty.buffer.ByteBuf;
-import java.util.UUID;
-import javax.annotation.Nonnull;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-public class GT_Cover_WirelessMaintenanceDetector
- extends GT_Cover_AdvancedRedstoneTransmitterBase<
- GT_Cover_WirelessMaintenanceDetector.MaintenanceTransmitterData> {
+public class GT_Cover_WirelessMaintenanceDetector extends
+ GT_Cover_AdvancedRedstoneTransmitterBase<GT_Cover_WirelessMaintenanceDetector.MaintenanceTransmitterData> {
public GT_Cover_WirelessMaintenanceDetector(ITexture coverTexture) {
super(MaintenanceTransmitterData.class, coverTexture);
@@ -41,8 +44,8 @@ public class GT_Cover_WirelessMaintenanceDetector
return createDataObject();
}
- private static byte computeSignalBasedOnMaintenance(
- MaintenanceTransmitterData coverVariable, ICoverable tileEntity) {
+ private static byte computeSignalBasedOnMaintenance(MaintenanceTransmitterData coverVariable,
+ ICoverable tileEntity) {
boolean signal = false;
if (tileEntity instanceof IGregTechTileEntity) {
@@ -73,9 +76,10 @@ public class GT_Cover_WirelessMaintenanceDetector
if (coverVariable.mode == MaintenanceMode.ROTOR_80) {
signal = current >= max * 8 / 10;
} else {
- long expectedDamage = Math.round(Math.min(
- (double) multiTE.mEUt / multiTE.damageFactorLow,
- Math.pow(multiTE.mEUt, multiTE.damageFactorHigh)));
+ long expectedDamage = Math.round(
+ Math.min(
+ (double) multiTE.mEUt / multiTE.damageFactorLow,
+ Math.pow(multiTE.mEUt, multiTE.damageFactorHigh)));
signal = current + expectedDamage * 2 >= max;
}
} else {
@@ -93,13 +97,8 @@ public class GT_Cover_WirelessMaintenanceDetector
}
@Override
- public MaintenanceTransmitterData doCoverThingsImpl(
- byte aSide,
- byte aInputRedstone,
- int aCoverID,
- MaintenanceTransmitterData aCoverVariable,
- ICoverable aTileEntity,
- long aTimer) {
+ public MaintenanceTransmitterData doCoverThingsImpl(byte aSide, byte aInputRedstone, int aCoverID,
+ MaintenanceTransmitterData aCoverVariable, ICoverable aTileEntity, long aTimer) {
byte signal = computeSignalBasedOnMaintenance(aCoverVariable, aTileEntity);
long hash = hashCoverCoords(aTileEntity, aSide);
setSignalAt(aCoverVariable.getUuid(), aCoverVariable.getFrequency(), hash, signal);
@@ -108,20 +107,20 @@ public class GT_Cover_WirelessMaintenanceDetector
}
@Override
- public boolean letsRedstoneGoOutImpl(
- byte aSide, int aCoverID, MaintenanceTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ public boolean letsRedstoneGoOutImpl(byte aSide, int aCoverID, MaintenanceTransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return true;
}
@Override
- protected boolean manipulatesSidedRedstoneOutputImpl(
- byte aSide, int aCoverID, MaintenanceTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ protected boolean manipulatesSidedRedstoneOutputImpl(byte aSide, int aCoverID,
+ MaintenanceTransmitterData aCoverVariable, ICoverable aTileEntity) {
return true;
}
@Override
- public int getTickRateImpl(
- byte aSide, int aCoverID, MaintenanceTransmitterData aCoverVariable, ICoverable aTileEntity) {
+ public int getTickRateImpl(byte aSide, int aCoverID, MaintenanceTransmitterData aCoverVariable,
+ ICoverable aTileEntity) {
return 60;
}
@@ -137,6 +136,7 @@ public class GT_Cover_WirelessMaintenanceDetector
}
public static class MaintenanceTransmitterData extends GT_Cover_AdvancedRedstoneTransmitterBase.TransmitterData {
+
private MaintenanceMode mode;
public MaintenanceTransmitterData(int frequency, UUID uuid, boolean invert, MaintenanceMode mode) {
@@ -190,10 +190,8 @@ public class GT_Cover_WirelessMaintenanceDetector
// GUI stuff
- private static final String[] extraTexts = new String[] {
- "No Issues", ">= 1 Issue", ">= 2 Issues", ">= 3 Issues",
- ">= 4 Issues", ">= 5 Issues", "Rotor < 80%", "Rotor < 100%"
- };
+ private static final String[] extraTexts = new String[] { "No Issues", ">= 1 Issue", ">= 2 Issues", ">= 3 Issues",
+ ">= 4 Issues", ">= 5 Issues", "Rotor < 80%", "Rotor < 100%" };
@Override
public ModularWindow createWindow(GT_CoverUIBuildContext buildContext) {
@@ -225,9 +223,9 @@ public class GT_Cover_WirelessMaintenanceDetector
protected void addUIWidgets(ModularWindow.Builder builder) {
super.addUIWidgets(builder);
for (int i = 0; i < 8; i++) {
- builder.widget(new TextWidget(extraTexts[i])
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(startX + spaceX * (i % 2 == 0 ? 1 : 7), 4 + startY + spaceY * (2 + i / 2)));
+ builder.widget(
+ new TextWidget(extraTexts[i]).setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(startX + spaceX * (i % 2 == 0 ? 1 : 7), 4 + startY + spaceY * (2 + i / 2)));
}
}
@@ -243,8 +241,8 @@ public class GT_Cover_WirelessMaintenanceDetector
coverData.mode = MaintenanceMode.values()[index];
return coverData;
},
- widget -> widget.setToggleTexture(
- GT_UITextures.OVERLAY_BUTTON_CHECKMARK, GT_UITextures.TRANSPARENT)
+ widget -> widget
+ .setToggleTexture(GT_UITextures.OVERLAY_BUTTON_CHECKMARK, GT_UITextures.TRANSPARENT)
.setPos(spaceX * (index % 2 == 0 ? 0 : 6), spaceY * (2 + index / 2)));
}
}
diff --git a/src/main/java/gregtech/common/entities/GT_EntityFXPollution.java b/src/main/java/gregtech/common/entities/GT_EntityFXPollution.java
index 5cb81ab20d..219cafdaf1 100644
--- a/src/main/java/gregtech/common/entities/GT_EntityFXPollution.java
+++ b/src/main/java/gregtech/common/entities/GT_EntityFXPollution.java
@@ -1,6 +1,7 @@
package gregtech.common.entities;
import java.util.Random;
+
import net.minecraft.client.particle.EntityFX;
import net.minecraft.world.World;
diff --git a/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java b/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java
index 028b3199f7..5afd1b3b47 100644
--- a/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java
+++ b/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java
@@ -1,13 +1,8 @@
package gregtech.common.entities;
-import com.mojang.authlib.GameProfile;
-import gregtech.api.enums.ParticleFX;
-import gregtech.api.objects.ItemData;
-import gregtech.api.util.GT_OreDictUnificator;
-import gregtech.api.util.GT_Utility;
-import gregtech.api.util.WorldSpawnedEventBuilder;
import java.util.List;
import java.util.UUID;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.enchantment.Enchantment;
@@ -30,7 +25,16 @@ import net.minecraft.world.World;
import net.minecraft.world.WorldServer;
import net.minecraftforge.common.util.FakePlayerFactory;
+import com.mojang.authlib.GameProfile;
+
+import gregtech.api.enums.ParticleFX;
+import gregtech.api.objects.ItemData;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.api.util.GT_Utility;
+import gregtech.api.util.WorldSpawnedEventBuilder;
+
public class GT_Entity_Arrow extends EntityArrow {
+
private int mHitBlockX = -1;
private int mHitBlockY = -1;
private int mHitBlockZ = -1;
@@ -72,10 +76,10 @@ public class GT_Entity_Arrow extends EntityArrow {
Entity tShootingEntity = this.shootingEntity;
if ((this.prevRotationPitch == 0.0F) && (this.prevRotationYaw == 0.0F)) {
float f = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
- this.prevRotationYaw =
- (this.rotationYaw = (float) (Math.atan2(this.motionX, this.motionZ) * 180.0D / 3.141592653589793D));
- this.prevRotationPitch =
- (this.rotationPitch = (float) (Math.atan2(this.motionY, f) * 180.0D / 3.141592653589793D));
+ this.prevRotationYaw = (this.rotationYaw = (float) (Math.atan2(this.motionX, this.motionZ) * 180.0D
+ / 3.141592653589793D));
+ this.prevRotationPitch = (this.rotationPitch = (float) (Math.atan2(this.motionY, f) * 180.0D
+ / 3.141592653589793D));
}
if (this.mTicksAlive++ == 3000) {
setDead();
@@ -83,8 +87,8 @@ public class GT_Entity_Arrow extends EntityArrow {
Block tBlock = this.worldObj.getBlock(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
if (tBlock.getMaterial() != Material.air) {
tBlock.setBlockBoundsBasedOnState(this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
- AxisAlignedBB axisalignedbb = tBlock.getCollisionBoundingBoxFromPool(
- this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
+ AxisAlignedBB axisalignedbb = tBlock
+ .getCollisionBoundingBoxFromPool(this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
if ((axisalignedbb != null)
&& (axisalignedbb.isVecInside(Vec3.createVectorHelper(this.posX, this.posY, this.posZ)))) {
this.inGround = true;
@@ -106,21 +110,19 @@ public class GT_Entity_Arrow extends EntityArrow {
} else {
this.ticksInAir += 1;
Vec3 vec31 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
- Vec3 vec3 = Vec3.createVectorHelper(
- this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
+ Vec3 vec3 = Vec3
+ .createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
MovingObjectPosition tVector = this.worldObj.func_147447_a(vec31, vec3, false, true, false);
vec31 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ);
- vec3 = Vec3.createVectorHelper(
- this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
+ vec3 = Vec3
+ .createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ);
if (tVector != null) {
vec3 = Vec3.createVectorHelper(tVector.hitVec.xCoord, tVector.hitVec.yCoord, tVector.hitVec.zCoord);
}
Entity tHitEntity = null;
List tAllPotentiallyHitEntities = this.worldObj.getEntitiesWithinAABBExcludingEntity(
this,
- this.boundingBox
- .addCoord(this.motionX, this.motionY, this.motionZ)
- .expand(1.0D, 1.0D, 1.0D));
+ this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ).expand(1.0D, 1.0D, 1.0D));
double tLargestDistance = 1.7976931348623157E+308D;
for (int i = 0; i < tAllPotentiallyHitEntities.size(); i++) {
Entity entity1 = (Entity) tAllPotentiallyHitEntities.get(i);
@@ -141,9 +143,8 @@ public class GT_Entity_Arrow extends EntityArrow {
}
if ((tVector != null) && ((tVector.entityHit instanceof EntityPlayer))) {
EntityPlayer entityplayer = (EntityPlayer) tVector.entityHit;
- if ((entityplayer.capabilities.disableDamage)
- || (((tShootingEntity instanceof EntityPlayer))
- && (!((EntityPlayer) tShootingEntity).canAttackPlayer(entityplayer)))) {
+ if ((entityplayer.capabilities.disableDamage) || (((tShootingEntity instanceof EntityPlayer))
+ && (!((EntityPlayer) tShootingEntity).canAttackPlayer(entityplayer)))) {
tVector = null;
}
}
@@ -151,19 +152,17 @@ public class GT_Entity_Arrow extends EntityArrow {
if (tVector.entityHit != null) {
ItemData tData = GT_OreDictUnificator.getItemData(this.mArrow);
- float tMagicDamage = (tVector.entityHit instanceof EntityLivingBase)
- ? EnchantmentHelper.func_152377_a(
- this.mArrow, ((EntityLivingBase) tVector.entityHit).getCreatureAttribute())
+ float tMagicDamage = (tVector.entityHit instanceof EntityLivingBase) ? EnchantmentHelper
+ .func_152377_a(this.mArrow, ((EntityLivingBase) tVector.entityHit).getCreatureAttribute())
: 0.0F;
- float tDamage = MathHelper.ceiling_double_int(MathHelper.sqrt_double(this.motionX * this.motionX
- + this.motionY * this.motionY
- + this.motionZ * this.motionZ)
- * (getDamage()
- + ((tData != null)
- && (tData.mMaterial != null)
- && (tData.mMaterial.mMaterial != null)
- ? tData.mMaterial.mMaterial.mToolQuality / 2.0F - 1.0F
- : 0.0F)));
+ float tDamage = MathHelper.ceiling_double_int(
+ MathHelper.sqrt_double(
+ this.motionX * this.motionX + this.motionY * this.motionY
+ + this.motionZ * this.motionZ)
+ * (getDamage() + ((tData != null) && (tData.mMaterial != null)
+ && (tData.mMaterial.mMaterial != null)
+ ? tData.mMaterial.mMaterial.mToolQuality / 2.0F - 1.0F
+ : 0.0F)));
if (getIsCritical()) {
tDamage += this.rand.nextInt((int) (tDamage / 2.0D + 2.0D));
}
@@ -211,28 +210,26 @@ public class GT_Entity_Arrow extends EntityArrow {
tPlayer.setDead();
}
}
- DamageSource tDamageSource =
- DamageSource.causeArrowDamage(this, tShootingEntity == null ? this : tShootingEntity);
+ DamageSource tDamageSource = DamageSource
+ .causeArrowDamage(this, tShootingEntity == null ? this : tShootingEntity);
if ((tDamage + tMagicDamage > 0.0F)
&& (tVector.entityHit.attackEntityFrom(tDamageSource, tDamage + tMagicDamage))) {
if ((tVector.entityHit instanceof EntityLivingBase)) {
if (tHitTimer >= 0) {
tVector.entityHit.hurtResistantTime = tHitTimer;
}
- if (((tVector.entityHit instanceof EntityCreeper))
- && (EnchantmentHelper.getEnchantmentLevel(
- Enchantment.fireAspect.effectId, this.mArrow)
- > 0)) {
+ if (((tVector.entityHit instanceof EntityCreeper)) && (EnchantmentHelper
+ .getEnchantmentLevel(Enchantment.fireAspect.effectId, this.mArrow) > 0)) {
((EntityCreeper) tVector.entityHit).func_146079_cb();
}
EntityLivingBase tHitLivingEntity = (EntityLivingBase) tVector.entityHit;
if (!this.worldObj.isRemote) {
- tHitLivingEntity.setArrowCountInEntity(
- tHitLivingEntity.getArrowCountInEntity() + 1);
+ tHitLivingEntity
+ .setArrowCountInEntity(tHitLivingEntity.getArrowCountInEntity() + 1);
}
if (tKnockback > 0) {
- float tKnockbackDivider = MathHelper.sqrt_double(
- this.motionX * this.motionX + this.motionZ * this.motionZ);
+ float tKnockbackDivider = MathHelper
+ .sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ);
if (tKnockbackDivider > 0.0F) {
tHitLivingEntity.addVelocity(
this.motionX * tKnockback * 0.6000000238418579D / tKnockbackDivider,
@@ -250,12 +247,11 @@ public class GT_Entity_Arrow extends EntityArrow {
: null,
tHitLivingEntity,
this.mArrow);
- if ((tShootingEntity != null)
- && (tHitLivingEntity != tShootingEntity)
+ if ((tShootingEntity != null) && (tHitLivingEntity != tShootingEntity)
&& ((tHitLivingEntity instanceof EntityPlayer))
&& ((tShootingEntity instanceof EntityPlayerMP))) {
- ((EntityPlayerMP) tShootingEntity)
- .playerNetServerHandler.sendPacket(new S2BPacketChangeGameState(6, 0.0F));
+ ((EntityPlayerMP) tShootingEntity).playerNetServerHandler
+ .sendPacket(new S2BPacketChangeGameState(6, 0.0F));
}
}
if (((tShootingEntity instanceof EntityPlayer)) && (tMagicDamage > 0.0F)) {
@@ -284,8 +280,8 @@ public class GT_Entity_Arrow extends EntityArrow {
this.mHitBlockY = tVector.blockY;
this.mHitBlockZ = tVector.blockZ;
this.mHitBlock = this.worldObj.getBlock(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
- this.mHitBlockMeta =
- this.worldObj.getBlockMetadata(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
+ this.mHitBlockMeta = this.worldObj
+ .getBlockMetadata(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ);
this.motionX = ((float) (tVector.hitVec.xCoord - this.posX));
this.motionY = ((float) (tVector.hitVec.yCoord - this.posY));
this.motionZ = ((float) (tVector.hitVec.zCoord - this.posZ));
@@ -300,30 +296,41 @@ public class GT_Entity_Arrow extends EntityArrow {
setIsCritical(false);
if (this.mHitBlock.getMaterial() != Material.air) {
this.mHitBlock.onEntityCollidedWithBlock(
- this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ, this);
+ this.worldObj,
+ this.mHitBlockX,
+ this.mHitBlockY,
+ this.mHitBlockZ,
+ this);
}
if ((!this.worldObj.isRemote)
&& (EnchantmentHelper.getEnchantmentLevel(Enchantment.fireAspect.effectId, this.mArrow)
> 2)) {
GT_Utility.setCoordsOnFire(
- this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ, true);
+ this.worldObj,
+ this.mHitBlockX,
+ this.mHitBlockY,
+ this.mHitBlockZ,
+ true);
}
if (breaksOnImpact()) {
setDead();
}
}
}
- WorldSpawnedEventBuilder.ParticleEventBuilder events =
- new WorldSpawnedEventBuilder.ParticleEventBuilder().setWorld(this.worldObj);
+ WorldSpawnedEventBuilder.ParticleEventBuilder events = new WorldSpawnedEventBuilder.ParticleEventBuilder()
+ .setWorld(this.worldObj);
if (getIsCritical()) {
events.setIdentifier(ParticleFX.CRIT)
- .setMotion(-this.motionX, -this.motionY + 0.2D, -this.motionZ)
- .<WorldSpawnedEventBuilder.ParticleEventBuilder>times(4, (x, i) -> x.setPosition(
- this.posX + this.motionX * i / 4.0D,
- this.posY + this.motionY * i / 4.0D,
- this.posZ + this.motionZ * i / 4.0D)
- .run());
+ .setMotion(
+ -this.motionX,
+ -this.motionY + 0.2D,
+ -this.motionZ).<WorldSpawnedEventBuilder.ParticleEventBuilder>times(
+ 4,
+ (x, i) -> x.setPosition(
+ this.posX + this.motionX * i / 4.0D,
+ this.posY + this.motionY * i / 4.0D,
+ this.posZ + this.motionZ * i / 4.0D).run());
}
this.posX += this.motionX;
this.posY += this.motionY;
@@ -331,12 +338,10 @@ public class GT_Entity_Arrow extends EntityArrow {
this.rotationYaw = ((float) (Math.atan2(this.motionX, this.motionZ) * 180.0D / 3.141592653589793D));
for (this.rotationPitch = ((float) (Math.atan2(
- this.motionY,
- MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ))
- * 180.0D
- / 3.141592653589793D));
- this.rotationPitch - this.prevRotationPitch < -180.0F;
- this.prevRotationPitch -= 360.0F) {}
+ this.motionY,
+ MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ)) * 180.0D
+ / 3.141592653589793D)); this.rotationPitch - this.prevRotationPitch
+ < -180.0F; this.prevRotationPitch -= 360.0F) {}
while (this.rotationPitch - this.prevRotationPitch >= 180.0F) {
this.prevRotationPitch += 360.0F;
}
@@ -350,8 +355,7 @@ public class GT_Entity_Arrow extends EntityArrow {
this.rotationYaw = (this.prevRotationYaw + (this.rotationYaw - this.prevRotationYaw) * 0.2F);
float tFrictionMultiplier = 0.99F;
if (isInWater()) {
- events.setMotion(-this.motionX, -this.motionY + 0.2D, -this.motionZ)
- .setIdentifier(ParticleFX.BUBBLE)
+ events.setMotion(-this.motionX, -this.motionY + 0.2D, -this.motionZ).setIdentifier(ParticleFX.BUBBLE)
.setPosition(
this.posX - this.motionX * 0.25D,
this.posY - this.motionY * 0.25D,
@@ -405,8 +409,7 @@ public class GT_Entity_Arrow extends EntityArrow {
@Override
public void onCollideWithPlayer(EntityPlayer aPlayer) {
- if ((!this.worldObj.isRemote)
- && (this.inGround)
+ if ((!this.worldObj.isRemote) && (this.inGround)
&& (this.arrowShake <= 0)
&& (this.canBePickedUp == 1)
&& (aPlayer.inventory.addItemStackToInventory(getArrowItem()))) {
@@ -416,16 +419,9 @@ public class GT_Entity_Arrow extends EntityArrow {
}
}
- public int[] onHitEntity(
- Entity aHitEntity,
- Entity aShootingEntity,
- ItemStack aArrow,
- int aRegularDamage,
- int aMagicDamage,
- int aKnockback,
- int aFireDamage,
- int aHitTimer) {
- return new int[] {aRegularDamage, aMagicDamage, aKnockback, aFireDamage, aHitTimer};
+ public int[] onHitEntity(Entity aHitEntity, Entity aShootingEntity, ItemStack aArrow, int aRegularDamage,
+ int aMagicDamage, int aKnockback, int aFireDamage, int aHitTimer) {
+ return new int[] { aRegularDamage, aMagicDamage, aKnockback, aFireDamage, aHitTimer };
}
public ItemStack getArrowItem() {
diff --git a/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java b/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java
index ec98099ba8..e44129d245 100644
--- a/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java
+++ b/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java
@@ -8,6 +8,7 @@ import net.minecraft.potion.PotionEffect;
import net.minecraft.world.World;
public class GT_Entity_Arrow_Potion extends GT_Entity_Arrow {
+
private int[] mPotions = new int[0];
public GT_Entity_Arrow_Potion(World aWorld) {
@@ -50,25 +51,28 @@ public class GT_Entity_Arrow_Potion extends GT_Entity_Arrow {
}
@Override
- public int[] onHitEntity(
- Entity aHitEntity,
- Entity aShootingEntity,
- ItemStack aArrow,
- int aRegularDamage,
- int aMagicDamage,
- int aKnockback,
- int aFireDamage,
- int aHitTimer) {
+ public int[] onHitEntity(Entity aHitEntity, Entity aShootingEntity, ItemStack aArrow, int aRegularDamage,
+ int aMagicDamage, int aKnockback, int aFireDamage, int aHitTimer) {
if ((aHitEntity instanceof EntityLivingBase)) {
for (int i = 3; i < this.mPotions.length; i += 4) {
if (aHitEntity.worldObj.rand.nextInt(100) < this.mPotions[i]) {
- ((EntityLivingBase) aHitEntity)
- .addPotionEffect(new PotionEffect(
- this.mPotions[(i - 3)], this.mPotions[(i - 2)], this.mPotions[(i - 1)], false));
+ ((EntityLivingBase) aHitEntity).addPotionEffect(
+ new PotionEffect(
+ this.mPotions[(i - 3)],
+ this.mPotions[(i - 2)],
+ this.mPotions[(i - 1)],
+ false));
}
}
}
return super.onHitEntity(
- aHitEntity, aShootingEntity, aArrow, 1, aMagicDamage, aKnockback, aFireDamage, aHitTimer);
+ aHitEntity,
+ aShootingEntity,
+ aArrow,
+ 1,
+ aMagicDamage,
+ aKnockback,
+ aFireDamage,
+ aHitTimer);
}
}
diff --git a/src/main/java/gregtech/common/fluid/GT_Fluid.java b/src/main/java/gregtech/common/fluid/GT_Fluid.java
index 10caccbcd0..e4503f95ea 100644
--- a/src/main/java/gregtech/common/fluid/GT_Fluid.java
+++ b/src/main/java/gregtech/common/fluid/GT_Fluid.java
@@ -1,5 +1,14 @@
package gregtech.common.fluid;
+import javax.annotation.Nonnull;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.ResourceLocation;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidContainerRegistry;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.FluidState;
import gregtech.api.enums.GT_Values;
@@ -8,15 +17,9 @@ import gregtech.api.interfaces.fluid.IGT_Fluid;
import gregtech.api.interfaces.fluid.IGT_RegisteredFluid;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_Utility;
-import javax.annotation.Nonnull;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ResourceLocation;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidContainerRegistry;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
public class GT_Fluid extends Fluid implements IGT_Fluid, IGT_RegisteredFluid, Runnable {
+
private final String localizedName;
private final ResourceLocation stillIconResourceLocation;
private final ResourceLocation flowingIconResourceLocation;
@@ -79,8 +82,7 @@ public class GT_Fluid extends Fluid implements IGT_Fluid, IGT_RegisteredFluid, R
*/
@Override
public int getColor() {
- return (Math.max(0, Math.min(255, colorRGBA[0])) << 16)
- | (Math.max(0, Math.min(255, colorRGBA[1])) << 8)
+ return (Math.max(0, Math.min(255, colorRGBA[0])) << 16) | (Math.max(0, Math.min(255, colorRGBA[1])) << 8)
| Math.max(0, Math.min(255, colorRGBA[2]));
}
@@ -111,13 +113,16 @@ public class GT_Fluid extends Fluid implements IGT_Fluid, IGT_RegisteredFluid, R
* @inheritDoc
*/
@Override
- public IGT_RegisteredFluid registerContainers(
- final ItemStack fullContainer, final ItemStack emptyContainer, final int containerSize) {
+ public IGT_RegisteredFluid registerContainers(final ItemStack fullContainer, final ItemStack emptyContainer,
+ final int containerSize) {
if (fullContainer != null && emptyContainer != null) {
final FluidStack fluidStack = new FluidStack(registeredFluid, containerSize);
if (!FluidContainerRegistry.registerFluidContainer(fluidStack, fullContainer, emptyContainer)) {
GT_Values.RA.addFluidCannerRecipe(
- fullContainer, GT_Utility.getContainerItem(fullContainer, false), null, fluidStack);
+ fullContainer,
+ GT_Utility.getContainerItem(fullContainer, false),
+ null,
+ fluidStack);
}
}
return this;
@@ -179,8 +184,8 @@ public class GT_Fluid extends Fluid implements IGT_Fluid, IGT_RegisteredFluid, R
// ----- Runnable interface implementations -----
/**
- * This {@link Runnable#run()} implementation is scheduled within the {@link GregTech_API#sGTBlockIconload}
- * to load this {@link IGT_Fluid}'s texture icons.
+ * This {@link Runnable#run()} implementation is scheduled within the {@link GregTech_API#sGTBlockIconload} to load
+ * this {@link IGT_Fluid}'s texture icons.
*
* @see Runnable#run()
*/
diff --git a/src/main/java/gregtech/common/fluid/GT_FluidBuilder.java b/src/main/java/gregtech/common/fluid/GT_FluidBuilder.java
index 48d4e0e95e..f3effb0c99 100644
--- a/src/main/java/gregtech/common/fluid/GT_FluidBuilder.java
+++ b/src/main/java/gregtech/common/fluid/GT_FluidBuilder.java
@@ -2,19 +2,23 @@ package gregtech.common.fluid;
import static gregtech.api.enums.GT_Values.MOD_ID;
-import gregtech.api.enums.Dyes;
-import gregtech.api.enums.FluidState;
-import gregtech.api.interfaces.fluid.IGT_Fluid;
-import gregtech.api.interfaces.fluid.IGT_FluidBuilder;
-import gregtech.api.interfaces.fluid.IGT_RegisteredFluid;
import java.util.Locale;
+
import javax.annotation.Nonnull;
+
import net.minecraft.block.Block;
import net.minecraft.util.IIcon;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.fluids.Fluid;
+import gregtech.api.enums.Dyes;
+import gregtech.api.enums.FluidState;
+import gregtech.api.interfaces.fluid.IGT_Fluid;
+import gregtech.api.interfaces.fluid.IGT_FluidBuilder;
+import gregtech.api.interfaces.fluid.IGT_RegisteredFluid;
+
public class GT_FluidBuilder implements IGT_FluidBuilder {
+
final String fluidName;
String localizedName;
ResourceLocation stillIconResourceLocation = null, flowingIconResourceLocation = null;
@@ -108,8 +112,8 @@ public class GT_FluidBuilder implements IGT_FluidBuilder {
* @inheritDoc
*/
@Override
- public IGT_FluidBuilder withTextures(
- final ResourceLocation stillIconResourceLocation, final ResourceLocation flowingIconResourceLocation) {
+ public IGT_FluidBuilder withTextures(final ResourceLocation stillIconResourceLocation,
+ final ResourceLocation flowingIconResourceLocation) {
this.stillIconResourceLocation = stillIconResourceLocation;
this.flowingIconResourceLocation = flowingIconResourceLocation;
return this;
diff --git a/src/main/java/gregtech/common/gui/modularui/UIHelper.java b/src/main/java/gregtech/common/gui/modularui/UIHelper.java
index 42d704bbf4..8973992c28 100644
--- a/src/main/java/gregtech/common/gui/modularui/UIHelper.java
+++ b/src/main/java/gregtech/common/gui/modularui/UIHelper.java
@@ -1,38 +1,30 @@
package gregtech.common.gui.modularui;
-import com.gtnewhorizons.modularui.api.drawable.IDrawable;
-import com.gtnewhorizons.modularui.api.math.Pos2d;
-import gregtech.api.enums.SteamVariant;
-import gregtech.api.gui.modularui.SteamTexture;
-import gregtech.api.util.GT_Recipe;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.stream.Collectors;
+
import javax.annotation.Nullable;
+import com.gtnewhorizons.modularui.api.drawable.IDrawable;
+import com.gtnewhorizons.modularui.api.math.Pos2d;
+
+import gregtech.api.enums.SteamVariant;
+import gregtech.api.gui.modularui.SteamTexture;
+import gregtech.api.util.GT_Recipe;
+
public class UIHelper {
/**
* Iterates over candidates for slot placement.
*/
- public static void forEachSlots(
- ForEachSlot forEachItemInputSlot,
- ForEachSlot forEachItemOutputSlot,
- ForEachSlot forEachSpecialSlot,
- ForEachSlot forEachFluidInputSlot,
- ForEachSlot forEachFluidOutputSlot,
- IDrawable itemSlotBackground,
- IDrawable fluidSlotBackground,
- @Nullable GT_Recipe.GT_Recipe_Map recipeMap,
- int itemInputCount,
- int itemOutputCount,
- int fluidInputCount,
- int fluidOutputCount,
- SteamVariant steamVariant,
- Pos2d offset) {
- List<Pos2d> itemInputPositions = recipeMap != null
- ? recipeMap.getItemInputPositions(itemInputCount)
+ public static void forEachSlots(ForEachSlot forEachItemInputSlot, ForEachSlot forEachItemOutputSlot,
+ ForEachSlot forEachSpecialSlot, ForEachSlot forEachFluidInputSlot, ForEachSlot forEachFluidOutputSlot,
+ IDrawable itemSlotBackground, IDrawable fluidSlotBackground, @Nullable GT_Recipe.GT_Recipe_Map recipeMap,
+ int itemInputCount, int itemOutputCount, int fluidInputCount, int fluidOutputCount,
+ SteamVariant steamVariant, Pos2d offset) {
+ List<Pos2d> itemInputPositions = recipeMap != null ? recipeMap.getItemInputPositions(itemInputCount)
: UIHelper.getItemInputPositions(itemInputCount);
itemInputPositions = itemInputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
for (int i = 0; i < itemInputPositions.size(); i++) {
@@ -42,11 +34,9 @@ public class UIHelper {
itemInputPositions.get(i));
}
- List<Pos2d> itemOutputPositions = recipeMap != null
- ? recipeMap.getItemOutputPositions(itemOutputCount)
+ List<Pos2d> itemOutputPositions = recipeMap != null ? recipeMap.getItemOutputPositions(itemOutputCount)
: UIHelper.getItemOutputPositions(itemOutputCount);
- itemOutputPositions =
- itemOutputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
+ itemOutputPositions = itemOutputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
for (int i = 0; i < itemOutputPositions.size(); i++) {
forEachItemOutputSlot.accept(
i,
@@ -60,11 +50,9 @@ public class UIHelper {
(recipeMap != null ? recipeMap.getSpecialItemPosition() : UIHelper.getSpecialItemPosition())
.add(offset));
- List<Pos2d> fluidInputPositions = recipeMap != null
- ? recipeMap.getFluidInputPositions(fluidInputCount)
+ List<Pos2d> fluidInputPositions = recipeMap != null ? recipeMap.getFluidInputPositions(fluidInputCount)
: UIHelper.getFluidInputPositions(fluidInputCount);
- fluidInputPositions =
- fluidInputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
+ fluidInputPositions = fluidInputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
for (int i = 0; i < fluidInputPositions.size(); i++) {
forEachFluidInputSlot.accept(
i,
@@ -72,11 +60,9 @@ public class UIHelper {
fluidInputPositions.get(i));
}
- List<Pos2d> fluidOutputPositions = recipeMap != null
- ? recipeMap.getFluidOutputPositions(fluidOutputCount)
+ List<Pos2d> fluidOutputPositions = recipeMap != null ? recipeMap.getFluidOutputPositions(fluidOutputCount)
: UIHelper.getFluidOutputPositions(fluidOutputCount);
- fluidOutputPositions =
- fluidOutputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
+ fluidOutputPositions = fluidOutputPositions.stream().map(p -> p.add(offset)).collect(Collectors.toList());
for (int i = 0; i < fluidOutputPositions.size(); i++) {
forEachFluidOutputSlot.accept(
i,
@@ -164,16 +150,15 @@ public class UIHelper {
return results;
}
- public static List<Pos2d> getGridPositions(
- int totalCount, int xOrigin, int yOrigin, int xDirMaxCount, int yDirMaxCount) {
+ public static List<Pos2d> getGridPositions(int totalCount, int xOrigin, int yOrigin, int xDirMaxCount,
+ int yDirMaxCount) {
// 18 pixels to get to a new grid for placing an item tile since they are 16x16 and have 1 pixel buffers
// around them.
int distance = 18;
List<Pos2d> results = new ArrayList<>();
int count = 0;
- loop:
- for (int j = 0; j < yDirMaxCount; j++) {
+ loop: for (int j = 0; j < yDirMaxCount; j++) {
for (int i = 0; i < xDirMaxCount; i++) {
if (count >= totalCount) break loop;
results.add(new Pos2d(xOrigin + i * distance, yOrigin + j * distance));
@@ -191,19 +176,13 @@ public class UIHelper {
* @deprecated Renamed to {@link #getGridPositions}
*/
@Deprecated
- public static List<Pos2d> getItemGridPositions(
- int itemCount, int xOrigin, int yOrigin, int xDirMaxCount, int yDirMaxCount) {
+ public static List<Pos2d> getItemGridPositions(int itemCount, int xOrigin, int yOrigin, int xDirMaxCount,
+ int yDirMaxCount) {
return getGridPositions(itemCount, xOrigin, yOrigin, xDirMaxCount, yDirMaxCount);
}
- private static IDrawable[] getBackgroundsForSlot(
- IDrawable base,
- GT_Recipe.GT_Recipe_Map recipeMap,
- boolean isFluid,
- boolean isOutput,
- int index,
- boolean isSpecial,
- SteamVariant steamVariant) {
+ private static IDrawable[] getBackgroundsForSlot(IDrawable base, GT_Recipe.GT_Recipe_Map recipeMap, boolean isFluid,
+ boolean isOutput, int index, boolean isSpecial, SteamVariant steamVariant) {
if (recipeMap != null) {
IDrawable overlay;
if (steamVariant != SteamVariant.NONE) {
@@ -217,14 +196,15 @@ public class UIHelper {
overlay = recipeMap.getOverlayForSlot(isFluid, isOutput, index, isSpecial);
}
if (overlay != null) {
- return new IDrawable[] {base, overlay};
+ return new IDrawable[] { base, overlay };
}
}
- return new IDrawable[] {base};
+ return new IDrawable[] { base };
}
@FunctionalInterface
public interface ForEachSlot {
+
void accept(int index, IDrawable[] backgrounds, Pos2d pos);
}
}
diff --git a/src/main/java/gregtech/common/gui/modularui/uifactory/SelectItemUIFactory.java b/src/main/java/gregtech/common/gui/modularui/uifactory/SelectItemUIFactory.java
index c3161b3f5e..00cfcf9d6d 100644
--- a/src/main/java/gregtech/common/gui/modularui/uifactory/SelectItemUIFactory.java
+++ b/src/main/java/gregtech/common/gui/modularui/uifactory/SelectItemUIFactory.java
@@ -1,5 +1,15 @@
package gregtech.common.gui.modularui.uifactory;
+import java.util.List;
+import java.util.concurrent.atomic.AtomicBoolean;
+import java.util.function.Consumer;
+import java.util.function.Supplier;
+
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.gui.FontRenderer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.StatCollector;
+
import com.gtnewhorizons.modularui.api.ModularUITextures;
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
import com.gtnewhorizons.modularui.api.drawable.ItemDrawable;
@@ -11,23 +21,15 @@ import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
import com.gtnewhorizons.modularui.common.widget.ButtonWidget;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.enums.Dyes;
import gregtech.api.gui.GT_GUIColorOverride;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.util.GT_Util;
import gregtech.api.util.GT_Utility;
-import java.util.List;
-import java.util.concurrent.atomic.AtomicBoolean;
-import java.util.function.Consumer;
-import java.util.function.Supplier;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.gui.FontRenderer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.StatCollector;
/**
- * Creates UI for selecting item from given list.
- * This is client-only UI to allow using client-preferred settings.
+ * Creates UI for selecting item from given list. This is client-only UI to allow using client-preferred settings.
*/
public class SelectItemUIFactory {
@@ -55,36 +57,31 @@ public class SelectItemUIFactory {
private final Supplier<Integer> COLOR_TITLE = () -> getTextColorOrDefault("title", 0x222222);
private final Supplier<Integer> COLOR_TEXT_GRAY = () -> getTextColorOrDefault("text_gray", 0x555555);
- public SelectItemUIFactory(
- String header, ItemStack headerItem, Consumer<ItemStack> selectedCallback, List<ItemStack> stacks) {
+ public SelectItemUIFactory(String header, ItemStack headerItem, Consumer<ItemStack> selectedCallback,
+ List<ItemStack> stacks) {
this(header, headerItem, selectedCallback, stacks, UNSELECTED);
}
- public SelectItemUIFactory(
- String header,
- ItemStack headerItem,
- Consumer<ItemStack> selectedCallback,
- List<ItemStack> stacks,
- int selected) {
+ public SelectItemUIFactory(String header, ItemStack headerItem, Consumer<ItemStack> selectedCallback,
+ List<ItemStack> stacks, int selected) {
this(header, headerItem, selectedCallback, stacks, selected, false);
}
/**
- * Constructor for a dialog to select an item from given list. Given callback may be called zero or more times depending on user action.
+ * Constructor for a dialog to select an item from given list. Given callback may be called zero or more times
+ * depending on user action.
+ *
* @param header Header text
* @param headerItem ItemStack to use as Dialog icon
* @param selectedCallback callback upon selected
* @param stacks list to choose from
- * @param selected preselected item. Use {@link #UNSELECTED} for unselected. Invalid selected will be clamped to 0 or highest index
- * @param noDeselect true if player cannot deselect, false otherwise. If this is set to true, selectedCallback is guaranteed to be called with a nonnull stack
+ * @param selected preselected item. Use {@link #UNSELECTED} for unselected. Invalid selected will be
+ * clamped to 0 or highest index
+ * @param noDeselect true if player cannot deselect, false otherwise. If this is set to true, selectedCallback
+ * is guaranteed to be called with a nonnull stack
*/
- public SelectItemUIFactory(
- String header,
- ItemStack headerItem,
- Consumer<ItemStack> selectedCallback,
- List<ItemStack> stacks,
- int selected,
- boolean noDeselect) {
+ public SelectItemUIFactory(String header, ItemStack headerItem, Consumer<ItemStack> selectedCallback,
+ List<ItemStack> stacks, int selected, boolean noDeselect) {
this.header = header;
this.headerItem = headerItem;
this.selectedCallback = selectedCallback;
@@ -96,7 +93,8 @@ public class SelectItemUIFactory {
/**
* @param anotherWindow If UI is shown on top of another window
- * @param dialogOpened Flag to store whether this UI is opened and hence it should block duplicated creation of this UI
+ * @param dialogOpened Flag to store whether this UI is opened and hence it should block duplicated creation of
+ * this UI
*/
public SelectItemUIFactory setAnotherWindow(boolean anotherWindow, AtomicBoolean dialogOpened) {
this.anotherWindow = anotherWindow;
@@ -118,8 +116,8 @@ public class SelectItemUIFactory {
}
public ModularWindow createWindow(UIBuildContext buildContext) {
- ModularWindow.Builder builder =
- ModularWindow.builder(getGUIWidth(), 53 + 18 * ((stacks.size() - 1) / cols + 1));
+ ModularWindow.Builder builder = ModularWindow
+ .builder(getGUIWidth(), 53 + 18 * ((stacks.size() - 1) / cols + 1));
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
builder.setGuiTint(guiTint);
@@ -128,33 +126,29 @@ public class SelectItemUIFactory {
}
builder.widget(new TextWidget(header).setDefaultColor(COLOR_TITLE.get()).setPos(25, 9));
- builder.widget(
- new SlotWidget(BaseSlot.phantom(currentDisplayItemHandler, 0)) {
- @Override
- public void draw(float partialTicks) {
- if (currentGetter != null) {
- ItemStack current = currentGetter.get();
- currentDisplayItemHandler.setStackInSlot(0, current);
- selected = GT_Utility.findMatchingStackInList(stacks, current);
- }
- super.draw(partialTicks);
- }
- }.disableInteraction()
- .setBackground(GT_UITextures.SLOT_DARK_GRAY)
- .setPos(
- 9
- + getFontRenderer()
- .getStringWidth(StatCollector.translateToLocal(
- "GT5U.gui.select.current")),
- 24))
- .widget(new TextWidget(StatCollector.translateToLocal("GT5U.gui.select.current"))
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(8, 25 + (18 - getFontRenderer().FONT_HEIGHT) / 2));
+ builder.widget(new SlotWidget(BaseSlot.phantom(currentDisplayItemHandler, 0)) {
+
+ @Override
+ public void draw(float partialTicks) {
+ if (currentGetter != null) {
+ ItemStack current = currentGetter.get();
+ currentDisplayItemHandler.setStackInSlot(0, current);
+ selected = GT_Utility.findMatchingStackInList(stacks, current);
+ }
+ super.draw(partialTicks);
+ }
+ }.disableInteraction().setBackground(GT_UITextures.SLOT_DARK_GRAY).setPos(
+ 9 + getFontRenderer().getStringWidth(StatCollector.translateToLocal("GT5U.gui.select.current")),
+ 24)).widget(
+ new TextWidget(StatCollector.translateToLocal("GT5U.gui.select.current"))
+ .setDefaultColor(COLOR_TEXT_GRAY.get())
+ .setPos(8, 25 + (18 - getFontRenderer().FONT_HEIGHT) / 2));
for (int i = 0; i < stacks.size(); i++) {
final int index = i;
builder.widget(
- new SlotWidget(new BaseSlot(new ItemStackHandler(new ItemStack[] {stacks.get(index)}), 0, true)) {
+ new SlotWidget(new BaseSlot(new ItemStackHandler(new ItemStack[] { stacks.get(index) }), 0, true)) {
+
@Override
public ClickResult onClick(int buttonId, boolean doubleClick) {
if (buttonId == 0) {
@@ -171,24 +165,22 @@ public class SelectItemUIFactory {
@Override
public IDrawable[] getBackground() {
return new IDrawable[] {
- index == selected ? GT_UITextures.SLOT_DARK_GRAY : ModularUITextures.ITEM_SLOT
- };
+ index == selected ? GT_UITextures.SLOT_DARK_GRAY : ModularUITextures.ITEM_SLOT };
}
}.disableInteraction().setPos(7 + 18 * (index % cols), 43 + 18 * (index / cols)));
}
if (anotherWindow) {
dialogOpened.set(true);
- builder.widget(
- new ButtonWidget() {
- @Override
- public void onDestroy() {
- dialogOpened.set(false);
- }
- }.setOnClick((clickData, widget) -> widget.getWindow().tryClose())
- .setBackground(ModularUITextures.VANILLA_BACKGROUND, new Text("x"))
- .setPos(getGUIWidth() - 15, 3)
- .setSize(12, 12));
+ builder.widget(new ButtonWidget() {
+
+ @Override
+ public void onDestroy() {
+ dialogOpened.set(false);
+ }
+ }.setOnClick((clickData, widget) -> widget.getWindow().tryClose())
+ .setBackground(ModularUITextures.VANILLA_BACKGROUND, new Text("x")).setPos(getGUIWidth() - 15, 3)
+ .setSize(12, 12));
}
return builder.build();
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/AESlotWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/AESlotWidget.java
index f3620d3234..386bb7112c 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/AESlotWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/AESlotWidget.java
@@ -1,15 +1,18 @@
package gregtech.common.gui.modularui.widget;
+import net.minecraft.client.renderer.entity.RenderItem;
+import net.minecraft.inventory.Slot;
+
import appeng.client.render.AppEngRenderItem;
import appeng.core.AELog;
import appeng.util.Platform;
+
import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
import com.gtnewhorizons.modularui.common.internal.wrapper.ModularGui;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
-import net.minecraft.client.renderer.entity.RenderItem;
-import net.minecraft.inventory.Slot;
public class AESlotWidget extends SlotWidget {
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/CoverCycleButtonWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/CoverCycleButtonWidget.java
index 599ed28a5f..70978351c2 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/CoverCycleButtonWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/CoverCycleButtonWidget.java
@@ -1,26 +1,28 @@
package gregtech.common.gui.modularui.widget;
+import org.lwjgl.opengl.GL11;
+
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
import com.gtnewhorizons.modularui.api.drawable.UITexture;
import com.gtnewhorizons.modularui.common.widget.CycleButtonWidget;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.gui.modularui.GT_UITextures;
-import org.lwjgl.opengl.GL11;
/**
- * Fires click action on mouse release, not on press.
- * Draws different backgrounds depending on whether the mouse is being pressed or the widget is hovered.
+ * Fires click action on mouse release, not on press. Draws different backgrounds depending on whether the mouse is
+ * being pressed or the widget is hovered.
*/
public class CoverCycleButtonWidget extends CycleButtonWidget {
- private static final UITexture BUTTON_NORMAL_NOT_PRESSED =
- GT_UITextures.BUTTON_COVER_NORMAL.getSubArea(0, 0, 1, 0.5f);
+ private static final UITexture BUTTON_NORMAL_NOT_PRESSED = GT_UITextures.BUTTON_COVER_NORMAL
+ .getSubArea(0, 0, 1, 0.5f);
private static final UITexture BUTTON_NORMAL_PRESSED = GT_UITextures.BUTTON_COVER_NORMAL.getSubArea(0, 0.5f, 1, 1);
- private static final UITexture BUTTON_HOVERED_NOT_PRESSED =
- GT_UITextures.BUTTON_COVER_NORMAL_HOVERED.getSubArea(0, 0, 1, 0.5f);
- private static final UITexture BUTTON_HOVERED_PRESSED =
- GT_UITextures.BUTTON_COVER_NORMAL_HOVERED.getSubArea(0, 0.5f, 1, 1);
+ private static final UITexture BUTTON_HOVERED_NOT_PRESSED = GT_UITextures.BUTTON_COVER_NORMAL_HOVERED
+ .getSubArea(0, 0, 1, 0.5f);
+ private static final UITexture BUTTON_HOVERED_PRESSED = GT_UITextures.BUTTON_COVER_NORMAL_HOVERED
+ .getSubArea(0, 0.5f, 1, 1);
private boolean clickPressed;
@@ -74,15 +76,15 @@ public class CoverCycleButtonWidget extends CycleButtonWidget {
public IDrawable[] getBackground() {
if (isHovering()) {
if (clickPressed) {
- return new IDrawable[] {BUTTON_HOVERED_PRESSED};
+ return new IDrawable[] { BUTTON_HOVERED_PRESSED };
} else {
- return new IDrawable[] {BUTTON_HOVERED_NOT_PRESSED};
+ return new IDrawable[] { BUTTON_HOVERED_NOT_PRESSED };
}
} else {
if (clickPressed) {
- return new IDrawable[] {BUTTON_NORMAL_PRESSED};
+ return new IDrawable[] { BUTTON_NORMAL_PRESSED };
} else {
- return new IDrawable[] {BUTTON_NORMAL_NOT_PRESSED};
+ return new IDrawable[] { BUTTON_NORMAL_NOT_PRESSED };
}
}
}
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataControllerWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataControllerWidget.java
index d28117054a..3fa25abdbf 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataControllerWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataControllerWidget.java
@@ -1,35 +1,38 @@
package gregtech.common.gui.modularui.widget;
-import com.gtnewhorizons.modularui.api.widget.Widget;
-import com.gtnewhorizons.modularui.common.internal.network.NetworkUtils;
-import gregtech.api.gui.modularui.IDataFollowerWidget;
-import gregtech.api.util.GT_CoverBehaviorBase;
-import gregtech.api.util.ISerializableObject;
import java.io.IOException;
import java.util.function.BiFunction;
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.function.Supplier;
+
import net.minecraft.network.PacketBuffer;
+import com.gtnewhorizons.modularui.api.widget.Widget;
+import com.gtnewhorizons.modularui.common.internal.network.NetworkUtils;
+
+import gregtech.api.gui.modularui.IDataFollowerWidget;
+import gregtech.api.util.GT_CoverBehaviorBase;
+import gregtech.api.util.ISerializableObject;
+
public class CoverDataControllerWidget<T extends ISerializableObject> extends DataControllerWidget<T> {
protected final GT_CoverBehaviorBase<T> coverBehavior;
/**
- * @param dataGetter () -> cover data this widget handles
- * @param dataSetter data to set -> if setting cover data is successful
+ * @param dataGetter () -> cover data this widget handles
+ * @param dataSetter data to set -> if setting cover data is successful
* @param coverBehavior cover this widget handles data update
*/
- public CoverDataControllerWidget(
- Supplier<T> dataGetter, Function<T, Boolean> dataSetter, GT_CoverBehaviorBase<T> coverBehavior) {
+ public CoverDataControllerWidget(Supplier<T> dataGetter, Function<T, Boolean> dataSetter,
+ GT_CoverBehaviorBase<T> coverBehavior) {
super(dataGetter, dataSetter);
this.coverBehavior = coverBehavior;
}
@Override
- public <U, W extends Widget & IDataFollowerWidget<T, U>> CoverDataControllerWidget<T> addFollower(
- W widget, Function<T, U> dataToStateGetter, BiFunction<T, U, T> dataUpdater, Consumer<W> applyForWidget) {
+ public <U, W extends Widget & IDataFollowerWidget<T, U>> CoverDataControllerWidget<T> addFollower(W widget,
+ Function<T, U> dataToStateGetter, BiFunction<T, U, T> dataUpdater, Consumer<W> applyForWidget) {
super.addFollower(widget, dataToStateGetter, dataUpdater, applyForWidget);
return this;
}
@@ -58,31 +61,27 @@ public class CoverDataControllerWidget<T extends ISerializableObject> extends Da
private final BiFunction<Integer, T, T> dataUpdater;
/**
- * @param coverDataGetter () -> cover data this widget handles
- * @param coverDataSetter data to set -> if setting cover data is successful
- * @param coverBehavior cover this widget handles data update
+ * @param coverDataGetter () -> cover data this widget handles
+ * @param coverDataSetter data to set -> if setting cover data is successful
+ * @param coverBehavior cover this widget handles data update
* @param dataToStateGetter (index of button, given cover data) -> button state
- * @param dataUpdater (index of button, current cover data) -> new cover data
+ * @param dataUpdater (index of button, current cover data) -> new cover data
*/
- public CoverDataIndexedControllerWidget_ToggleButtons(
- Supplier<T> coverDataGetter,
- Function<T, Boolean> coverDataSetter,
- GT_CoverBehaviorBase<T> coverBehavior,
- BiFunction<Integer, T, Boolean> dataToStateGetter,
- BiFunction<Integer, T, T> dataUpdater) {
+ public CoverDataIndexedControllerWidget_ToggleButtons(Supplier<T> coverDataGetter,
+ Function<T, Boolean> coverDataSetter, GT_CoverBehaviorBase<T> coverBehavior,
+ BiFunction<Integer, T, Boolean> dataToStateGetter, BiFunction<Integer, T, T> dataUpdater) {
super(coverDataGetter, coverDataSetter, coverBehavior);
this.dataToStateGetter = dataToStateGetter;
this.dataUpdater = dataUpdater;
}
/**
- * @param index index of widget to add
- * @param widget widget to add
+ * @param index index of widget to add
+ * @param widget widget to add
* @param applyForWidget methods to call for widget to add
*/
- public <W extends CoverDataFollower_ToggleButtonWidget<T>>
- CoverDataIndexedControllerWidget_ToggleButtons<T> addToggleButton(
- int index, W widget, Consumer<CoverDataFollower_ToggleButtonWidget<T>> applyForWidget) {
+ public <W extends CoverDataFollower_ToggleButtonWidget<T>> CoverDataIndexedControllerWidget_ToggleButtons<T> addToggleButton(
+ int index, W widget, Consumer<CoverDataFollower_ToggleButtonWidget<T>> applyForWidget) {
addFollower(
widget,
data -> dataToStateGetter.apply(index, data),
@@ -102,31 +101,27 @@ public class CoverDataControllerWidget<T extends ISerializableObject> extends Da
private final BiFunction<Integer, T, T> dataUpdater;
/**
- * @param coverDataGetter () -> cover data this widget handles
- * @param coverDataSetter data to set -> if setting cover data is successful
- * @param coverBehavior cover this widget handles data update
+ * @param coverDataGetter () -> cover data this widget handles
+ * @param coverDataSetter data to set -> if setting cover data is successful
+ * @param coverBehavior cover this widget handles data update
* @param dataToStateGetter (index of button, given cover data) -> button state
- * @param dataUpdater (index of button, current cover data) -> new cover data
+ * @param dataUpdater (index of button, current cover data) -> new cover data
*/
- public CoverDataIndexedControllerWidget_CycleButtons(
- Supplier<T> coverDataGetter,
- Function<T, Boolean> coverDataSetter,
- GT_CoverBehaviorBase<T> coverBehavior,
- BiFunction<Integer, T, Integer> dataToStateGetter,
- BiFunction<Integer, T, T> dataUpdater) {
+ public CoverDataIndexedControllerWidget_CycleButtons(Supplier<T> coverDataGetter,
+ Function<T, Boolean> coverDataSetter, GT_CoverBehaviorBase<T> coverBehavior,
+ BiFunction<Integer, T, Integer> dataToStateGetter, BiFunction<Integer, T, T> dataUpdater) {
super(coverDataGetter, coverDataSetter, coverBehavior);
this.dataToStateGetter = dataToStateGetter;
this.dataUpdater = dataUpdater;
}
/**
- * @param index index of widget to add
- * @param widget widget to add
+ * @param index index of widget to add
+ * @param widget widget to add
* @param applyForWidget methods to call for the widget to add
*/
- public <W extends CoverDataFollower_CycleButtonWidget<T>>
- CoverDataIndexedControllerWidget_CycleButtons<T> addCycleButton(
- int index, W widget, Consumer<CoverDataFollower_CycleButtonWidget<T>> applyForWidget) {
+ public <W extends CoverDataFollower_CycleButtonWidget<T>> CoverDataIndexedControllerWidget_CycleButtons<T> addCycleButton(
+ int index, W widget, Consumer<CoverDataFollower_CycleButtonWidget<T>> applyForWidget) {
addFollower(
widget,
data -> dataToStateGetter.apply(index, data),
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_CycleButtonWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_CycleButtonWidget.java
index d07165cc6e..6e69b1ff79 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_CycleButtonWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_CycleButtonWidget.java
@@ -1,10 +1,11 @@
package gregtech.common.gui.modularui.widget;
-import gregtech.api.gui.modularui.IDataFollowerWidget;
-import gregtech.api.util.ISerializableObject;
import java.util.function.Consumer;
import java.util.function.Function;
+import gregtech.api.gui.modularui.IDataFollowerWidget;
+import gregtech.api.util.ISerializableObject;
+
/**
* Determines button state with cover data.
*/
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_SlotWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_SlotWidget.java
index c09c5b5279..c7795efbdc 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_SlotWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_SlotWidget.java
@@ -1,15 +1,18 @@
package gregtech.common.gui.modularui.widget;
+import java.io.IOException;
+import java.util.function.Consumer;
+import java.util.function.Function;
+
+import net.minecraft.item.ItemStack;
+
import com.gtnewhorizons.modularui.api.forge.IItemHandlerModifiable;
import com.gtnewhorizons.modularui.api.widget.Interactable;
import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
import gregtech.api.gui.modularui.IDataFollowerWidget;
import gregtech.api.util.ISerializableObject;
-import java.io.IOException;
-import java.util.function.Consumer;
-import java.util.function.Function;
-import net.minecraft.item.ItemStack;
public class CoverDataFollower_SlotWidget<T extends ISerializableObject> extends SlotWidget
implements IDataFollowerWidget<T, ItemStack> {
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_TextFieldWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_TextFieldWidget.java
index 9130f8e3d0..7d11656231 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_TextFieldWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_TextFieldWidget.java
@@ -1,15 +1,18 @@
package gregtech.common.gui.modularui.widget;
+import java.util.function.Consumer;
+import java.util.function.Function;
+
+import net.minecraft.client.gui.GuiScreen;
+
import com.gtnewhorizons.modularui.api.math.Alignment;
import com.gtnewhorizons.modularui.api.math.Color;
import com.gtnewhorizons.modularui.api.math.MathExpression;
import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
+
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.gui.modularui.IDataFollowerWidget;
import gregtech.api.util.ISerializableObject;
-import java.util.function.Consumer;
-import java.util.function.Function;
-import net.minecraft.client.gui.GuiScreen;
public class CoverDataFollower_TextFieldWidget<T extends ISerializableObject> extends TextFieldWidget
implements IDataFollowerWidget<T, String> {
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_ToggleButtonWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_ToggleButtonWidget.java
index 8e091d7bc6..cb5fbf7994 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_ToggleButtonWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/CoverDataFollower_ToggleButtonWidget.java
@@ -1,11 +1,13 @@
package gregtech.common.gui.modularui.widget;
+import java.util.function.Consumer;
+import java.util.function.Function;
+
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
+
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.gui.modularui.IDataFollowerWidget;
import gregtech.api.util.ISerializableObject;
-import java.util.function.Consumer;
-import java.util.function.Function;
public class CoverDataFollower_ToggleButtonWidget<T extends ISerializableObject> extends CoverCycleButtonWidget
implements IDataFollowerWidget<T, Boolean> {
@@ -77,7 +79,7 @@ public class CoverDataFollower_ToggleButtonWidget<T extends ISerializableObject>
@Override
public IDrawable[] getBackground() {
- if (!canClick()) return new IDrawable[] {GT_UITextures.BUTTON_COVER_NORMAL_DISABLED};
+ if (!canClick()) return new IDrawable[] { GT_UITextures.BUTTON_COVER_NORMAL_DISABLED };
return super.getBackground();
}
}
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java
index f29b8eeaf9..4e9ac4a245 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/DataControllerWidget.java
@@ -1,26 +1,31 @@
package gregtech.common.gui.modularui.widget;
+import java.io.IOException;
+import java.util.function.BiFunction;
+import java.util.function.Consumer;
+import java.util.function.Function;
+import java.util.function.Supplier;
+
+import net.minecraft.network.PacketBuffer;
+
import com.gtnewhorizons.modularui.api.widget.ISyncedWidget;
import com.gtnewhorizons.modularui.api.widget.Widget;
import com.gtnewhorizons.modularui.common.internal.network.NetworkUtils;
import com.gtnewhorizons.modularui.common.widget.MultiChildWidget;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.gui.modularui.IDataFollowerWidget;
import gregtech.api.util.ISerializableObject;
-import java.io.IOException;
-import java.util.function.BiFunction;
-import java.util.function.Consumer;
-import java.util.function.Function;
-import java.util.function.Supplier;
-import net.minecraft.network.PacketBuffer;
/**
- * Controls state of child widgets with specific data, and allows centralized control of multiple widgets.
- * e.g. clicking button B will set machine mode to B, so button A, whose state is bound to the mode,
- * will be automatically deactivated by this widget.
- * <br> This widget wraps data and handles validation, e.g. tell client to close GUI when tile is broken or cover is removed.
- * <br> Data can be anything, e.g. {@link ISerializableObject} or machine recipe mode.
+ * Controls state of child widgets with specific data, and allows centralized control of multiple widgets. e.g. clicking
+ * button B will set machine mode to B, so button A, whose state is bound to the mode, will be automatically deactivated
+ * by this widget. <br>
+ * This widget wraps data and handles validation, e.g. tell client to close GUI when tile is broken or cover is removed.
+ * <br>
+ * Data can be anything, e.g. {@link ISerializableObject} or machine recipe mode.
+ *
* @param <T> Data type stored in this widget
* @see IDataFollowerWidget
*/
@@ -139,15 +144,15 @@ public abstract class DataControllerWidget<T> extends MultiChildWidget implement
}
/**
- * @param widget widget to add that implements {@link IDataFollowerWidget}
+ * @param widget widget to add that implements {@link IDataFollowerWidget}
* @param dataToStateGetter given data -> state of the widget to add
- * @param dataUpdater (current data, state of the widget to add) -> new data to set
- * @param applyForWidget methods to call for the widget to add
- * @param <U> state type stored in the widget to add
- * @param <W> widget type to add
+ * @param dataUpdater (current data, state of the widget to add) -> new data to set
+ * @param applyForWidget methods to call for the widget to add
+ * @param <U> state type stored in the widget to add
+ * @param <W> widget type to add
*/
- public <U, W extends Widget & IDataFollowerWidget<T, U>> DataControllerWidget<T> addFollower(
- W widget, Function<T, U> dataToStateGetter, BiFunction<T, U, T> dataUpdater, Consumer<W> applyForWidget) {
+ public <U, W extends Widget & IDataFollowerWidget<T, U>> DataControllerWidget<T> addFollower(W widget,
+ Function<T, U> dataToStateGetter, BiFunction<T, U, T> dataUpdater, Consumer<W> applyForWidget) {
widget.setDataToStateGetter(dataToStateGetter);
widget.setStateSetter(state -> {
T newData = dataUpdater.apply(getLastData(), state);
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/FluidDisplaySlotWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/FluidDisplaySlotWidget.java
index 688800e4ef..182f007b33 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/FluidDisplaySlotWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/FluidDisplaySlotWidget.java
@@ -1,19 +1,12 @@
package gregtech.common.gui.modularui.widget;
-import com.gtnewhorizons.modularui.api.forge.IItemHandlerModifiable;
-import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
-import com.gtnewhorizons.modularui.common.widget.SlotWidget;
-import gregtech.GT_Mod;
-import gregtech.api.interfaces.IFluidAccess;
-import gregtech.api.interfaces.IHasFluidDisplayItem;
-import gregtech.api.interfaces.metatileentity.IFluidLockable;
-import gregtech.api.util.GT_Utility;
import java.io.IOException;
import java.util.Collections;
import java.util.List;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import java.util.function.Supplier;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.ItemStack;
@@ -22,6 +15,16 @@ import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidContainerItem;
+import com.gtnewhorizons.modularui.api.forge.IItemHandlerModifiable;
+import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
+import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
+import gregtech.GT_Mod;
+import gregtech.api.interfaces.IFluidAccess;
+import gregtech.api.interfaces.IHasFluidDisplayItem;
+import gregtech.api.interfaces.metatileentity.IFluidLockable;
+import gregtech.api.util.GT_Utility;
+
public class FluidDisplaySlotWidget extends SlotWidget {
private IHasFluidDisplayItem iHasFluidDisplay;
@@ -57,11 +60,10 @@ public class FluidDisplaySlotWidget extends SlotWidget {
if (interactionDisabled) return ClickResult.REJECT;
/*
- * While a logical client don't really need to process fluid cells upon click (it could have just wait
- * for server side to send the result), doing so would result in every fluid interaction having a
- * noticeable delay between clicking and changes happening even on single player.
- * I'd imagine this lag to become only more severe when playing MP over ethernet, which would have much more latency
- * than a memory connection
+ * While a logical client don't really need to process fluid cells upon click (it could have just wait for
+ * server side to send the result), doing so would result in every fluid interaction having a noticeable delay
+ * between clicking and changes happening even on single player. I'd imagine this lag to become only more severe
+ * when playing MP over ethernet, which would have much more latency than a memory connection
*/
ClickData clickData = ClickData.create(buttonId, doubleClick);
ItemStack verifyToken = executeRealClick(clickData);
@@ -126,8 +128,7 @@ public class FluidDisplaySlotWidget extends SlotWidget {
ItemStack serverVerifyToken = executeRealClick(clickData);
// similar to what NetHandlerPlayServer#processClickWindow does
if (!ItemStack.areItemStacksEqual(clientVerifyToken, serverVerifyToken)) {
- ((EntityPlayerMP) getContext().getPlayer())
- .sendContainerToPlayer(getContext().getContainer());
+ ((EntityPlayerMP) getContext().getPlayer()).sendContainerToPlayer(getContext().getContainer());
}
}
@@ -140,8 +141,8 @@ public class FluidDisplaySlotWidget extends SlotWidget {
ItemStack ret = null;
if (actionRealClick == Action.TRANSFER) {
if (fluidAccessConstructor == null) {
- GT_Mod.GT_FML_LOGGER.warn(
- "FluidDisplaySlotWidget is asked to transfer fluid, but fluidAccessConstructor is null!");
+ GT_Mod.GT_FML_LOGGER
+ .warn("FluidDisplaySlotWidget is asked to transfer fluid, but fluidAccessConstructor is null!");
return null;
}
ret = transferFluid(
@@ -158,12 +159,8 @@ public class FluidDisplaySlotWidget extends SlotWidget {
return ret;
}
- protected ItemStack transferFluid(
- IFluidAccess aFluidAccess,
- EntityPlayer aPlayer,
- boolean aProcessFullStack,
- boolean aCanDrain,
- boolean aCanFill) {
+ protected ItemStack transferFluid(IFluidAccess aFluidAccess, EntityPlayer aPlayer, boolean aProcessFullStack,
+ boolean aCanDrain, boolean aCanFill) {
ItemStack tStackHeld = aPlayer.inventory.getItemStack();
ItemStack tStackSizedOne = GT_Utility.copyAmount(1, tStackHeld);
if (tStackSizedOne == null || tStackHeld.stackSize == 0) return null;
@@ -224,12 +221,10 @@ public class FluidDisplaySlotWidget extends SlotWidget {
if (aProcessFullStack) {
int tFilledAmount = tOriginalFluidAmount - tTankStack.amount;
/*
- work out how many more items we can fill
- one cell is already used, so account for that
- the round down behavior will left over a fraction of a cell worth of fluid
- the user then get to decide what to do with it
- it will not be too fancy if it spills out partially filled cells
- */
+ * work out how many more items we can fill one cell is already used, so account for that the round down
+ * behavior will left over a fraction of a cell worth of fluid the user then get to decide what to do
+ * with it it will not be too fancy if it spills out partially filled cells
+ */
int tAdditionalParallel = Math.min(tStackHeld.stackSize - 1, tTankStack.amount / tFilledAmount);
tTankStack.amount -= tFilledAmount * tAdditionalParallel;
tFilledContainer.stackSize += tAdditionalParallel;
@@ -240,8 +235,8 @@ public class FluidDisplaySlotWidget extends SlotWidget {
return tFilledContainer;
}
- protected static ItemStack fillFluid(
- IFluidAccess aFluidAccess, EntityPlayer aPlayer, FluidStack aFluidHeld, boolean aProcessFullStack) {
+ protected static ItemStack fillFluid(IFluidAccess aFluidAccess, EntityPlayer aPlayer, FluidStack aFluidHeld,
+ boolean aProcessFullStack) {
// we are not using aMachine.fill() here any more, so we need to check for fluid type here ourselves
if (aFluidAccess.get() != null && !aFluidAccess.get().isFluidEqual(aFluidHeld)) return null;
ItemStack tStackHeld = aPlayer.inventory.getItemStack();
@@ -402,8 +397,8 @@ public class FluidDisplaySlotWidget extends SlotWidget {
}
/**
- * Add a predicate on whether a client stack will be accepted. Note this will only be called when this slot is already
- * empty. It is assumed whatever is already in the slot will pass the filter.
+ * Add a predicate on whether a client stack will be accepted. Note this will only be called when this slot is
+ * already empty. It is assumed whatever is already in the slot will pass the filter.
*/
public FluidDisplaySlotWidget setEmptyCanFillFilter(Predicate<Fluid> canFillFilter) {
this.canFillFilter = canFillFilter;
@@ -411,8 +406,7 @@ public class FluidDisplaySlotWidget extends SlotWidget {
}
/**
- * Sets action called on drag-and-drop from NEI.
- * You can't use {@link Action#TRANSFER} here.
+ * Sets action called on drag-and-drop from NEI. You can't use {@link Action#TRANSFER} here.
*/
public FluidDisplaySlotWidget setActionDragAndDrop(Action actionDragAndDrop) {
this.actionDragAndDrop = actionDragAndDrop;
@@ -421,6 +415,7 @@ public class FluidDisplaySlotWidget extends SlotWidget {
/**
* Sets function called before {@link #executeRealClick}.
+ *
* @param beforeRealClick (click data, this widget) -> if allow click
*/
public FluidDisplaySlotWidget setBeforeRealClick(
@@ -431,6 +426,7 @@ public class FluidDisplaySlotWidget extends SlotWidget {
/**
* Sets function called before {@link #executeDragAndDrop}.
+ *
* @param beforeDragAndDrop (click data, this widget) -> if allow click
*/
public FluidDisplaySlotWidget setBeforeDragAndDrop(
@@ -441,7 +437,8 @@ public class FluidDisplaySlotWidget extends SlotWidget {
/**
* Sets function called before both of {@link #executeRealClick} and {@link #executeDragAndDrop}.
- * @param beforeClick (click data, this widget) -> if allow click
+ *
+ * @param beforeClick (click data, this widget) -> if allow click
*/
public FluidDisplaySlotWidget setBeforeClick(BiFunction<ClickData, FluidDisplaySlotWidget, Boolean> beforeClick) {
setBeforeRealClick(beforeClick);
@@ -450,8 +447,8 @@ public class FluidDisplaySlotWidget extends SlotWidget {
}
/**
- * By default, this widget runs {@link IHasFluidDisplayItem#updateFluidDisplayItem} after click.
- * You can specify custom update action with this method.
+ * By default, this widget runs {@link IHasFluidDisplayItem#updateFluidDisplayItem} after click. You can specify
+ * custom update action with this method.
*/
public FluidDisplaySlotWidget setUpdateFluidDisplayItem(Runnable updateFluidDisplayItem) {
this.updateFluidDisplayItem = updateFluidDisplayItem;
@@ -464,20 +461,17 @@ public class FluidDisplaySlotWidget extends SlotWidget {
public enum Action {
/**
- * Fill/drain fluid into/from the tank.
- * Uses fluid amount, so drag-and-drop cannot use this mode.
+ * Fill/drain fluid into/from the tank. Uses fluid amount, so drag-and-drop cannot use this mode.
*/
TRANSFER,
/**
- * Lock fluid for {@link IFluidLockable}.
- * Does not use fluid amount.
+ * Lock fluid for {@link IFluidLockable}. Does not use fluid amount.
*/
LOCK,
/**
- * Set filter for the tank. (not implemented yet)
- * Does not use fluid amount.
+ * Set filter for the tank. (not implemented yet) Does not use fluid amount.
*/
FILTER,
diff --git a/src/main/java/gregtech/common/gui/modularui/widget/ItemWatcherSlotWidget.java b/src/main/java/gregtech/common/gui/modularui/widget/ItemWatcherSlotWidget.java
index 7385208874..265450d384 100644
--- a/src/main/java/gregtech/common/gui/modularui/widget/ItemWatcherSlotWidget.java
+++ b/src/main/java/gregtech/common/gui/modularui/widget/ItemWatcherSlotWidget.java
@@ -1,16 +1,18 @@
package gregtech.common.gui.modularui.widget;
+import java.util.function.Supplier;
+
+import net.minecraft.item.ItemStack;
+
import com.gtnewhorizons.modularui.api.forge.IItemHandlerModifiable;
import com.gtnewhorizons.modularui.api.forge.ItemStackHandler;
import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
import gregtech.api.util.GT_Utility;
-import java.util.function.Supplier;
-import net.minecraft.item.ItemStack;
/**
- * Watches specific ItemStack and pulls changes from it.
- * Player cannot interact with slot, other than viewing NEI recipe or adding bookmark.
+ * Watches specific ItemStack and pulls changes from it. Player cannot interact with slot, other than viewing NEI recipe
+ * or adding bookmark.
*/
public class ItemWatcherSlotWidget extends SlotWidget {
diff --git a/src/main/java/gregtech/common/items/CombType.java b/src/main/java/gregtech/common/items/CombType.java
index b010cba824..ff08fde695 100644
--- a/src/main/java/gregtech/common/items/CombType.java
+++ b/src/main/java/gregtech/common/items/CombType.java
@@ -1,10 +1,12 @@
package gregtech.common.items;
+import java.util.Arrays;
+
import gregtech.api.enums.Materials;
import gregtech.api.util.GT_LanguageManager;
-import java.util.Arrays;
public enum CombType {
+
// Organic Line
LIGNIE(0, "lignite", true, Materials.Lignite, 100, 0x58300B, 0x906237, ItemComb.Voltage.LV),
COAL(1, "coal", true, Materials.Coal, 100, 0x525252, 0x666666, ItemComb.Voltage.LV),
@@ -26,8 +28,8 @@ public enum CombType {
CONDUCTIVEIRON(13, "conductiveiron", true, Materials.ConductiveIron, 80, 0x817671, 0xCEADA3, ItemComb.Voltage.MV),
VIBRANTALLOY(14, "vibrantalloy", true, Materials.VibrantAlloy, 50, 0x86A12D, 0xC4F2AE, ItemComb.Voltage.HV),
ENERGETICALLOY(15, "energeticalloy", true, Materials.EnergeticAlloy, 70, 0xFF9933, 0xFFAD5C, ItemComb.Voltage.HV),
- ELECTRICALSTEEL(
- 16, "electricalsteel", true, Materials.ElectricalSteel, 90, 0x787878, 0xD8D8D8, ItemComb.Voltage.LV),
+ ELECTRICALSTEEL(16, "electricalsteel", true, Materials.ElectricalSteel, 90, 0x787878, 0xD8D8D8,
+ ItemComb.Voltage.LV),
DARKSTEEL(17, "darksteel", true, Materials.DarkSteel, 80, 0x252525, 0x443B44, ItemComb.Voltage.MV),
PULSATINGIRON(18, "pulsatingiron", true, Materials.PulsatingIron, 80, 0x006600, 0x6DD284, ItemComb.Voltage.HV),
STAINLESSSTEEL(19, "stainlesssteel", true, Materials.StainlessSteel, 75, 0x778899, 0xC8C8DC, ItemComb.Voltage.HV),
@@ -124,8 +126,8 @@ public enum CombType {
MYTRYL(96, "mytryl", true, Materials.Mytryl, 65, 0xDAA520, 0xF26404, ItemComb.Voltage.IV),
QUANTIUM(97, "quantium", true, Materials.Quantium, 50, 0x00FF00, 0x00D10B, ItemComb.Voltage.IV),
ORIHARUKON(98, "oriharukon", true, Materials.Oriharukon, 50, 0x228B22, 0x677D68, ItemComb.Voltage.IV),
- MYSTERIOUSCRYSTAL(
- 99, "mysteriouscrystal", true, Materials.MysteriousCrystal, 45, 0x3CB371, 0x16856C, ItemComb.Voltage.LuV),
+ MYSTERIOUSCRYSTAL(99, "mysteriouscrystal", true, Materials.MysteriousCrystal, 45, 0x3CB371, 0x16856C,
+ ItemComb.Voltage.LuV),
BLACKPLUTONIUM(100, "blackplutonium", true, Materials.Quantium, 25, 0x000000, 0x323232, ItemComb.Voltage.LuV),
TRINIUM(101, "trinium", true, Materials.Trinium, 25, 0xB0E0E6, 0xC8C8D2, ItemComb.Voltage.ZPM),
@@ -224,19 +226,13 @@ public enum CombType {
this.material = material;
this.chance = chance;
this.showInList = show;
- this.color = new int[] {color1, color2};
+ this.color = new int[] { color1, color2 };
this.localizedName = GT_LanguageManager.addStringLocalization(
- "comb." + this.name, this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Comb");
+ "comb." + this.name,
+ this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Comb");
}
- CombType(
- int id,
- String pName,
- boolean show,
- Materials material,
- int chance,
- int color1,
- int color2,
+ CombType(int id, String pName, boolean show, Materials material, int chance, int color1, int color2,
ItemComb.Voltage voltage) {
if (id < 0 && !"INVALIDCOMB".equals(pName)) throw new IllegalArgumentException();
this.id = id;
@@ -245,9 +241,10 @@ public enum CombType {
this.material = material;
this.chance = chance;
this.showInList = show;
- this.color = new int[] {color1, color2};
+ this.color = new int[] { color1, color2 };
this.localizedName = GT_LanguageManager.addStringLocalization(
- "comb." + this.name, this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Comb");
+ "comb." + this.name,
+ this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Comb");
}
public void setHidden() {
@@ -260,7 +257,7 @@ public enum CombType {
}
public int[] getColours() {
- return color == null || color.length != 2 ? new int[] {0, 0} : color;
+ return color == null || color.length != 2 ? new int[] { 0, 0 } : color;
}
public int getId() {
@@ -272,13 +269,11 @@ public enum CombType {
}
private static final class Companion {
+
private static final CombType[] VALUES;
static {
- int biggestId = Arrays.stream(CombType.values())
- .mapToInt(CombType::getId)
- .max()
- .getAsInt();
+ int biggestId = Arrays.stream(CombType.values()).mapToInt(CombType::getId).max().getAsInt();
VALUES = new CombType[biggestId + 1];
Arrays.fill(VALUES, _NULL);
for (CombType type : CombType.values()) {
diff --git a/src/main/java/gregtech/common/items/DropType.java b/src/main/java/gregtech/common/items/DropType.java
index 6bc8eadcf7..3195e9ecbd 100644
--- a/src/main/java/gregtech/common/items/DropType.java
+++ b/src/main/java/gregtech/common/items/DropType.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.Materials;
import gregtech.api.util.GT_LanguageManager;
public enum DropType {
+
OIL("oil", true),
MUTAGEN("small mutagen catalyst", true),
COOLANT("coolant", true),
@@ -14,17 +15,9 @@ public enum DropType {
LAPIS("lapis coolant", true),
ENDERGOO("ender goo", true);
- private static int[][] colours = new int[][] {
- {0x19191B, 0x303032},
- {0xffc100, 0x00ff11},
- {0x144F5A, 0x2494A2},
- {0xC11F1F, 0xEBB9B9},
- {0x872836, 0xB8132C},
- {0xD02001, 0x9C0018},
- {0x003366, 0x0066BB},
- {0x1727b1, 0x008ce3},
- {0xA005E7, 0x161616},
- };
+ private static int[][] colours = new int[][] { { 0x19191B, 0x303032 }, { 0xffc100, 0x00ff11 },
+ { 0x144F5A, 0x2494A2 }, { 0xC11F1F, 0xEBB9B9 }, { 0x872836, 0xB8132C }, { 0xD02001, 0x9C0018 },
+ { 0x003366, 0x0066BB }, { 0x1727b1, 0x008ce3 }, { 0xA005E7, 0x161616 }, };
public boolean showInList;
public Materials material;
public int chance;
@@ -42,7 +35,8 @@ public enum DropType {
public String getName() {
return GT_LanguageManager.addStringLocalization(
- "drop." + this.name, this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Drop");
+ "drop." + this.name,
+ this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Drop");
}
public int[] getColours() {
diff --git a/src/main/java/gregtech/common/items/GT_DepletetCell_Item.java b/src/main/java/gregtech/common/items/GT_DepletetCell_Item.java
index 7a4df4f1a3..a7505f8953 100644
--- a/src/main/java/gregtech/common/items/GT_DepletetCell_Item.java
+++ b/src/main/java/gregtech/common/items/GT_DepletetCell_Item.java
@@ -1,8 +1,9 @@
package gregtech.common.items;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.items.GT_RadioactiveCellIC_Item;
import ic2.api.reactor.IReactor;
-import net.minecraft.item.ItemStack;
public class GT_DepletetCell_Item extends GT_RadioactiveCellIC_Item {
@@ -11,19 +12,12 @@ public class GT_DepletetCell_Item extends GT_RadioactiveCellIC_Item {
}
@Override
- public void processChamber(
- IReactor paramIReactor, ItemStack paramItemStack, int paramInt1, int paramInt2, boolean paramBoolean) {}
+ public void processChamber(IReactor paramIReactor, ItemStack paramItemStack, int paramInt1, int paramInt2,
+ boolean paramBoolean) {}
@Override
- public boolean acceptUraniumPulse(
- IReactor paramIReactor,
- ItemStack paramItemStack1,
- ItemStack paramItemStack2,
- int paramInt1,
- int paramInt2,
- int paramInt3,
- int paramInt4,
- boolean paramBoolean) {
+ public boolean acceptUraniumPulse(IReactor paramIReactor, ItemStack paramItemStack1, ItemStack paramItemStack2,
+ int paramInt1, int paramInt2, int paramInt3, int paramInt4, boolean paramBoolean) {
return false;
}
@@ -43,8 +37,8 @@ public class GT_DepletetCell_Item extends GT_RadioactiveCellIC_Item {
}
@Override
- public int alterHeat(
- IReactor paramIReactor, ItemStack paramItemStack, int paramInt1, int paramInt2, int paramInt3) {
+ public int alterHeat(IReactor paramIReactor, ItemStack paramItemStack, int paramInt1, int paramInt2,
+ int paramInt3) {
return 0;
}
diff --git a/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java b/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java
index 373147a738..624e326268 100644
--- a/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java
+++ b/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java
@@ -1,17 +1,11 @@
package gregtech.common.items;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Materials;
-import gregtech.api.items.GT_Generic_Item;
-import gregtech.api.util.GT_Utility;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.stream.Stream;
+
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
@@ -26,7 +20,15 @@ import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.oredict.OreDictionary;
-@SuppressWarnings({"rawtypes", "unchecked"})
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.api.items.GT_Generic_Item;
+import gregtech.api.util.GT_Utility;
+
+@SuppressWarnings({ "rawtypes", "unchecked" })
public class GT_FluidDisplayItem extends GT_Generic_Item {
private static final Map<Fluid, String> sFluidTooltips = new HashMap<>();
@@ -39,8 +41,8 @@ public class GT_FluidDisplayItem extends GT_Generic_Item {
@Override
protected void addAdditionalToolTips(List<String> aList, ItemStack aStack, EntityPlayer aPlayer) {
if (FluidRegistry.getFluid(aStack.getItemDamage()) != null) {
- String tChemicalFormula =
- getChemicalFormula(new FluidStack(FluidRegistry.getFluid(aStack.getItemDamage()), 1));
+ String tChemicalFormula = getChemicalFormula(
+ new FluidStack(FluidRegistry.getFluid(aStack.getItemDamage()), 1));
if (!tChemicalFormula.isEmpty())
aList.add(EnumChatFormatting.YELLOW + tChemicalFormula + EnumChatFormatting.RESET);
}
@@ -54,14 +56,21 @@ public class GT_FluidDisplayItem extends GT_Generic_Item {
if (aNBT != null) {
long tToolTipAmount = aNBT.getLong("mFluidDisplayAmount");
if (tToolTipAmount > 0L) {
- aList.add(EnumChatFormatting.BLUE + "Amount: " + GT_Utility.formatNumbers(tToolTipAmount) + " L"
- + EnumChatFormatting.GRAY);
+ aList.add(
+ EnumChatFormatting.BLUE + "Amount: "
+ + GT_Utility.formatNumbers(tToolTipAmount)
+ + " L"
+ + EnumChatFormatting.GRAY);
}
- aList.add(EnumChatFormatting.RED + "Temperature: "
- + GT_Utility.formatNumbers(aNBT.getLong("mFluidDisplayHeat")) + " K" + EnumChatFormatting.GRAY);
- aList.add(EnumChatFormatting.GREEN
- + String.format(transItem("018", "State: %s"), aNBT.getBoolean("mFluidState") ? "Gas" : "Liquid")
- + EnumChatFormatting.GRAY);
+ aList.add(
+ EnumChatFormatting.RED + "Temperature: "
+ + GT_Utility.formatNumbers(aNBT.getLong("mFluidDisplayHeat"))
+ + " K"
+ + EnumChatFormatting.GRAY);
+ aList.add(
+ EnumChatFormatting.GREEN + String
+ .format(transItem("018", "State: %s"), aNBT.getBoolean("mFluidState") ? "Gas" : "Liquid")
+ + EnumChatFormatting.GRAY);
}
}
@@ -71,12 +80,8 @@ public class GT_FluidDisplayItem extends GT_Generic_Item {
@Override
public IIcon getIconFromDamage(int aMetaData) {
- return Stream.of(FluidRegistry.getFluid(aMetaData), FluidRegistry.WATER)
- .filter(Objects::nonNull)
- .map(Fluid::getStillIcon)
- .filter(Objects::nonNull)
- .findFirst()
- .orElseThrow(IllegalStateException::new);
+ return Stream.of(FluidRegistry.getFluid(aMetaData), FluidRegistry.WATER).filter(Objects::nonNull)
+ .map(Fluid::getStillIcon).filter(Objects::nonNull).findFirst().orElseThrow(IllegalStateException::new);
}
@Override
@@ -125,8 +130,7 @@ public class GT_FluidDisplayItem extends GT_Generic_Item {
// tooltip
List tTooltip = tContainer.getTooltip(null, true);
for (Object tInfo : tTooltip) {
- if (!((String) tInfo).contains(" ")
- && !((String) tInfo).contains(":")
+ if (!((String) tInfo).contains(" ") && !((String) tInfo).contains(":")
&& tTooltip.indexOf(tInfo) != 0) {
return (String) tInfo;
}
@@ -164,8 +168,8 @@ public class GT_FluidDisplayItem extends GT_Generic_Item {
for (int tOreDict : OreDictionary.getOreIDs(tItemStack)) {
String tOreDictName = OreDictionary.getOreName(tOreDict);
if (tOreDictName.startsWith("cell")) {
- return Materials.getRealMaterial(
- tOreDictName.replace("cell", "").replace("Molten", "").replace("Plasma", ""));
+ return Materials
+ .getRealMaterial(tOreDictName.replace("cell", "").replace("Molten", "").replace("Plasma", ""));
}
}
return Materials._NULL;
diff --git a/src/main/java/gregtech/common/items/GT_IntegratedCircuit_Item.java b/src/main/java/gregtech/common/items/GT_IntegratedCircuit_Item.java
index a5842bb9c1..3fa06018f0 100644
--- a/src/main/java/gregtech/common/items/GT_IntegratedCircuit_Item.java
+++ b/src/main/java/gregtech/common/items/GT_IntegratedCircuit_Item.java
@@ -3,29 +3,12 @@ package gregtech.common.items;
import static gregtech.GT_Mod.GT_FML_LOGGER;
import static gregtech.api.enums.GT_Values.RES_PATH_ITEM;
-import com.gtnewhorizons.modularui.api.UIInfos;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.INetworkUpdatableItem;
-import gregtech.api.items.GT_Generic_Item;
-import gregtech.api.net.GT_Packet_UpdateItem;
-import gregtech.api.objects.XSTR;
-import gregtech.api.util.GT_Config;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.gui.modularui.uifactory.SelectItemUIFactory;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.function.BiFunction;
import java.util.function.Predicate;
+
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer;
@@ -40,9 +23,31 @@ import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import net.minecraftforge.common.util.Constants;
import net.minecraftforge.common.util.FakePlayer;
+
import org.apache.commons.lang3.tuple.Pair;
+import com.gtnewhorizons.modularui.api.UIInfos;
+
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.INetworkUpdatableItem;
+import gregtech.api.items.GT_Generic_Item;
+import gregtech.api.net.GT_Packet_UpdateItem;
+import gregtech.api.objects.XSTR;
+import gregtech.api.util.GT_Config;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.gui.modularui.uifactory.SelectItemUIFactory;
+
public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetworkUpdatableItem {
+
private static final String aTextEmptyRow = " ";
private static final List<ItemStack> ALL_VARIANTS = new ArrayList<>();
protected IIcon[] mIconDamage = new IIcon[25];
@@ -64,81 +69,105 @@ public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetwo
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Circuit_Integrated.getWithDamage(1L, 0L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {OrePrefixes.circuit.get(Materials.Basic)});
+ new Object[] { OrePrefixes.circuit.get(Materials.Basic) });
long bits = GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE;
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 1L), bits, new Object[] {
- "d ", " P ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 2L), bits, new Object[] {
- " d ", " P ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 3L), bits, new Object[] {
- " d", " P ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 4L), bits, new Object[] {
- aTextEmptyRow, " Pd", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 5L), bits, new Object[] {
- aTextEmptyRow, " P ", " d", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 6L), bits, new Object[] {
- aTextEmptyRow, " P ", " d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 7L), bits, new Object[] {
- aTextEmptyRow, " P ", "d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 8L), bits, new Object[] {
- aTextEmptyRow, "dP ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 1L),
+ bits,
+ new Object[] { "d ", " P ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 2L),
+ bits,
+ new Object[] { " d ", " P ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 3L),
+ bits,
+ new Object[] { " d", " P ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 4L),
+ bits,
+ new Object[] { aTextEmptyRow, " Pd", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 5L),
+ bits,
+ new Object[] { aTextEmptyRow, " P ", " d", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 6L),
+ bits,
+ new Object[] { aTextEmptyRow, " P ", " d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 7L),
+ bits,
+ new Object[] { aTextEmptyRow, " P ", "d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 8L),
+ bits,
+ new Object[] { aTextEmptyRow, "dP ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 9L), bits, new Object[] {
- "P d", aTextEmptyRow, aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 10L), bits, new Object[] {
- "P ", " d", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 11L), bits, new Object[] {
- "P ", aTextEmptyRow, " d", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 12L), bits, new Object[] {
- "P ", aTextEmptyRow, " d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 13L), bits, new Object[] {
- " P", aTextEmptyRow, " d", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 14L), bits, new Object[] {
- " P", aTextEmptyRow, " d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 15L), bits, new Object[] {
- " P", aTextEmptyRow, "d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 16L), bits, new Object[] {
- " P", "d ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 17L), bits, new Object[] {
- aTextEmptyRow, aTextEmptyRow, "d P", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 18L), bits, new Object[] {
- aTextEmptyRow, "d ", " P", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 19L), bits, new Object[] {
- "d ", aTextEmptyRow, " P", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 20L), bits, new Object[] {
- " d ", aTextEmptyRow, " P", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 21L), bits, new Object[] {
- "d ", aTextEmptyRow, "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 22L), bits, new Object[] {
- " d ", aTextEmptyRow, "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 23L), bits, new Object[] {
- " d", aTextEmptyRow, "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
- GT_ModHandler.addCraftingRecipe(ItemList.Circuit_Integrated.getWithDamage(1L, 24L), bits, new Object[] {
- aTextEmptyRow, " d", "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L)
- });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 9L),
+ bits,
+ new Object[] { "P d", aTextEmptyRow, aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 10L),
+ bits,
+ new Object[] { "P ", " d", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 11L),
+ bits,
+ new Object[] { "P ", aTextEmptyRow, " d", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 12L),
+ bits,
+ new Object[] { "P ", aTextEmptyRow, " d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 13L),
+ bits,
+ new Object[] { " P", aTextEmptyRow, " d", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 14L),
+ bits,
+ new Object[] { " P", aTextEmptyRow, " d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 15L),
+ bits,
+ new Object[] { " P", aTextEmptyRow, "d ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 16L),
+ bits,
+ new Object[] { " P", "d ", aTextEmptyRow, 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 17L),
+ bits,
+ new Object[] { aTextEmptyRow, aTextEmptyRow, "d P", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 18L),
+ bits,
+ new Object[] { aTextEmptyRow, "d ", " P", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 19L),
+ bits,
+ new Object[] { "d ", aTextEmptyRow, " P", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 20L),
+ bits,
+ new Object[] { " d ", aTextEmptyRow, " P", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 21L),
+ bits,
+ new Object[] { "d ", aTextEmptyRow, "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 22L),
+ bits,
+ new Object[] { " d ", aTextEmptyRow, "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 23L),
+ bits,
+ new Object[] { " d", aTextEmptyRow, "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.Circuit_Integrated.getWithDamage(1L, 24L),
+ bits,
+ new Object[] { aTextEmptyRow, " d", "P ", 'P', ItemList.Circuit_Integrated.getWildcard(1L) });
}
private static String getModeString(int aMetaData) {
@@ -164,25 +193,18 @@ public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetwo
@Override
public void addAdditionalToolTips(List<String> aList, ItemStack aStack, EntityPlayer aPlayer) {
super.addAdditionalToolTips(aList, aStack, aPlayer);
- aList.add(GT_LanguageManager.addStringLocalization(
- new StringBuilder()
- .append(getUnlocalizedName())
- .append(".configuration")
- .toString(),
- "Configuration: ")
- + getConfigurationString(getDamage(aStack)));
- aList.add(GT_LanguageManager.addStringLocalization(
- new StringBuilder()
- .append(getUnlocalizedName())
- .append(".tooltip.0")
- .toString(),
- "Right click to reconfigure"));
- aList.add(GT_LanguageManager.addStringLocalization(
- new StringBuilder()
- .append(getUnlocalizedName())
- .append(".tooltip.1")
- .toString(),
- "Needs a screwdriver or circuit programming tool"));
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ new StringBuilder().append(getUnlocalizedName()).append(".configuration").toString(),
+ "Configuration: ") + getConfigurationString(getDamage(aStack)));
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ new StringBuilder().append(getUnlocalizedName()).append(".tooltip.0").toString(),
+ "Right click to reconfigure"));
+ aList.add(
+ GT_LanguageManager.addStringLocalization(
+ new StringBuilder().append(getUnlocalizedName()).append(".tooltip.1").toString(),
+ "Needs a screwdriver or circuit programming tool"));
}
@Override
@@ -201,8 +223,8 @@ public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetwo
public void registerIcons(IIconRegister aIconRegister) {
super.registerIcons(aIconRegister);
for (int i = 0; i < mIconDamage.length; i++) {
- mIconDamage[i] = aIconRegister.registerIcon(
- RES_PATH_ITEM + (GT_Config.troll ? "troll" : getUnlocalizedName() + "/" + i));
+ mIconDamage[i] = aIconRegister
+ .registerIcon(RES_PATH_ITEM + (GT_Config.troll ? "troll" : getUnlocalizedName() + "/" + i));
}
if (GregTech_API.sPostloadFinished) {
GT_Log.out.println("GT_Mod: Starting Item Icon Load Phase");
@@ -259,13 +281,15 @@ public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetwo
count = Integer.parseInt(
StatCollector.translateToLocal("GT5U.item.programmed_circuit.no_screwdriver.count"));
} catch (NumberFormatException e) {
- player.addChatComponentMessage(new ChatComponentText(
- "Error in translation GT5U.item.programmed_circuit.no_screwdriver.count: "
- + e.getMessage()));
+ player.addChatComponentMessage(
+ new ChatComponentText(
+ "Error in translation GT5U.item.programmed_circuit.no_screwdriver.count: "
+ + e.getMessage()));
count = 1;
}
- player.addChatComponentMessage(new ChatComponentTranslation(
- "GT5U.item.programmed_circuit.no_screwdriver." + XSTR.XSTR_INSTANCE.nextInt(count)));
+ player.addChatComponentMessage(
+ new ChatComponentTranslation(
+ "GT5U.item.programmed_circuit.no_screwdriver." + XSTR.XSTR_INSTANCE.nextInt(count)));
return stack;
}
configuratorStack = player.inventory.mainInventory[configurator.getKey()];
@@ -275,14 +299,15 @@ public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetwo
}
private void openSelectorGui(ItemStack configurator, int meta, EntityPlayer player) {
- UIInfos.openClientUI(player, buildContext -> new SelectItemUIFactory(
+ UIInfos.openClientUI(
+ player,
+ buildContext -> new SelectItemUIFactory(
StatCollector.translateToLocal("GT5U.item.programmed_circuit.select.header"),
configurator,
GT_IntegratedCircuit_Item::onConfigured,
ALL_VARIANTS,
meta,
- true)
- .createWindow(buildContext));
+ true).createWindow(buildContext));
}
private static void onConfigured(ItemStack stack) {
@@ -299,8 +324,8 @@ public class GT_IntegratedCircuit_Item extends GT_Generic_Item implements INetwo
if (!GT_Utility.isStackValid(toolStack)) continue;
- for (Map.Entry<Predicate<ItemStack>, BiFunction<ItemStack, EntityPlayerMP, ItemStack>> p :
- GregTech_API.sCircuitProgrammerList.entrySet())
+ for (Map.Entry<Predicate<ItemStack>, BiFunction<ItemStack, EntityPlayerMP, ItemStack>> p : GregTech_API.sCircuitProgrammerList
+ .entrySet())
if (p.getKey().test(toolStack)) return Pair.of(j, p.getValue());
}
return null;
diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java
index e6882c4977..2abb7ff209 100644
--- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java
+++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java
@@ -2,6 +2,23 @@ package gregtech.common.items;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import net.minecraft.block.Block;
+import net.minecraft.enchantment.Enchantment;
+import net.minecraft.entity.item.EntityItem;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.init.Items;
+import net.minecraft.item.EnumAction;
+import net.minecraft.item.ItemStack;
+import net.minecraft.potion.Potion;
+import net.minecraft.util.MathHelper;
+import net.minecraftforge.oredict.OreDictionary;
+
import cpw.mods.fml.common.Loader;
import gregtech.api.GregTech_API;
import gregtech.api.enums.Dyes;
@@ -27,26 +44,12 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.common.covers.*;
import gregtech.common.items.behaviors.*;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import net.minecraft.block.Block;
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.EnumAction;
-import net.minecraft.item.ItemStack;
-import net.minecraft.potion.Potion;
-import net.minecraft.util.MathHelper;
-import net.minecraftforge.oredict.OreDictionary;
public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
+
public static GT_MetaGenerated_Item_01 INSTANCE;
- private final String mToolTipPurify = GT_LanguageManager.addStringLocalization(
- "metaitem.01.tooltip.purify", "Throw into Cauldron to get clean Dust");
+ private final String mToolTipPurify = GT_LanguageManager
+ .addStringLocalization("metaitem.01.tooltip.purify", "Throw into Cauldron to get clean Dust");
private static final String aTextArrow = " A";
private static final String aTextStick = " S ";
private static final String aTextFeather = "F ";
@@ -57,8 +60,7 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
private static final String PartNotCoverText = "Cannot be used as a Cover";
private static final String RAText = "Grabs from and inserts into specific slots";
private static final String FRText1 = "Configurable up to ";
- private static final String FRText2 =
- " L/sec (as Cover)/n Rightclick/Screwdriver-rightclick/Shift-screwdriver-rightclick/n to adjust the pump speed by 1/16/256 L/sec per click";
+ private static final String FRText2 = " L/sec (as Cover)/n Rightclick/Screwdriver-rightclick/Shift-screwdriver-rightclick/n to adjust the pump speed by 1/16/256 L/sec per click";
public GT_MetaGenerated_Item_01() {
super(
@@ -112,805 +114,560 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemStack tStack = new ItemStack(this, 1, 17000 + Materials.Wood.mMetaItemSubID);
tStack.setStackDisplayName("The holy Planks of Sengir");
GT_Utility.ItemNBT.addEnchantment(tStack, Enchantment.smite, 10);
- GT_ModHandler.addCraftingRecipe(tStack, GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] {
- "XXX",
- "XDX",
- "XXX",
- 'X',
- OrePrefixes.gem.get(Materials.NetherStar),
- 'D',
- new ItemStack(Blocks.dragon_egg, 1, 32767)
- });
+ GT_ModHandler.addCraftingRecipe(
+ tStack,
+ GT_ModHandler.RecipeBits.NOT_REMOVABLE,
+ new Object[] { "XXX", "XDX", "XXX", 'X', OrePrefixes.gem.get(Materials.NetherStar), 'D',
+ new ItemStack(Blocks.dragon_egg, 1, 32767) });
ItemList.Credit_Greg_Copper.set(addItem(tLastID = 0, "Copper GT Credit", "0.125 Credits"));
- ItemList.Credit_Greg_Cupronickel.set(addItem(
- tLastID = 1, "Cupronickel GT Credit", "1 Credit", new ItemData(Materials.Cupronickel, 907200L)));
- ItemList.Credit_Greg_Silver.set(addItem(
- tLastID = 2, "Silver GT Credit", "8 Credits", new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Credit_Greg_Cupronickel.set(
+ addItem(
+ tLastID = 1,
+ "Cupronickel GT Credit",
+ "1 Credit",
+ new ItemData(Materials.Cupronickel, 907200L)));
+ ItemList.Credit_Greg_Silver.set(
+ addItem(
+ tLastID = 2,
+ "Silver GT Credit",
+ "8 Credits",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
ItemList.Credit_Greg_Gold.set(addItem(tLastID = 3, "Gold GT Credit", "64 Credits"));
ItemList.Credit_Greg_Platinum.set(addItem(tLastID = 4, "Platinum GT Credit", "512 Credits"));
ItemList.Credit_Greg_Osmium.set(addItem(tLastID = 5, "Osmium GT Credit", "4,096 Credits"));
ItemList.Credit_Greg_Naquadah.set(addItem(tLastID = 6, "Naquadah GT Credit", "32,768 Credits"));
ItemList.Credit_Greg_Neutronium.set(addItem(tLastID = 7, "Neutronium GT Credit", "262,144 Credits"));
- ItemList.Coin_Gold_Ancient.set(addItem(
- tLastID = 8,
- "Ancient Gold Coin",
- "Found in ancient Ruins",
- new ItemData(Materials.Gold, 907200L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 8L)));
- ItemList.Coin_Doge.set(addItem(
- tLastID = 9,
- "Doge Coin",
- "wow much coin how money so crypto plz mine v rich very currency wow",
- new ItemData(Materials.Brass, 907200L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
- ItemList.Coin_Chocolate.set(addItem(
- tLastID = 10,
- "Chocolate Coin",
- "Wrapped in Gold",
- new ItemData(Materials.Gold, OrePrefixes.foil.mMaterialAmount),
- new GT_FoodStat(
- 1,
- 0.1F,
- EnumAction.eat,
- GT_OreDictUnificator.get(OrePrefixes.foil, Materials.Gold, 1L),
- true,
- false,
- false,
- Potion.moveSpeed.id,
- 200,
- 1,
- 100)));
+ ItemList.Coin_Gold_Ancient.set(
+ addItem(
+ tLastID = 8,
+ "Ancient Gold Coin",
+ "Found in ancient Ruins",
+ new ItemData(Materials.Gold, 907200L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 8L)));
+ ItemList.Coin_Doge.set(
+ addItem(
+ tLastID = 9,
+ "Doge Coin",
+ "wow much coin how money so crypto plz mine v rich very currency wow",
+ new ItemData(Materials.Brass, 907200L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Coin_Chocolate.set(
+ addItem(
+ tLastID = 10,
+ "Chocolate Coin",
+ "Wrapped in Gold",
+ new ItemData(Materials.Gold, OrePrefixes.foil.mMaterialAmount),
+ new GT_FoodStat(
+ 1,
+ 0.1F,
+ EnumAction.eat,
+ GT_OreDictUnificator.get(OrePrefixes.foil, Materials.Gold, 1L),
+ true,
+ false,
+ false,
+ Potion.moveSpeed.id,
+ 200,
+ 1,
+ 100)));
ItemList.Credit_Copper.set(addItem(tLastID = 11, "Industrial Copper Credit", "0.125 Credits"));
- ItemList.Credit_Silver.set(addItem(
- tLastID = 13,
- "Industrial Silver Credit",
- "8 Credits",
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Credit_Silver.set(
+ addItem(
+ tLastID = 13,
+ "Industrial Silver Credit",
+ "8 Credits",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
ItemList.Credit_Gold.set(addItem(tLastID = 14, "Industrial Gold Credit", "64 Credits"));
ItemList.Credit_Platinum.set(addItem(tLastID = 15, "Industrial Platinum Credit", "512 Credits"));
ItemList.Credit_Osmium.set(addItem(tLastID = 16, "Industrial Osmium Credit", "4096 Credits"));
- GT_ModHandler.addShapelessCraftingRecipe(ItemList.Coin_Chocolate.get(1L), new Object[] {
- OrePrefixes.dust.get(Materials.Cocoa),
- OrePrefixes.dust.get(Materials.Milk),
- OrePrefixes.dust.get(Materials.Sugar),
- OrePrefixes.foil.get(Materials.Gold)
- });
+ GT_ModHandler.addShapelessCraftingRecipe(
+ ItemList.Coin_Chocolate.get(1L),
+ new Object[] { OrePrefixes.dust.get(Materials.Cocoa), OrePrefixes.dust.get(Materials.Milk),
+ OrePrefixes.dust.get(Materials.Sugar), OrePrefixes.foil.get(Materials.Gold) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Copper.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Iron});
+ new Object[] { ItemList.Credit_Iron });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Iron.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Silver});
+ new Object[] { ItemList.Credit_Silver });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Silver.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Gold});
+ new Object[] { ItemList.Credit_Gold });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Gold.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Platinum});
+ new Object[] { ItemList.Credit_Platinum });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Platinum.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Osmium});
+ new Object[] { ItemList.Credit_Osmium });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Iron.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Copper,
- ItemList.Credit_Copper,
- ItemList.Credit_Copper,
- ItemList.Credit_Copper,
- ItemList.Credit_Copper,
- ItemList.Credit_Copper,
- ItemList.Credit_Copper,
- ItemList.Credit_Copper
- });
+ new Object[] { ItemList.Credit_Copper, ItemList.Credit_Copper, ItemList.Credit_Copper,
+ ItemList.Credit_Copper, ItemList.Credit_Copper, ItemList.Credit_Copper, ItemList.Credit_Copper,
+ ItemList.Credit_Copper });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Silver.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Iron,
- ItemList.Credit_Iron,
- ItemList.Credit_Iron,
- ItemList.Credit_Iron,
- ItemList.Credit_Iron,
- ItemList.Credit_Iron,
- ItemList.Credit_Iron,
- ItemList.Credit_Iron
- });
+ new Object[] { ItemList.Credit_Iron, ItemList.Credit_Iron, ItemList.Credit_Iron, ItemList.Credit_Iron,
+ ItemList.Credit_Iron, ItemList.Credit_Iron, ItemList.Credit_Iron, ItemList.Credit_Iron });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Gold.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Silver,
- ItemList.Credit_Silver,
- ItemList.Credit_Silver,
- ItemList.Credit_Silver,
- ItemList.Credit_Silver,
- ItemList.Credit_Silver,
- ItemList.Credit_Silver,
- ItemList.Credit_Silver
- });
+ new Object[] { ItemList.Credit_Silver, ItemList.Credit_Silver, ItemList.Credit_Silver,
+ ItemList.Credit_Silver, ItemList.Credit_Silver, ItemList.Credit_Silver, ItemList.Credit_Silver,
+ ItemList.Credit_Silver });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Platinum.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Gold,
- ItemList.Credit_Gold,
- ItemList.Credit_Gold,
- ItemList.Credit_Gold,
- ItemList.Credit_Gold,
- ItemList.Credit_Gold,
- ItemList.Credit_Gold,
- ItemList.Credit_Gold
- });
+ new Object[] { ItemList.Credit_Gold, ItemList.Credit_Gold, ItemList.Credit_Gold, ItemList.Credit_Gold,
+ ItemList.Credit_Gold, ItemList.Credit_Gold, ItemList.Credit_Gold, ItemList.Credit_Gold });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Osmium.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum,
- ItemList.Credit_Platinum
- });
+ new Object[] { ItemList.Credit_Platinum, ItemList.Credit_Platinum, ItemList.Credit_Platinum,
+ ItemList.Credit_Platinum, ItemList.Credit_Platinum, ItemList.Credit_Platinum,
+ ItemList.Credit_Platinum, ItemList.Credit_Platinum });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Copper.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Cupronickel});
+ new Object[] { ItemList.Credit_Greg_Cupronickel });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Cupronickel.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Silver});
+ new Object[] { ItemList.Credit_Greg_Silver });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Silver.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Gold});
+ new Object[] { ItemList.Credit_Greg_Gold });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Gold.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Platinum});
+ new Object[] { ItemList.Credit_Greg_Platinum });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Platinum.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Osmium});
+ new Object[] { ItemList.Credit_Greg_Osmium });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Osmium.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Naquadah});
+ new Object[] { ItemList.Credit_Greg_Naquadah });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Naquadah.get(8L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Credit_Greg_Neutronium});
+ new Object[] { ItemList.Credit_Greg_Neutronium });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Cupronickel.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper,
- ItemList.Credit_Greg_Copper
- });
+ new Object[] { ItemList.Credit_Greg_Copper, ItemList.Credit_Greg_Copper, ItemList.Credit_Greg_Copper,
+ ItemList.Credit_Greg_Copper, ItemList.Credit_Greg_Copper, ItemList.Credit_Greg_Copper,
+ ItemList.Credit_Greg_Copper, ItemList.Credit_Greg_Copper });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Silver.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel,
- ItemList.Credit_Greg_Cupronickel
- });
+ new Object[] { ItemList.Credit_Greg_Cupronickel, ItemList.Credit_Greg_Cupronickel,
+ ItemList.Credit_Greg_Cupronickel, ItemList.Credit_Greg_Cupronickel,
+ ItemList.Credit_Greg_Cupronickel, ItemList.Credit_Greg_Cupronickel,
+ ItemList.Credit_Greg_Cupronickel, ItemList.Credit_Greg_Cupronickel });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Gold.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver,
- ItemList.Credit_Greg_Silver
- });
+ new Object[] { ItemList.Credit_Greg_Silver, ItemList.Credit_Greg_Silver, ItemList.Credit_Greg_Silver,
+ ItemList.Credit_Greg_Silver, ItemList.Credit_Greg_Silver, ItemList.Credit_Greg_Silver,
+ ItemList.Credit_Greg_Silver, ItemList.Credit_Greg_Silver });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Platinum.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold,
- ItemList.Credit_Greg_Gold
- });
+ new Object[] { ItemList.Credit_Greg_Gold, ItemList.Credit_Greg_Gold, ItemList.Credit_Greg_Gold,
+ ItemList.Credit_Greg_Gold, ItemList.Credit_Greg_Gold, ItemList.Credit_Greg_Gold,
+ ItemList.Credit_Greg_Gold, ItemList.Credit_Greg_Gold });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Osmium.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum,
- ItemList.Credit_Greg_Platinum
- });
+ new Object[] { ItemList.Credit_Greg_Platinum, ItemList.Credit_Greg_Platinum,
+ ItemList.Credit_Greg_Platinum, ItemList.Credit_Greg_Platinum, ItemList.Credit_Greg_Platinum,
+ ItemList.Credit_Greg_Platinum, ItemList.Credit_Greg_Platinum, ItemList.Credit_Greg_Platinum });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Naquadah.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium,
- ItemList.Credit_Greg_Osmium
- });
+ new Object[] { ItemList.Credit_Greg_Osmium, ItemList.Credit_Greg_Osmium, ItemList.Credit_Greg_Osmium,
+ ItemList.Credit_Greg_Osmium, ItemList.Credit_Greg_Osmium, ItemList.Credit_Greg_Osmium,
+ ItemList.Credit_Greg_Osmium, ItemList.Credit_Greg_Osmium });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Credit_Greg_Neutronium.get(1L),
GT_ModHandler.RecipeBits.KEEPNBT | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah,
- ItemList.Credit_Greg_Naquadah
- });
-
- ItemList.Component_Minecart_Wheels_Iron.set(addItem(
- tLastID = 100,
- "Iron Minecart Wheels",
- "To get things rolling",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L)));
- ItemList.Component_Minecart_Wheels_Steel.set(addItem(
- tLastID = 101,
- "Steel Minecart Wheels",
- "To get things rolling",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L)));
+ new Object[] { ItemList.Credit_Greg_Naquadah, ItemList.Credit_Greg_Naquadah,
+ ItemList.Credit_Greg_Naquadah, ItemList.Credit_Greg_Naquadah, ItemList.Credit_Greg_Naquadah,
+ ItemList.Credit_Greg_Naquadah, ItemList.Credit_Greg_Naquadah, ItemList.Credit_Greg_Naquadah });
+
+ ItemList.Component_Minecart_Wheels_Iron.set(
+ addItem(
+ tLastID = 100,
+ "Iron Minecart Wheels",
+ "To get things rolling",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L)));
+ ItemList.Component_Minecart_Wheels_Steel.set(
+ addItem(
+ tLastID = 101,
+ "Steel Minecart Wheels",
+ "To get things rolling",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Component_Minecart_Wheels_Iron.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- " h ",
- "RSR",
- " w ",
- 'R',
- OrePrefixes.ring.get(Materials.AnyIron),
- 'S',
- OrePrefixes.stick.get(Materials.AnyIron)
- });
+ new Object[] { " h ", "RSR", " w ", 'R', OrePrefixes.ring.get(Materials.AnyIron), 'S',
+ OrePrefixes.stick.get(Materials.AnyIron) });
GT_ModHandler.addCraftingRecipe(
ItemList.Component_Minecart_Wheels_Steel.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- " h ",
- "RSR",
- " w ",
- 'R',
- OrePrefixes.ring.get(Materials.Steel),
- 'S',
- OrePrefixes.stick.get(Materials.Steel)
- });
+ new Object[] { " h ", "RSR", " w ", 'R', OrePrefixes.ring.get(Materials.Steel), 'S',
+ OrePrefixes.stick.get(Materials.Steel) });
ItemList.CompressedFireclay.set(addItem(tLastID = 110, "Compressed Fireclay", "Brick-shaped"));
ItemList.Firebrick.set(addItem(tLastID = 111, "Firebrick", "Heat resistant"));
- ItemList.Arrow_Head_Glass_Emtpy.set(addItem(
- tLastID = 200,
- "Empty Glass Arrow Head",
- "Fill with Potions before use",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Arrow_Head_Glass_Poison.set(addItem(
- tLastID = 201,
- "Poison Glass Arrow Head",
- "Glass Arrow filled with Poison",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Poison_Long.set(addItem(
- tLastID = 202,
- "Poison Glass Arrow Head",
- "Glass Arrow filled with stretched Poison",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Poison_Strong.set(addItem(
- tLastID = 203,
- "Poison Glass Arrow Head",
- "Glass Arrow filled with strong Poison",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Slowness.set(addItem(
- tLastID = 204,
- "Slowness Glass Arrow Head",
- "Glass Arrow filled with Laming Brew",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Slowness_Long.set(addItem(
- tLastID = 205,
- "Slowness Glass Arrow Head",
- "Glass Arrow filled with stretched Laming Brew",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Weakness.set(addItem(
- tLastID = 206,
- "Weakness Glass Arrow Head",
- "Glass Arrow filled with Weakening Brew",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Weakness_Long.set(addItem(
- tLastID = 207,
- "Weakness Glass Arrow Head",
- "Glass Arrow filled with stretched Weakening Brew",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Head_Glass_Holy_Water.set(addItem(
- tLastID = 208,
- "Holy Water Glass Arrow Head",
- "Glass Arrow filled with Holy Water",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
-
- ItemList.Arrow_Wooden_Glass_Emtpy.set(addItem(
- tLastID = 225,
- "Regular Glass Vial Arrow",
- "Empty Glass Arrow",
- new Behaviour_Arrow_Potion(1.0F, 6.0F),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Arrow_Wooden_Glass_Poison.set(addItem(
- tLastID = 226,
- "Regular Poison Arrow",
- "Glass Arrow filled with Poison",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 450, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Poison_Long.set(addItem(
- tLastID = 227,
- "Regular Poison Arrow",
- "Glass Arrow filled with stretched Poison",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 900, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Poison_Strong.set(addItem(
- tLastID = 228,
- "Regular Poison Arrow",
- "Glass Arrow filled with strong Poison",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 450, 1, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Slowness.set(addItem(
- tLastID = 229,
- "Regular Slowness Arrow",
- "Glass Arrow filled with Laming Brew",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.moveSlowdown.id, 900, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Slowness_Long.set(addItem(
- tLastID = 230,
- "Regular Slowness Arrow",
- "Glass Arrow filled with stretched Laming Brew",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.moveSlowdown.id, 1800, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Weakness.set(addItem(
- tLastID = 231,
- "Regular Weakness Arrow",
- "Glass Arrow filled with Weakening Brew",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.weakness.id, 900, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Weakness_Long.set(addItem(
- tLastID = 232,
- "Regular Weakness Arrow",
- "Glass Arrow filled with stretched Weakening Brew",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.weakness.id, 1800, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Wooden_Glass_Holy_Water.set(addItem(
- tLastID = 233,
- "Regular Holy Water Arrow",
- "Glass Arrow filled with Holy Water",
- new Behaviour_Arrow_Potion(1.0F, 6.0F, Enchantment.smite, 10),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
-
- ItemList.Arrow_Plastic_Glass_Emtpy.set(addItem(
- tLastID = 250,
- "Light Glass Vial Arrow",
- "Empty Glass Arrow",
- new Behaviour_Arrow_Potion(1.5F, 6.0F),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Arrow_Plastic_Glass_Poison.set(addItem(
- tLastID = 251,
- "Light Poison Arrow",
- "Glass Arrow filled with Poison",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 450, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Poison_Long.set(addItem(
- tLastID = 252,
- "Light Poison Arrow",
- "Glass Arrow filled with stretched Poison",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 900, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Poison_Strong.set(addItem(
- tLastID = 253,
- "Light Poison Arrow",
- "Glass Arrow filled with strong Poison",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 450, 1, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Slowness.set(addItem(
- tLastID = 254,
- "Light Slowness Arrow",
- "Glass Arrow filled with Laming Brew",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.moveSlowdown.id, 900, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Slowness_Long.set(addItem(
- tLastID = 255,
- "Light Slowness Arrow",
- "Glass Arrow filled with stretched Laming Brew",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.moveSlowdown.id, 1800, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Weakness.set(addItem(
- tLastID = 256,
- "Light Weakness Arrow",
- "Glass Arrow filled with Weakening Brew",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.weakness.id, 900, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Weakness_Long.set(addItem(
- tLastID = 257,
- "Light Weakness Arrow",
- "Glass Arrow filled with stretched Weakening Brew",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.weakness.id, 1800, 0, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
- ItemList.Arrow_Plastic_Glass_Holy_Water.set(addItem(
- tLastID = 258,
- "Light Holy Water Arrow",
- "Glass Arrow filled with Holy Water",
- new Behaviour_Arrow_Potion(1.5F, 6.0F, Enchantment.smite, 10),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
+ ItemList.Arrow_Head_Glass_Emtpy.set(
+ addItem(
+ tLastID = 200,
+ "Empty Glass Arrow Head",
+ "Fill with Potions before use",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Arrow_Head_Glass_Poison.set(
+ addItem(
+ tLastID = 201,
+ "Poison Glass Arrow Head",
+ "Glass Arrow filled with Poison",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Poison_Long.set(
+ addItem(
+ tLastID = 202,
+ "Poison Glass Arrow Head",
+ "Glass Arrow filled with stretched Poison",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Poison_Strong.set(
+ addItem(
+ tLastID = 203,
+ "Poison Glass Arrow Head",
+ "Glass Arrow filled with strong Poison",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Slowness.set(
+ addItem(
+ tLastID = 204,
+ "Slowness Glass Arrow Head",
+ "Glass Arrow filled with Laming Brew",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Slowness_Long.set(
+ addItem(
+ tLastID = 205,
+ "Slowness Glass Arrow Head",
+ "Glass Arrow filled with stretched Laming Brew",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Weakness.set(
+ addItem(
+ tLastID = 206,
+ "Weakness Glass Arrow Head",
+ "Glass Arrow filled with Weakening Brew",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Weakness_Long.set(
+ addItem(
+ tLastID = 207,
+ "Weakness Glass Arrow Head",
+ "Glass Arrow filled with stretched Weakening Brew",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Head_Glass_Holy_Water.set(
+ addItem(
+ tLastID = 208,
+ "Holy Water Glass Arrow Head",
+ "Glass Arrow filled with Holy Water",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
+
+ ItemList.Arrow_Wooden_Glass_Emtpy.set(
+ addItem(
+ tLastID = 225,
+ "Regular Glass Vial Arrow",
+ "Empty Glass Arrow",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Arrow_Wooden_Glass_Poison.set(
+ addItem(
+ tLastID = 226,
+ "Regular Poison Arrow",
+ "Glass Arrow filled with Poison",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 450, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Poison_Long.set(
+ addItem(
+ tLastID = 227,
+ "Regular Poison Arrow",
+ "Glass Arrow filled with stretched Poison",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 900, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Poison_Strong.set(
+ addItem(
+ tLastID = 228,
+ "Regular Poison Arrow",
+ "Glass Arrow filled with strong Poison",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 450, 1, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Slowness.set(
+ addItem(
+ tLastID = 229,
+ "Regular Slowness Arrow",
+ "Glass Arrow filled with Laming Brew",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.moveSlowdown.id, 900, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Slowness_Long.set(
+ addItem(
+ tLastID = 230,
+ "Regular Slowness Arrow",
+ "Glass Arrow filled with stretched Laming Brew",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.moveSlowdown.id, 1800, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Weakness.set(
+ addItem(
+ tLastID = 231,
+ "Regular Weakness Arrow",
+ "Glass Arrow filled with Weakening Brew",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.weakness.id, 900, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Weakness_Long.set(
+ addItem(
+ tLastID = 232,
+ "Regular Weakness Arrow",
+ "Glass Arrow filled with stretched Weakening Brew",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.weakness.id, 1800, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Wooden_Glass_Holy_Water.set(
+ addItem(
+ tLastID = 233,
+ "Regular Holy Water Arrow",
+ "Glass Arrow filled with Holy Water",
+ new Behaviour_Arrow_Potion(1.0F, 6.0F, Enchantment.smite, 10),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
+
+ ItemList.Arrow_Plastic_Glass_Emtpy.set(
+ addItem(
+ tLastID = 250,
+ "Light Glass Vial Arrow",
+ "Empty Glass Arrow",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Arrow_Plastic_Glass_Poison.set(
+ addItem(
+ tLastID = 251,
+ "Light Poison Arrow",
+ "Glass Arrow filled with Poison",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 450, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Poison_Long.set(
+ addItem(
+ tLastID = 252,
+ "Light Poison Arrow",
+ "Glass Arrow filled with stretched Poison",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 900, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Poison_Strong.set(
+ addItem(
+ tLastID = 253,
+ "Light Poison Arrow",
+ "Glass Arrow filled with strong Poison",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 450, 1, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Slowness.set(
+ addItem(
+ tLastID = 254,
+ "Light Slowness Arrow",
+ "Glass Arrow filled with Laming Brew",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.moveSlowdown.id, 900, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Slowness_Long.set(
+ addItem(
+ tLastID = 255,
+ "Light Slowness Arrow",
+ "Glass Arrow filled with stretched Laming Brew",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.moveSlowdown.id, 1800, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Weakness.set(
+ addItem(
+ tLastID = 256,
+ "Light Weakness Arrow",
+ "Glass Arrow filled with Weakening Brew",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.weakness.id, 900, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Weakness_Long.set(
+ addItem(
+ tLastID = 257,
+ "Light Weakness Arrow",
+ "Glass Arrow filled with stretched Weakening Brew",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.weakness.id, 1800, 0, 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L)));
+ ItemList.Arrow_Plastic_Glass_Holy_Water.set(
+ addItem(
+ tLastID = 258,
+ "Light Holy Water Arrow",
+ "Glass Arrow filled with Holy Water",
+ new Behaviour_Arrow_Potion(1.5F, 6.0F, Enchantment.smite, 10),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Emtpy.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Emtpy,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Emtpy, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Poison.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Poison,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Poison_Long.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Poison_Long,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Long, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Poison_Strong.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Poison_Strong,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Strong, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Slowness.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Slowness,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Slowness_Long.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Slowness_Long,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness_Long, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Weakness.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Weakness,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Weakness, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Weakness_Long.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Weakness_Long,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Weakness_Long, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Wooden_Glass_Holy_Water.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Holy_Water,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Holy_Water, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Emtpy.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Emtpy,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Emtpy, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Poison.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Poison,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Poison_Long.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Poison_Long,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Long, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Poison_Strong.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Poison_Strong,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Strong, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Slowness.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Slowness,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Slowness_Long.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Slowness_Long,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness_Long, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Weakness.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Weakness,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Weakness, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Weakness_Long.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Weakness_Long,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Weakness_Long, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Arrow_Plastic_Glass_Holy_Water.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- aTextArrow,
- aTextStick,
- aTextFeather,
- 'A',
- ItemList.Arrow_Head_Glass_Holy_Water,
- 'F',
- OreDictNames.craftingFeather,
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
-
- ItemList.Shape_Empty.set(addItem(
- tLastID = 300,
- "Empty Shape Plate",
- "Raw Plate to make Molds and Extruder Shapes",
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L)));
+ new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Holy_Water, 'F',
+ OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) });
+
+ ItemList.Shape_Empty.set(
+ addItem(
+ tLastID = 300,
+ "Empty Shape Plate",
+ "Raw Plate to make Molds and Extruder Shapes",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L)));
// GT_ModHandler.addCraftingRecipe(ItemList.Shape_Empty.get(1L, new Object[0]),
// GT_ModHandler.RecipeBits.MIRRORED | GT_ModHandler.RecipeBits.BUFFERED |
@@ -920,8 +677,8 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemList.Shape_Mold_Plate.set(addItem(tLastID = 301, "Mold (Plate)", "Mold for making Plates"));
ItemList.Shape_Mold_Casing.set(addItem(tLastID = 302, "Mold (Casing)", "Mold for making Item Casings"));
ItemList.Shape_Mold_Gear.set(addItem(tLastID = 303, "Mold (Gear)", "Mold for making Gears"));
- ItemList.Shape_Mold_Credit.set(
- addItem(tLastID = 304, "Mold (Coinage)", "Secure Mold for making Coins (Don't lose it!)"));
+ ItemList.Shape_Mold_Credit
+ .set(addItem(tLastID = 304, "Mold (Coinage)", "Secure Mold for making Coins (Don't lose it!)"));
ItemList.Shape_Mold_Bottle.set(addItem(tLastID = 305, "Mold (Bottle)", "Mold for making Bottles"));
ItemList.Shape_Mold_Ingot.set(addItem(tLastID = 306, "Mold (Ingot)", "Mold for making Ingots"));
ItemList.Shape_Mold_Ball.set(addItem(tLastID = 307, "Mold (Ball)", "Mold for making Balls"));
@@ -932,8 +689,8 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemList.Shape_Mold_Baguette.set(addItem(tLastID = 312, "Mold (Baguette)", "Mold for shaping Baguettes"));
ItemList.Shape_Mold_Cylinder.set(addItem(tLastID = 313, "Mold (Cylinder)", "Mold for shaping Cylinders"));
ItemList.Shape_Mold_Anvil.set(addItem(tLastID = 314, "Mold (Anvil)", "Mold for shaping Anvils"));
- ItemList.Shape_Mold_Name.set(
- addItem(tLastID = 315, "Mold (Name)", "Mold for naming Items (rename Mold with Anvil)"));
+ ItemList.Shape_Mold_Name
+ .set(addItem(tLastID = 315, "Mold (Name)", "Mold for naming Items (rename Mold with Anvil)"));
ItemList.Shape_Mold_Arrow.set(addItem(tLastID = 316, "Mold (Arrow Head)", "Mold for making Arrow Heads"));
ItemList.Shape_Mold_Gear_Small.set(addItem(tLastID = 317, "Mold (Small Gear)", "Mold for making small Gears"));
ItemList.Shape_Mold_Rod.set(addItem(tLastID = 318, "Mold (Rod)", "Mold for making Rods"));
@@ -943,425 +700,398 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemList.Shape_Mold_Ring.set(addItem(tLastID = 322, "Mold (Ring)", "Mold for making Rings"));
ItemList.Shape_Mold_Rod_Long.set(addItem(tLastID = 323, "Mold (Long Rod)", "Mold for making Long Rods"));
ItemList.Shape_Mold_Rotor.set(addItem(tLastID = 324, "Mold (Rotor)", "Mold for making a Rotor"));
- ItemList.Shape_Mold_Turbine_Blade.set(
- addItem(tLastID = 325, "Mold (Turbine Blade)", "Mold for making a Turbine Blade"));
+ ItemList.Shape_Mold_Turbine_Blade
+ .set(addItem(tLastID = 325, "Mold (Turbine Blade)", "Mold for making a Turbine Blade"));
ItemList.Shape_Mold_Pipe_Tiny.set(addItem(tLastID = 326, "Mold (Tiny Pipe)", "Mold for making tiny Pipes"));
ItemList.Shape_Mold_Pipe_Small.set(addItem(tLastID = 327, "Mold (Small Pipe)", "Mold for making small Pipes"));
ItemList.Shape_Mold_Pipe_Medium.set(addItem(tLastID = 328, "Mold (Normal Pipe)", "Mold for making Pipes"));
ItemList.Shape_Mold_Pipe_Large.set(addItem(tLastID = 329, "Mold (Large Pipe)", "Mold for making large Pipes"));
- ItemList.Shape_Mold_Pipe_Huge.set(
- addItem(tLastID = 330, "Mold (Huge Pipe)", "Mold for making full Block Pipes"));
- ItemList.Shape_Mold_ToolHeadDrill.set(
- addItem(tLastID = 331, "Mold (Drill Head)", "Mold for making Drill Heads"));
+ ItemList.Shape_Mold_Pipe_Huge
+ .set(addItem(tLastID = 330, "Mold (Huge Pipe)", "Mold for making full Block Pipes"));
+ ItemList.Shape_Mold_ToolHeadDrill
+ .set(addItem(tLastID = 331, "Mold (Drill Head)", "Mold for making Drill Heads"));
GT_ModHandler.removeRecipe(
- new ItemStack(Blocks.glass), null, new ItemStack(Blocks.glass), null, new ItemStack(Blocks.glass));
-
- ItemList.Shape_Extruder_Plate.set(
- addItem(tLastID = 350, "Extruder Shape (Plate)", "Extruder Shape for making Plates"));
- ItemList.Shape_Extruder_Rod.set(
- addItem(tLastID = 351, "Extruder Shape (Rod)", "Extruder Shape for making Rods"));
- ItemList.Shape_Extruder_Bolt.set(
- addItem(tLastID = 352, "Extruder Shape (Bolt)", "Extruder Shape for making Bolts"));
- ItemList.Shape_Extruder_Ring.set(
- addItem(tLastID = 353, "Extruder Shape (Ring)", "Extruder Shape for making Rings"));
- ItemList.Shape_Extruder_Cell.set(
- addItem(tLastID = 354, "Extruder Shape (Cell)", "Extruder Shape for making Cells"));
- ItemList.Shape_Extruder_Ingot.set(addItem(
- tLastID = 355, "Extruder Shape (Ingot)", "Extruder Shape for, wait, can't we just use a Furnace?"));
- ItemList.Shape_Extruder_Wire.set(
- addItem(tLastID = 356, "Extruder Shape (Wire)", "Extruder Shape for making Wires"));
- ItemList.Shape_Extruder_Casing.set(
- addItem(tLastID = 357, "Extruder Shape (Casing)", "Extruder Shape for making Item Casings"));
- ItemList.Shape_Extruder_Pipe_Tiny.set(
- addItem(tLastID = 358, "Extruder Shape (Tiny Pipe)", "Extruder Shape for making tiny Pipes"));
- ItemList.Shape_Extruder_Pipe_Small.set(
- addItem(tLastID = 359, "Extruder Shape (Small Pipe)", "Extruder Shape for making small Pipes"));
- ItemList.Shape_Extruder_Pipe_Medium.set(
- addItem(tLastID = 360, "Extruder Shape (Normal Pipe)", "Extruder Shape for making Pipes"));
- ItemList.Shape_Extruder_Pipe_Large.set(
- addItem(tLastID = 361, "Extruder Shape (Large Pipe)", "Extruder Shape for making large Pipes"));
+ new ItemStack(Blocks.glass),
+ null,
+ new ItemStack(Blocks.glass),
+ null,
+ new ItemStack(Blocks.glass));
+
+ ItemList.Shape_Extruder_Plate
+ .set(addItem(tLastID = 350, "Extruder Shape (Plate)", "Extruder Shape for making Plates"));
+ ItemList.Shape_Extruder_Rod
+ .set(addItem(tLastID = 351, "Extruder Shape (Rod)", "Extruder Shape for making Rods"));
+ ItemList.Shape_Extruder_Bolt
+ .set(addItem(tLastID = 352, "Extruder Shape (Bolt)", "Extruder Shape for making Bolts"));
+ ItemList.Shape_Extruder_Ring
+ .set(addItem(tLastID = 353, "Extruder Shape (Ring)", "Extruder Shape for making Rings"));
+ ItemList.Shape_Extruder_Cell
+ .set(addItem(tLastID = 354, "Extruder Shape (Cell)", "Extruder Shape for making Cells"));
+ ItemList.Shape_Extruder_Ingot.set(
+ addItem(
+ tLastID = 355,
+ "Extruder Shape (Ingot)",
+ "Extruder Shape for, wait, can't we just use a Furnace?"));
+ ItemList.Shape_Extruder_Wire
+ .set(addItem(tLastID = 356, "Extruder Shape (Wire)", "Extruder Shape for making Wires"));
+ ItemList.Shape_Extruder_Casing
+ .set(addItem(tLastID = 357, "Extruder Shape (Casing)", "Extruder Shape for making Item Casings"));
+ ItemList.Shape_Extruder_Pipe_Tiny
+ .set(addItem(tLastID = 358, "Extruder Shape (Tiny Pipe)", "Extruder Shape for making tiny Pipes"));
+ ItemList.Shape_Extruder_Pipe_Small
+ .set(addItem(tLastID = 359, "Extruder Shape (Small Pipe)", "Extruder Shape for making small Pipes"));
+ ItemList.Shape_Extruder_Pipe_Medium
+ .set(addItem(tLastID = 360, "Extruder Shape (Normal Pipe)", "Extruder Shape for making Pipes"));
+ ItemList.Shape_Extruder_Pipe_Large
+ .set(addItem(tLastID = 361, "Extruder Shape (Large Pipe)", "Extruder Shape for making large Pipes"));
ItemList.Shape_Extruder_Pipe_Huge.set(
addItem(tLastID = 362, "Extruder Shape (Huge Pipe)", "Extruder Shape for making full Block Pipes"));
- ItemList.Shape_Extruder_Block.set(
- addItem(tLastID = 363, "Extruder Shape (Block)", "Extruder Shape for making Blocks"));
- ItemList.Shape_Extruder_Sword.set(
- addItem(tLastID = 364, "Extruder Shape (Sword Blade)", "Extruder Shape for making Swords"));
- ItemList.Shape_Extruder_Pickaxe.set(
- addItem(tLastID = 365, "Extruder Shape (Pickaxe Head)", "Extruder Shape for making Pickaxes"));
- ItemList.Shape_Extruder_Shovel.set(
- addItem(tLastID = 366, "Extruder Shape (Shovel Head)", "Extruder Shape for making Shovels"));
- ItemList.Shape_Extruder_Axe.set(
- addItem(tLastID = 367, "Extruder Shape (Axe Head)", "Extruder Shape for making Axes"));
- ItemList.Shape_Extruder_Hoe.set(
- addItem(tLastID = 368, "Extruder Shape (Hoe Head)", "Extruder Shape for making Hoes"));
- ItemList.Shape_Extruder_Hammer.set(
- addItem(tLastID = 369, "Extruder Shape (Hammer Head)", "Extruder Shape for making Hammers"));
- ItemList.Shape_Extruder_File.set(
- addItem(tLastID = 370, "Extruder Shape (File Head)", "Extruder Shape for making Files"));
- ItemList.Shape_Extruder_Saw.set(
- addItem(tLastID = 371, "Extruder Shape (Saw Blade)", "Extruder Shape for making Saws"));
- ItemList.Shape_Extruder_Gear.set(
- addItem(tLastID = 372, "Extruder Shape (Gear)", "Extruder Shape for making Gears"));
- ItemList.Shape_Extruder_Bottle.set(
- addItem(tLastID = 373, "Extruder Shape (Bottle)", "Extruder Shape for making Bottles"));
- ItemList.Shape_Extruder_Rotor.set(
- addItem(tLastID = 374, "Extruder Shape (Rotor)", "Extruder Shape for a Rotor"));
- ItemList.Shape_Extruder_Small_Gear.set(
- addItem(tLastID = 375, "Extruder Shape (Small Gear)", "Extruder Shape for a Small Gear"));
- ItemList.Shape_Extruder_Turbine_Blade.set(
- addItem(tLastID = 376, "Extruder Shape (Turbine Blade)", "Extruder Shape for a Turbine Blade"));
- ItemList.Shape_Extruder_ToolHeadDrill.set(
- addItem(tLastID = 377, "Extruder Shape (Drill Head)", "Extruder Shape for a Drill Head"));
+ ItemList.Shape_Extruder_Block
+ .set(addItem(tLastID = 363, "Extruder Shape (Block)", "Extruder Shape for making Blocks"));
+ ItemList.Shape_Extruder_Sword
+ .set(addItem(tLastID = 364, "Extruder Shape (Sword Blade)", "Extruder Shape for making Swords"));
+ ItemList.Shape_Extruder_Pickaxe
+ .set(addItem(tLastID = 365, "Extruder Shape (Pickaxe Head)", "Extruder Shape for making Pickaxes"));
+ ItemList.Shape_Extruder_Shovel
+ .set(addItem(tLastID = 366, "Extruder Shape (Shovel Head)", "Extruder Shape for making Shovels"));
+ ItemList.Shape_Extruder_Axe
+ .set(addItem(tLastID = 367, "Extruder Shape (Axe Head)", "Extruder Shape for making Axes"));
+ ItemList.Shape_Extruder_Hoe
+ .set(addItem(tLastID = 368, "Extruder Shape (Hoe Head)", "Extruder Shape for making Hoes"));
+ ItemList.Shape_Extruder_Hammer
+ .set(addItem(tLastID = 369, "Extruder Shape (Hammer Head)", "Extruder Shape for making Hammers"));
+ ItemList.Shape_Extruder_File
+ .set(addItem(tLastID = 370, "Extruder Shape (File Head)", "Extruder Shape for making Files"));
+ ItemList.Shape_Extruder_Saw
+ .set(addItem(tLastID = 371, "Extruder Shape (Saw Blade)", "Extruder Shape for making Saws"));
+ ItemList.Shape_Extruder_Gear
+ .set(addItem(tLastID = 372, "Extruder Shape (Gear)", "Extruder Shape for making Gears"));
+ ItemList.Shape_Extruder_Bottle
+ .set(addItem(tLastID = 373, "Extruder Shape (Bottle)", "Extruder Shape for making Bottles"));
+ ItemList.Shape_Extruder_Rotor
+ .set(addItem(tLastID = 374, "Extruder Shape (Rotor)", "Extruder Shape for a Rotor"));
+ ItemList.Shape_Extruder_Small_Gear
+ .set(addItem(tLastID = 375, "Extruder Shape (Small Gear)", "Extruder Shape for a Small Gear"));
+ ItemList.Shape_Extruder_Turbine_Blade
+ .set(addItem(tLastID = 376, "Extruder Shape (Turbine Blade)", "Extruder Shape for a Turbine Blade"));
+ ItemList.Shape_Extruder_ToolHeadDrill
+ .set(addItem(tLastID = 377, "Extruder Shape (Drill Head)", "Extruder Shape for a Drill Head"));
ItemList.Shape_Slicer_Flat.set(addItem(tLastID = 398, "Slicer Blade (Flat)", "Slicer Blade for cutting Flat"));
- ItemList.Shape_Slicer_Stripes.set(
- addItem(tLastID = 399, "Slicer Blade (Stripes)", "Slicer Blade for cutting Stripes"));
+ ItemList.Shape_Slicer_Stripes
+ .set(addItem(tLastID = 399, "Slicer Blade (Stripes)", "Slicer Blade for cutting Stripes"));
GT_ModHandler.addCraftingRecipe(
ItemList.Shape_Slicer_Flat.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "hXS",
- aTextShape,
- "fXd",
- 'P',
- ItemList.Shape_Extruder_Block,
- 'X',
- OrePrefixes.plate.get(Materials.StainlessSteel),
- 'S',
- OrePrefixes.screw.get(Materials.StainlessSteel)
- });
+ new Object[] { "hXS", aTextShape, "fXd", 'P', ItemList.Shape_Extruder_Block, 'X',
+ OrePrefixes.plate.get(Materials.StainlessSteel), 'S',
+ OrePrefixes.screw.get(Materials.StainlessSteel) });
GT_ModHandler.addCraftingRecipe(
ItemList.Shape_Slicer_Stripes.get(1L),
- GT_ModHandler.RecipeBits.BUFFERED
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "hXS",
- "XPX",
- "fXd",
- 'P',
- ItemList.Shape_Extruder_Block,
- 'X',
- OrePrefixes.plate.get(Materials.StainlessSteel),
- 'S',
- OrePrefixes.screw.get(Materials.StainlessSteel)
- });
-
- ItemList.Fuel_Can_Plastic_Empty.set(addItem(
- tLastID = 400,
- "Empty Plastic Fuel Can",
- "Used to store Fuels",
- new ItemData(Materials.Plastic, OrePrefixes.plate.mMaterialAmount * 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
- ItemList.Fuel_Can_Plastic_Filled.set(addItem(
- tLastID = 401,
- "Plastic Fuel Can",
- "Burns well in Diesel Generators",
- new ItemData(Materials.Plastic, OrePrefixes.plate.mMaterialAmount * 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
+ new Object[] { "hXS", "XPX", "fXd", 'P', ItemList.Shape_Extruder_Block, 'X',
+ OrePrefixes.plate.get(Materials.StainlessSteel), 'S',
+ OrePrefixes.screw.get(Materials.StainlessSteel) });
+
+ ItemList.Fuel_Can_Plastic_Empty.set(
+ addItem(
+ tLastID = 400,
+ "Empty Plastic Fuel Can",
+ "Used to store Fuels",
+ new ItemData(Materials.Plastic, OrePrefixes.plate.mMaterialAmount * 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
+ ItemList.Fuel_Can_Plastic_Filled.set(
+ addItem(
+ tLastID = 401,
+ "Plastic Fuel Can",
+ "Burns well in Diesel Generators",
+ new ItemData(Materials.Plastic, OrePrefixes.plate.mMaterialAmount * 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Fuel_Can_Plastic_Empty.get(7L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" PP", "P P", "PPP", 'P', OrePrefixes.plate.get(Materials.Plastic)});
-
- ItemList.Spray_Empty.set(addItem(
- tLastID = 402,
- "Empty Spray Can",
- "Used for making Sprays",
- new ItemData(
- Materials.Tin,
- OrePrefixes.plate.mMaterialAmount * 2L,
- Materials.Redstone,
- OrePrefixes.dust.mMaterialAmount),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
+ new Object[] { " PP", "P P", "PPP", 'P', OrePrefixes.plate.get(Materials.Plastic) });
+
+ ItemList.Spray_Empty.set(
+ addItem(
+ tLastID = 402,
+ "Empty Spray Can",
+ "Used for making Sprays",
+ new ItemData(
+ Materials.Tin,
+ OrePrefixes.plate.mMaterialAmount * 2L,
+ Materials.Redstone,
+ OrePrefixes.dust.mMaterialAmount),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Redstone, 1L),
- GT_OreDictUnificator.get(OrePrefixes.cell, Materials.Empty, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Redstone, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.cell, Materials.Empty, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Spray_Empty.get(1L),
800,
1);
- ItemList.Crate_Empty.set(addItem(
- tLastID = 403,
- "Empty Crate",
- "To Package lots of Material",
- new ItemData(Materials.Wood, 3628800L, Materials.Iron, OrePrefixes.screw.mMaterialAmount),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L)));
+ ItemList.Crate_Empty.set(
+ addItem(
+ tLastID = 403,
+ "Empty Crate",
+ "To Package lots of Material",
+ new ItemData(Materials.Wood, 3628800L, Materials.Iron, OrePrefixes.screw.mMaterialAmount),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L)));
GT_ModHandler.addCraftingRecipe(
- ItemList.Crate_Empty.get(4L), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] {
- "SWS",
- "WdW",
- "SWS",
- 'W',
- OrePrefixes.plank.get(Materials.Wood),
- 'S',
- OrePrefixes.screw.get(Materials.AnyIron)
- });
+ ItemList.Crate_Empty.get(4L),
+ GT_ModHandler.RecipeBits.NOT_REMOVABLE,
+ new Object[] { "SWS", "WdW", "SWS", 'W', OrePrefixes.plank.get(Materials.Wood), 'S',
+ OrePrefixes.screw.get(Materials.AnyIron) });
GT_ModHandler.addCraftingRecipe(
- ItemList.Crate_Empty.get(4L), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] {
- "SWS",
- "WdW",
- "SWS",
- 'W',
- OrePrefixes.plank.get(Materials.Wood),
- 'S',
- OrePrefixes.screw.get(Materials.Steel)
- });
-
- ItemList.ThermosCan_Empty.set(addItem(
- tLastID = 404,
- "Empty Thermos Can",
- "Keeping hot things hot and cold things cold",
- new ItemData(
- Materials.Aluminium,
- OrePrefixes.plateDouble.mMaterialAmount * 1L + 2L * OrePrefixes.ring.mMaterialAmount),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L)));
+ ItemList.Crate_Empty.get(4L),
+ GT_ModHandler.RecipeBits.NOT_REMOVABLE,
+ new Object[] { "SWS", "WdW", "SWS", 'W', OrePrefixes.plank.get(Materials.Wood), 'S',
+ OrePrefixes.screw.get(Materials.Steel) });
+
+ ItemList.ThermosCan_Empty.set(
+ addItem(
+ tLastID = 404,
+ "Empty Thermos Can",
+ "Keeping hot things hot and cold things cold",
+ new ItemData(
+ Materials.Aluminium,
+ OrePrefixes.plateDouble.mMaterialAmount * 1L + 2L * OrePrefixes.ring.mMaterialAmount),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Aluminium, 1L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Aluminium, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Aluminium, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Aluminium, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.ThermosCan_Empty.get(1L),
800,
1);
- ItemList.Large_Fluid_Cell_Steel.set(addItem(
- tLastID = 405,
- "Large Steel Fluid Cell",
- "",
- new ItemData(
- Materials.Steel,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Bronze, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+ ItemList.Large_Fluid_Cell_Steel.set(
+ addItem(
+ tLastID = 405,
+ "Large Steel Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Steel,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Bronze, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
setFluidContainerStats(32000 + tLastID, 8000L, 64L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Steel, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.AnyBronze, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Steel, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.AnyBronze, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Steel.get(1L),
200,
30);
- ItemList.Large_Fluid_Cell_TungstenSteel.set(addItem(
- tLastID = 406,
- "Large Tungstensteel Fluid Cell",
- "",
- new ItemData(
- Materials.TungstenSteel,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Platinum, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 9L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 7L)));
+ ItemList.Large_Fluid_Cell_TungstenSteel.set(
+ addItem(
+ tLastID = 406,
+ "Large Tungstensteel Fluid Cell",
+ "",
+ new ItemData(
+ Materials.TungstenSteel,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Platinum, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 9L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 7L)));
setFluidContainerStats(32000 + tLastID, 512000L, 32L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.TungstenSteel, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Platinum, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.TungstenSteel, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Platinum, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_TungstenSteel.get(1L),
200,
480);
- ItemList.Large_Fluid_Cell_Aluminium.set(addItem(
- tLastID = 407,
- "Large Aluminium Fluid Cell",
- "",
- new ItemData(
- Materials.Aluminium,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Silver, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 5L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 3L)));
+ ItemList.Large_Fluid_Cell_Aluminium.set(
+ addItem(
+ tLastID = 407,
+ "Large Aluminium Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Aluminium,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Silver, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 5L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 3L)));
setFluidContainerStats(32000 + tLastID, 32000L, 64L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Aluminium, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Silver, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Aluminium, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Silver, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Aluminium.get(1L),
200,
64);
- ItemList.Large_Fluid_Cell_StainlessSteel.set(addItem(
- tLastID = 408,
- "Large Stainless Steel Fluid Cell",
- "",
- new ItemData(
- Materials.StainlessSteel,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Electrum, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 6L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 4L)));
+ ItemList.Large_Fluid_Cell_StainlessSteel.set(
+ addItem(
+ tLastID = 408,
+ "Large Stainless Steel Fluid Cell",
+ "",
+ new ItemData(
+ Materials.StainlessSteel,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Electrum, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 6L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 4L)));
setFluidContainerStats(32000 + tLastID, 64000L, 64L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.StainlessSteel, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Electrum, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.StainlessSteel, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Electrum, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_StainlessSteel.get(1L),
200,
120);
- ItemList.Large_Fluid_Cell_Titanium.set(addItem(
- tLastID = 409,
- "Large Titanium Fluid Cell",
- "",
- new ItemData(
- Materials.Titanium,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.RoseGold, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 7L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 5L)));
+ ItemList.Large_Fluid_Cell_Titanium.set(
+ addItem(
+ tLastID = 409,
+ "Large Titanium Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Titanium,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.RoseGold, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 7L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 5L)));
setFluidContainerStats(32000 + tLastID, 128000L, 64L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Titanium, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.RoseGold, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Titanium, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.RoseGold, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Titanium.get(1L),
200,
256);
- ItemList.Large_Fluid_Cell_Chrome.set(addItem(
- tLastID = 410,
- "Large Chrome Fluid Cell",
- "",
- new ItemData(
- Materials.Chrome,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Palladium, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 6L)));
+ ItemList.Large_Fluid_Cell_Chrome.set(
+ addItem(
+ tLastID = 410,
+ "Large Chrome Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Chrome,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Palladium, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 6L)));
setFluidContainerStats(32000 + tLastID, 2048000L, 8L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Chrome, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Palladium, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Chrome, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Palladium, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Chrome.get(1L),
200,
1024);
- ItemList.Large_Fluid_Cell_Iridium.set(addItem(
- tLastID = 411,
- "Large Iridium Fluid Cell",
- "",
- new ItemData(
- Materials.Iridium,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Naquadah, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 10L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 8L)));
+ ItemList.Large_Fluid_Cell_Iridium.set(
+ addItem(
+ tLastID = 411,
+ "Large Iridium Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Iridium,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Naquadah, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 10L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 8L)));
setFluidContainerStats(32000 + tLastID, 8192000L, 2L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Iridium, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Naquadah, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Iridium, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Naquadah, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Iridium.get(1L),
200,
1920);
- ItemList.Large_Fluid_Cell_Osmium.set(addItem(
- tLastID = 412,
- "Large Osmium Fluid Cell",
- "",
- new ItemData(
- Materials.Osmium,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.ElectrumFlux, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 11L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 9L)));
+ ItemList.Large_Fluid_Cell_Osmium.set(
+ addItem(
+ tLastID = 412,
+ "Large Osmium Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Osmium,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.ElectrumFlux, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 11L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 9L)));
setFluidContainerStats(32000 + tLastID, 32768000L, 1L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Osmium, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.ElectrumFlux, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Osmium, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.ElectrumFlux, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Osmium.get(1L),
200,
4096);
- ItemList.Large_Fluid_Cell_Neutronium.set(addItem(
- tLastID = 413,
- "Large Neutronium Fluid Cell",
- "",
- new ItemData(
- Materials.Neutronium,
- OrePrefixes.plateDouble.mMaterialAmount * 4L,
- new MaterialStack(Materials.Draconium, OrePrefixes.ring.mMaterialAmount * 4L)),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 12L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 10L)));
+ ItemList.Large_Fluid_Cell_Neutronium.set(
+ addItem(
+ tLastID = 413,
+ "Large Neutronium Fluid Cell",
+ "",
+ new ItemData(
+ Materials.Neutronium,
+ OrePrefixes.plateDouble.mMaterialAmount * 4L,
+ new MaterialStack(Materials.Draconium, OrePrefixes.ring.mMaterialAmount * 4L)),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 12L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 10L)));
setFluidContainerStats(32000 + tLastID, 131072000L, 1L);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Neutronium, 4L),
- GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Draconium, 4L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plateDouble, Materials.Neutronium, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.ring, Materials.Draconium, 4L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Large_Fluid_Cell_Neutronium.get(1L),
200,
7680);
for (byte i = 0; i < 16; i = (byte) (i + 1)) {
- ItemList.SPRAY_CAN_DYES[i].set(addItem(
- tLastID = 430 + 2 * i,
- "Spray Can (" + Dyes.get(i).mName + ")",
- "Full",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 4L)));
- ItemList.SPRAY_CAN_DYES_USED[i].set(addItem(
- tLastID + 1,
- "Spray Can (" + Dyes.get(i).mName + ")",
- "Used",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 3L),
- SubTag.INVISIBLE));
+ ItemList.SPRAY_CAN_DYES[i].set(
+ addItem(
+ tLastID = 430 + 2 * i,
+ "Spray Can (" + Dyes.get(i).mName + ")",
+ "Full",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 4L)));
+ ItemList.SPRAY_CAN_DYES_USED[i].set(
+ addItem(
+ tLastID + 1,
+ "Spray Can (" + Dyes.get(i).mName + ")",
+ "Used",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 3L),
+ SubTag.INVISIBLE));
IItemBehaviour<GT_MetaBase_Item> tBehaviour = new Behaviour_Spray_Color(
ItemList.Spray_Empty.get(1L),
ItemList.SPRAY_CAN_DYES_USED[i].get(1L),
@@ -1371,70 +1101,71 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
addItemBehavior(32000 + tLastID, tBehaviour);
addItemBehavior(32001 + tLastID, tBehaviour);
}
- ItemList.Tool_Matches.set(addItem(
- tLastID = 471,
- "Match",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Tool_MatchBox_Used.set(addItem(
- tLastID = 472,
- "Match Box",
- "This is not a Car",
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- SubTag.INVISIBLE));
- ItemList.Tool_MatchBox_Full.set(addItem(
- tLastID = 473,
- "Match Box (Full)",
- "This is not a Car",
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
-
- IItemBehaviour<GT_MetaBase_Item> tBehaviour =
- new Behaviour_Lighter(null, ItemList.Tool_Matches.get(1L), ItemList.Tool_Matches.get(1L), 1L);
+ ItemList.Tool_Matches.set(
+ addItem(
+ tLastID = 471,
+ "Match",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Tool_MatchBox_Used.set(
+ addItem(
+ tLastID = 472,
+ "Match Box",
+ "This is not a Car",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ SubTag.INVISIBLE));
+ ItemList.Tool_MatchBox_Full.set(
+ addItem(
+ tLastID = 473,
+ "Match Box (Full)",
+ "This is not a Car",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+
+ IItemBehaviour<GT_MetaBase_Item> tBehaviour = new Behaviour_Lighter(
+ null,
+ ItemList.Tool_Matches.get(1L),
+ ItemList.Tool_Matches.get(1L),
+ 1L);
addItemBehavior(32471, tBehaviour);
tBehaviour = new Behaviour_Lighter(
- null, ItemList.Tool_MatchBox_Used.get(1L), ItemList.Tool_MatchBox_Full.get(1L), 16L);
+ null,
+ ItemList.Tool_MatchBox_Used.get(1L),
+ ItemList.Tool_MatchBox_Full.get(1L),
+ 16L);
addItemBehavior(32472, tBehaviour);
addItemBehavior(32473, tBehaviour);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.Phosphorus, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.Phosphorus, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Tool_Matches.get(1L),
16,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.TricalciumPhosphate, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.TricalciumPhosphate, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Tool_Matches.get(1L),
16,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 4L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Phosphorus, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Phosphorus, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Tool_Matches.get(4L),
64,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 4L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.TricalciumPhosphate, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.bolt, Materials.Wood, 4L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.TricalciumPhosphate, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Tool_Matches.get(4L),
64,
@@ -1445,31 +1176,34 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemList.Tool_MatchBox_Full.get(1L),
64,
16);
- GT_Values.RA.addUnboxingRecipe(
- ItemList.Tool_MatchBox_Full.get(1L), ItemList.Tool_Matches.get(16L), null, 32, 16);
-
- ItemList.Tool_Lighter_Invar_Empty.set(addItem(
- tLastID = 474,
- "Lighter (Empty)",
- "",
- new ItemData(Materials.Invar, OrePrefixes.plate.mMaterialAmount * 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Tool_Lighter_Invar_Used.set(addItem(
- tLastID = 475,
- "Lighter",
- "",
- new ItemData(Materials.Invar, OrePrefixes.plate.mMaterialAmount * 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- SubTag.INVISIBLE));
- ItemList.Tool_Lighter_Invar_Full.set(addItem(
- tLastID = 476,
- "Lighter (Full)",
- "",
- new ItemData(Materials.Invar, OrePrefixes.plate.mMaterialAmount * 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ GT_Values.RA
+ .addUnboxingRecipe(ItemList.Tool_MatchBox_Full.get(1L), ItemList.Tool_Matches.get(16L), null, 32, 16);
+
+ ItemList.Tool_Lighter_Invar_Empty.set(
+ addItem(
+ tLastID = 474,
+ "Lighter (Empty)",
+ "",
+ new ItemData(Materials.Invar, OrePrefixes.plate.mMaterialAmount * 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Tool_Lighter_Invar_Used.set(
+ addItem(
+ tLastID = 475,
+ "Lighter",
+ "",
+ new ItemData(Materials.Invar, OrePrefixes.plate.mMaterialAmount * 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ SubTag.INVISIBLE));
+ ItemList.Tool_Lighter_Invar_Full.set(
+ addItem(
+ tLastID = 476,
+ "Lighter (Full)",
+ "",
+ new ItemData(Materials.Invar, OrePrefixes.plate.mMaterialAmount * 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
tBehaviour = new Behaviour_Lighter(
ItemList.Tool_Lighter_Invar_Empty.get(1L),
@@ -1480,41 +1214,41 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
addItemBehavior(32476, tBehaviour);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Invar, 2L),
- new ItemStack(Items.flint, 1),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Invar, 2L),
+ new ItemStack(Items.flint, 1), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Tool_Lighter_Invar_Empty.get(1L),
256,
16);
- ItemList.Tool_Lighter_Platinum_Empty.set(addItem(
- tLastID = 477,
- "Platinum Lighter (Empty)",
- "A known Prank Master is engraved on it",
- new ItemData(Materials.Platinum, OrePrefixes.plate.mMaterialAmount * 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Tool_Lighter_Platinum_Used.set(addItem(
- tLastID = 478,
- "Platinum Lighter",
- "A known Prank Master is engraved on it",
- new ItemData(Materials.Platinum, OrePrefixes.plate.mMaterialAmount * 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- SubTag.INVISIBLE));
- ItemList.Tool_Lighter_Platinum_Full.set(addItem(
- tLastID = 479,
- "Platinum Lighter (Full)",
- "A known Prank Master is engraved on it",
- new ItemData(Materials.Platinum, OrePrefixes.plate.mMaterialAmount * 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Tool_Lighter_Platinum_Empty.set(
+ addItem(
+ tLastID = 477,
+ "Platinum Lighter (Empty)",
+ "A known Prank Master is engraved on it",
+ new ItemData(Materials.Platinum, OrePrefixes.plate.mMaterialAmount * 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Tool_Lighter_Platinum_Used.set(
+ addItem(
+ tLastID = 478,
+ "Platinum Lighter",
+ "A known Prank Master is engraved on it",
+ new ItemData(Materials.Platinum, OrePrefixes.plate.mMaterialAmount * 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ SubTag.INVISIBLE));
+ ItemList.Tool_Lighter_Platinum_Full.set(
+ addItem(
+ tLastID = 479,
+ "Platinum Lighter (Full)",
+ "A known Prank Master is engraved on it",
+ new ItemData(Materials.Platinum, OrePrefixes.plate.mMaterialAmount * 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
tBehaviour = new Behaviour_Lighter(
ItemList.Tool_Lighter_Platinum_Empty.get(1L),
@@ -1525,35 +1259,33 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
addItemBehavior(32479, tBehaviour);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Platinum, 2L),
- new ItemStack(Items.flint, 1),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Platinum, 2L),
+ new ItemStack(Items.flint, 1), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Tool_Lighter_Platinum_Empty.get(1L),
256,
256);
if (Loader.isModLoaded("GalacticraftMars")) {
- ItemList.Ingot_Heavy1.set(
- addItem(tLastID = 462, "Heavy Duty Alloy Ingot T1", "Used to make Heavy Duty Plates T1"));
- ItemList.Ingot_Heavy2.set(
- addItem(tLastID = 463, "Heavy Duty Alloy Ingot T2", "Used to make Heavy Duty Plates T2"));
- ItemList.Ingot_Heavy3.set(
- addItem(tLastID = 464, "Heavy Duty Alloy Ingot T3", "Used to make Heavy Duty Plates T3"));
+ ItemList.Ingot_Heavy1
+ .set(addItem(tLastID = 462, "Heavy Duty Alloy Ingot T1", "Used to make Heavy Duty Plates T1"));
+ ItemList.Ingot_Heavy2
+ .set(addItem(tLastID = 463, "Heavy Duty Alloy Ingot T2", "Used to make Heavy Duty Plates T2"));
+ ItemList.Ingot_Heavy3
+ .set(addItem(tLastID = 464, "Heavy Duty Alloy Ingot T3", "Used to make Heavy Duty Plates T3"));
// GT_ModHandler.addCraftingRecipe(ItemList.Ingot_Heavy1.get(1L, new Object[0]),
// GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[]{"BhB", "CAS", "B B", 'B',
// OrePrefixes.bolt.get(Materials.StainlessSteel), 'C', OrePrefixes.compressed.get(Materials.Bronze), 'A',
// OrePrefixes.compressed.get(Materials.Aluminium), 'S', OrePrefixes.compressed.get(Materials.Steel)});
}
- ItemList.Ingot_IridiumAlloy.set(addItem(
- tLastID = 480,
- "Iridium Alloy Ingot",
- "Used to make Iridium Plates",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L)));
+ ItemList.Ingot_IridiumAlloy.set(
+ addItem(
+ tLastID = 480,
+ "Iridium Alloy Ingot",
+ "Used to make Iridium Plates",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L)));
// GT_ModHandler.addRollingMachineRecipe(ItemList.Ingot_IridiumAlloy.get(1L, new Object[0]), new Object[]{"IAI",
// "ADA", "IAI", 'D', GregTech_API.sRecipeFile.get(ConfigCategories.Recipes.harderrecipes, "iridiumplate", true)
@@ -1565,391 +1297,423 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
// OreDictNames.craftingIndustrialDiamond : OrePrefixes.dust.get(Materials.Diamond), 'A',
// OrePrefixes.plateAlloy.get("Advanced"), 'I', OrePrefixes.plate.get(Materials.Iridium)});
- ItemList.Paper_Printed_Pages.set(addItem(
- tLastID = 481,
- "Printed Pages",
- "Used to make written Books",
- new ItemData(Materials.Paper, 10886400L),
- new Behaviour_PrintedPages(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
- ItemList.Paper_Magic_Empty.set(addItem(
- tLastID = 482,
- "Magic Paper",
- "",
- SubTag.INVISIBLE,
- new ItemData(Materials.Paper, 3628800L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PRAECANTATIO, 1L)));
- ItemList.Paper_Magic_Page.set(addItem(
- tLastID = 483,
- "Enchanted Page",
- "",
- SubTag.INVISIBLE,
- new ItemData(Materials.Paper, 3628800L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PRAECANTATIO, 2L)));
- ItemList.Paper_Magic_Pages.set(addItem(
- tLastID = 484,
- "Enchanted Pages",
- "",
- SubTag.INVISIBLE,
- new ItemData(Materials.Paper, 10886400L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PRAECANTATIO, 4L)));
- ItemList.Paper_Punch_Card_Empty.set(addItem(
- tLastID = 485,
- "Punch Card",
- "",
- SubTag.INVISIBLE,
- new ItemData(Materials.Paper, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L)));
- ItemList.Paper_Punch_Card_Encoded.set(addItem(
- tLastID = 486,
- "Punched Card",
- "",
- SubTag.INVISIBLE,
- new ItemData(Materials.Paper, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
- ItemList.Book_Written_01.set(addItem(
- tLastID = 487,
- "Book",
- "",
- new ItemData(Materials.Paper, 10886400L),
- "bookWritten",
- OreDictNames.craftingBook,
- new Behaviour_WrittenBook(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
- ItemList.Book_Written_02.set(addItem(
- tLastID = 488,
- "Book",
- "",
- new ItemData(Materials.Paper, 10886400L),
- "bookWritten",
- OreDictNames.craftingBook,
- new Behaviour_WrittenBook(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
- ItemList.Book_Written_03.set(addItem(
- tLastID = 489,
- "Book",
- "",
- new ItemData(Materials.Paper, 10886400L),
- "bookWritten",
- OreDictNames.craftingBook,
- new Behaviour_WrittenBook(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
-
- ItemList.Schematic.set(addItem(
- tLastID = 490,
- "Schematic",
- "EMPTY",
- new ItemData(Materials.Steel, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.STRONTIO, 1L)));
- ItemList.Schematic_Crafting.set(addItem(
- tLastID = 491,
- "Schematic (Crafting)",
- "Crafts the Programmed Recipe",
- new ItemData(Materials.Steel, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
- ItemList.Schematic_1by1.set(addItem(
- tLastID = 495,
- "Schematic (1x1)",
- "Crafts 1 Items as 1x1 (use in Packager)",
- new ItemData(Materials.Steel, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
- ItemList.Schematic_2by2.set(addItem(
- tLastID = 496,
- "Schematic (2x2)",
- "Crafts 4 Items as 2x2 (use in Packager)",
- new ItemData(Materials.Steel, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
- ItemList.Schematic_3by3.set(addItem(
- tLastID = 497,
- "Schematic (3x3)",
- "Crafts 9 Items as 3x3 (use in Packager)",
- new ItemData(Materials.Steel, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
- ItemList.Schematic_Dust.set(addItem(
- tLastID = 498,
- "Schematic (Dusts)",
- "Combines Dusts (use in Packager)",
- new ItemData(Materials.Steel, 7257600L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
+ ItemList.Paper_Printed_Pages.set(
+ addItem(
+ tLastID = 481,
+ "Printed Pages",
+ "Used to make written Books",
+ new ItemData(Materials.Paper, 10886400L),
+ new Behaviour_PrintedPages(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
+ ItemList.Paper_Magic_Empty.set(
+ addItem(
+ tLastID = 482,
+ "Magic Paper",
+ "",
+ SubTag.INVISIBLE,
+ new ItemData(Materials.Paper, 3628800L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PRAECANTATIO, 1L)));
+ ItemList.Paper_Magic_Page.set(
+ addItem(
+ tLastID = 483,
+ "Enchanted Page",
+ "",
+ SubTag.INVISIBLE,
+ new ItemData(Materials.Paper, 3628800L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PRAECANTATIO, 2L)));
+ ItemList.Paper_Magic_Pages.set(
+ addItem(
+ tLastID = 484,
+ "Enchanted Pages",
+ "",
+ SubTag.INVISIBLE,
+ new ItemData(Materials.Paper, 10886400L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PRAECANTATIO, 4L)));
+ ItemList.Paper_Punch_Card_Empty.set(
+ addItem(
+ tLastID = 485,
+ "Punch Card",
+ "",
+ SubTag.INVISIBLE,
+ new ItemData(Materials.Paper, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L)));
+ ItemList.Paper_Punch_Card_Encoded.set(
+ addItem(
+ tLastID = 486,
+ "Punched Card",
+ "",
+ SubTag.INVISIBLE,
+ new ItemData(Materials.Paper, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
+ ItemList.Book_Written_01.set(
+ addItem(
+ tLastID = 487,
+ "Book",
+ "",
+ new ItemData(Materials.Paper, 10886400L),
+ "bookWritten",
+ OreDictNames.craftingBook,
+ new Behaviour_WrittenBook(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
+ ItemList.Book_Written_02.set(
+ addItem(
+ tLastID = 488,
+ "Book",
+ "",
+ new ItemData(Materials.Paper, 10886400L),
+ "bookWritten",
+ OreDictNames.craftingBook,
+ new Behaviour_WrittenBook(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
+ ItemList.Book_Written_03.set(
+ addItem(
+ tLastID = 489,
+ "Book",
+ "",
+ new ItemData(Materials.Paper, 10886400L),
+ "bookWritten",
+ OreDictNames.craftingBook,
+ new Behaviour_WrittenBook(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
+
+ ItemList.Schematic.set(
+ addItem(
+ tLastID = 490,
+ "Schematic",
+ "EMPTY",
+ new ItemData(Materials.Steel, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.STRONTIO, 1L)));
+ ItemList.Schematic_Crafting.set(
+ addItem(
+ tLastID = 491,
+ "Schematic (Crafting)",
+ "Crafts the Programmed Recipe",
+ new ItemData(Materials.Steel, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
+ ItemList.Schematic_1by1.set(
+ addItem(
+ tLastID = 495,
+ "Schematic (1x1)",
+ "Crafts 1 Items as 1x1 (use in Packager)",
+ new ItemData(Materials.Steel, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
+ ItemList.Schematic_2by2.set(
+ addItem(
+ tLastID = 496,
+ "Schematic (2x2)",
+ "Crafts 4 Items as 2x2 (use in Packager)",
+ new ItemData(Materials.Steel, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
+ ItemList.Schematic_3by3.set(
+ addItem(
+ tLastID = 497,
+ "Schematic (3x3)",
+ "Crafts 9 Items as 3x3 (use in Packager)",
+ new ItemData(Materials.Steel, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
+ ItemList.Schematic_Dust.set(
+ addItem(
+ tLastID = 498,
+ "Schematic (Dusts)",
+ "Combines Dusts (use in Packager)",
+ new ItemData(Materials.Steel, 7257600L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 1L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Schematic_1by1.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {"d ", aTextShape, aTextEmptyRow, 'P', ItemList.Schematic});
+ new Object[] { "d ", aTextShape, aTextEmptyRow, 'P', ItemList.Schematic });
GT_ModHandler.addCraftingRecipe(
ItemList.Schematic_2by2.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" d ", aTextShape, aTextEmptyRow, 'P', ItemList.Schematic});
+ new Object[] { " d ", aTextShape, aTextEmptyRow, 'P', ItemList.Schematic });
GT_ModHandler.addCraftingRecipe(
ItemList.Schematic_3by3.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" d", aTextShape, aTextEmptyRow, 'P', ItemList.Schematic});
+ new Object[] { " d", aTextShape, aTextEmptyRow, 'P', ItemList.Schematic });
GT_ModHandler.addCraftingRecipe(
ItemList.Schematic_Dust.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {aTextEmptyRow, aTextShape, " d", 'P', ItemList.Schematic});
+ new Object[] { aTextEmptyRow, aTextShape, " d", 'P', ItemList.Schematic });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Schematic.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Schematic_Crafting});
+ new Object[] { ItemList.Schematic_Crafting });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Schematic.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Schematic_1by1});
+ new Object[] { ItemList.Schematic_1by1 });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Schematic.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Schematic_2by2});
+ new Object[] { ItemList.Schematic_2by2 });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Schematic.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Schematic_3by3});
+ new Object[] { ItemList.Schematic_3by3 });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Schematic.get(1L),
GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Schematic_Dust});
-
- ItemList.Battery_Hull_LV.set(addItem(
- 500,
- "Small Battery Hull",
- "An empty LV Battery Hull",
- new ItemData(Materials.BatteryAlloy, OrePrefixes.plate.mMaterialAmount * 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Battery_Hull_MV.set(addItem(
- 501,
- "Medium Battery Hull",
- "An empty MV Battery Hull",
- new ItemData(Materials.BatteryAlloy, OrePrefixes.plate.mMaterialAmount * 3L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
- ItemList.Battery_Hull_HV.set(addItem(
- 502,
- "Large Battery Hull",
- "An empty HV Battery Hull",
- new ItemData(Materials.BatteryAlloy, OrePrefixes.plate.mMaterialAmount * 9L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ new Object[] { ItemList.Schematic_Dust });
+
+ ItemList.Battery_Hull_LV.set(
+ addItem(
+ 500,
+ "Small Battery Hull",
+ "An empty LV Battery Hull",
+ new ItemData(Materials.BatteryAlloy, OrePrefixes.plate.mMaterialAmount * 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Battery_Hull_MV.set(
+ addItem(
+ 501,
+ "Medium Battery Hull",
+ "An empty MV Battery Hull",
+ new ItemData(Materials.BatteryAlloy, OrePrefixes.plate.mMaterialAmount * 3L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
+ ItemList.Battery_Hull_HV.set(
+ addItem(
+ 502,
+ "Large Battery Hull",
+ "An empty HV Battery Hull",
+ new ItemData(Materials.BatteryAlloy, OrePrefixes.plate.mMaterialAmount * 9L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L)));
GT_ModHandler.addCraftingRecipe(
- ItemList.Battery_Hull_LV.get(1L), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new Object[] {
- "Cf ",
- "Ph ",
- "Ps ",
- 'P',
- OrePrefixes.plate.get(Materials.BatteryAlloy),
- 'C',
- OreDictNames.craftingWireTin
- });
+ ItemList.Battery_Hull_LV.get(1L),
+ GT_ModHandler.RecipeBits.NOT_REMOVABLE,
+ new Object[] { "Cf ", "Ph ", "Ps ", 'P', OrePrefixes.plate.get(Materials.BatteryAlloy), 'C',
+ OreDictNames.craftingWireTin });
// GT_ModHandler.addCraftingRecipe(ItemList.Battery_Hull_MV.get(1L), GT_ModHandler.RecipeBits.NOT_REMOVABLE, new
// Object[]{"C C", "PPP", "PPP", 'P', OrePrefixes.plate.get(Materials.BatteryAlloy), 'C',
// OreDictNames.craftingWireCopper});
// ULV Batteries
- ItemList.Battery_RE_ULV_Tantalum.set(addItem(
- tLastID = 499,
- "Tantalum Capacitor",
- "Reusable",
- "batteryULV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Battery_RE_ULV_Tantalum.set(
+ addItem(
+ tLastID = 499,
+ "Tantalum Capacitor",
+ "Reusable",
+ "batteryULV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
setElectricStats(32000 + tLastID, 1000L, GT_Values.V[0], 0L, -3L, false);
OreDictionary.registerOre("ULV", ItemList.Battery_RE_ULV_Tantalum.get(1));
// LV Batteries
- ItemList.Battery_SU_LV_SulfuricAcid.set(addItem(
- tLastID = 510,
- "Small Acid Battery",
- "Single Use",
- "batteryLV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Battery_SU_LV_SulfuricAcid.set(
+ addItem(
+ tLastID = 510,
+ "Small Acid Battery",
+ "Single Use",
+ "batteryLV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
setElectricStats(32000 + tLastID, 18000L, GT_Values.V[1], 1L, -2L, true);
OreDictionary.registerOre("LV", ItemList.Battery_SU_LV_SulfuricAcid.get(1));
- ItemList.Battery_SU_LV_Mercury.set(addItem(
- tLastID = 511,
- "Small Mercury Battery",
- "Single Use",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Battery_SU_LV_Mercury.set(
+ addItem(
+ tLastID = 511,
+ "Small Mercury Battery",
+ "Single Use",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
setElectricStats(32000 + tLastID, 32000L, GT_Values.V[1], 1L, -2L, true);
OreDictionary.registerOre("LV", ItemList.Battery_SU_LV_Mercury.get(1));
- ItemList.Battery_RE_LV_Cadmium.set(addItem(
- tLastID = 517,
- "Small Cadmium Battery",
- "Reusable",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- "batteryLV"));
+ ItemList.Battery_RE_LV_Cadmium.set(
+ addItem(
+ tLastID = 517,
+ "Small Cadmium Battery",
+ "Reusable",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ "batteryLV"));
setElectricStats(32000 + tLastID, 75000L, GT_Values.V[1], 1L, -3L, true);
OreDictionary.registerOre("LV", ItemList.Battery_RE_LV_Cadmium.get(1));
- OreDictionary.registerOre(
- "calclavia:ADVANCED_BATTERY", ItemList.Battery_RE_LV_Cadmium.get(1)); // Annoying backwards compat
-
- ItemList.Battery_RE_LV_Lithium.set(addItem(
- tLastID = 518,
- "Small Lithium Battery",
- "Reusable",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- "batteryLV"));
+ OreDictionary.registerOre("calclavia:ADVANCED_BATTERY", ItemList.Battery_RE_LV_Cadmium.get(1)); // Annoying
+ // backwards
+ // compat
+
+ ItemList.Battery_RE_LV_Lithium.set(
+ addItem(
+ tLastID = 518,
+ "Small Lithium Battery",
+ "Reusable",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ "batteryLV"));
setElectricStats(32000 + tLastID, 100000L, GT_Values.V[1], 1L, -3L, true);
OreDictionary.registerOre("LV", ItemList.Battery_RE_LV_Lithium.get(1));
- OreDictionary.registerOre(
- "calclavia:ADVANCED_BATTERY", ItemList.Battery_RE_LV_Lithium.get(1)); // Annoying backwards compat
-
- ItemList.Battery_RE_LV_Sodium.set(addItem(
- tLastID = 519,
- "Small Sodium Battery",
- "Reusable",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- "calclavia:ADVANCED_BATTERY"));
+ OreDictionary.registerOre("calclavia:ADVANCED_BATTERY", ItemList.Battery_RE_LV_Lithium.get(1)); // Annoying
+ // backwards
+ // compat
+
+ ItemList.Battery_RE_LV_Sodium.set(
+ addItem(
+ tLastID = 519,
+ "Small Sodium Battery",
+ "Reusable",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ "calclavia:ADVANCED_BATTERY"));
setElectricStats(32000 + tLastID, 50000L, GT_Values.V[1], 1L, -3L, true);
OreDictionary.registerOre("LV", ItemList.Battery_RE_LV_Sodium.get(1));
- OreDictionary.registerOre(
- "calclavia:ADVANCED_BATTERY", ItemList.Battery_RE_LV_Sodium.get(1)); // Annoying backwards compat
+ OreDictionary.registerOre("calclavia:ADVANCED_BATTERY", ItemList.Battery_RE_LV_Sodium.get(1)); // Annoying
+ // backwards
+ // compat
// MV Batteries
- ItemList.Battery_SU_MV_SulfuricAcid.set(addItem(
- tLastID = 520,
- "Medium Acid Battery",
- "Single Use",
- "batteryMV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
+ ItemList.Battery_SU_MV_SulfuricAcid.set(
+ addItem(
+ tLastID = 520,
+ "Medium Acid Battery",
+ "Single Use",
+ "batteryMV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
setElectricStats(32000 + tLastID, 72000L, GT_Values.V[2], 2L, -2L, true);
OreDictionary.registerOre("MV", ItemList.Battery_SU_MV_SulfuricAcid.get(1));
- ItemList.Battery_SU_MV_Mercury.set(addItem(
- tLastID = 521,
- "Medium Mercury Battery",
- "Single Use",
- "batteryMV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
+ ItemList.Battery_SU_MV_Mercury.set(
+ addItem(
+ tLastID = 521,
+ "Medium Mercury Battery",
+ "Single Use",
+ "batteryMV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
setElectricStats(32000 + tLastID, 128000L, GT_Values.V[2], 2L, -2L, true);
OreDictionary.registerOre("MV", ItemList.Battery_SU_MV_Mercury.get(1));
- ItemList.Battery_RE_MV_Cadmium.set(addItem(
- tLastID = 527,
- "Medium Cadmium Battery",
- "Reusable",
- "batteryMV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Battery_RE_MV_Cadmium.set(
+ addItem(
+ tLastID = 527,
+ "Medium Cadmium Battery",
+ "Reusable",
+ "batteryMV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
setElectricStats(32000 + tLastID, 300000L, GT_Values.V[2], 2L, -3L, true);
OreDictionary.registerOre("MV", ItemList.Battery_RE_MV_Cadmium.get(1));
- ItemList.Battery_RE_MV_Lithium.set(addItem(
- tLastID = 528,
- "Medium Lithium Battery",
- "Reusable",
- "batteryMV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Battery_RE_MV_Lithium.set(
+ addItem(
+ tLastID = 528,
+ "Medium Lithium Battery",
+ "Reusable",
+ "batteryMV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
setElectricStats(32000 + tLastID, 400000L, GT_Values.V[2], 2L, -3L, true);
OreDictionary.registerOre("MV", ItemList.Battery_RE_MV_Lithium.get(1));
- ItemList.Battery_RE_MV_Sodium.set(addItem(
- tLastID = 529,
- "Medium Sodium Battery",
- "Reusable",
- "batteryMV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Battery_RE_MV_Sodium.set(
+ addItem(
+ tLastID = 529,
+ "Medium Sodium Battery",
+ "Reusable",
+ "batteryMV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
setElectricStats(32000 + tLastID, 200000L, GT_Values.V[2], 2L, -3L, true);
OreDictionary.registerOre("MV", ItemList.Battery_RE_MV_Sodium.get(1));
// HV Batteries
- ItemList.Battery_SU_HV_SulfuricAcid.set(addItem(
- tLastID = 530,
- "Large Acid Battery",
- "Single Use",
- "batteryHV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 8L)));
+ ItemList.Battery_SU_HV_SulfuricAcid.set(
+ addItem(
+ tLastID = 530,
+ "Large Acid Battery",
+ "Single Use",
+ "batteryHV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 8L)));
setElectricStats(32000 + tLastID, 288000L, GT_Values.V[3], 3L, -2L, true);
OreDictionary.registerOre("HV", ItemList.Battery_SU_HV_SulfuricAcid.get(1));
- ItemList.Battery_SU_HV_Mercury.set(addItem(
- tLastID = 531,
- "Large Mercury Battery",
- "Single Use",
- "batteryHV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 8L)));
+ ItemList.Battery_SU_HV_Mercury.set(
+ addItem(
+ tLastID = 531,
+ "Large Mercury Battery",
+ "Single Use",
+ "batteryHV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 8L)));
setElectricStats(32000 + tLastID, 512000L, GT_Values.V[3], 3L, -2L, true);
OreDictionary.registerOre("HV", ItemList.Battery_SU_HV_Mercury.get(1));
- ItemList.Battery_RE_HV_Cadmium.set(addItem(
- tLastID = 537,
- "Large Cadmium Battery",
- "Reusable",
- "batteryHV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
+ ItemList.Battery_RE_HV_Cadmium.set(
+ addItem(
+ tLastID = 537,
+ "Large Cadmium Battery",
+ "Reusable",
+ "batteryHV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
setElectricStats(32000 + tLastID, 1200000L, GT_Values.V[3], 3L, -3L, true);
OreDictionary.registerOre("HV", ItemList.Battery_RE_HV_Cadmium.get(1));
- ItemList.Battery_RE_HV_Lithium.set(addItem(
- tLastID = 538,
- "Large Lithium Battery",
- "Reusable",
- "batteryHV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
+ ItemList.Battery_RE_HV_Lithium.set(
+ addItem(
+ tLastID = 538,
+ "Large Lithium Battery",
+ "Reusable",
+ "batteryHV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
setElectricStats(32000 + tLastID, 1600000L, GT_Values.V[3], 3L, -3L, true);
OreDictionary.registerOre("HV", ItemList.Battery_RE_HV_Lithium.get(1));
- ItemList.Battery_RE_HV_Sodium.set(addItem(
- tLastID = 539,
- "Large Sodium Battery",
- "Reusable",
- "batteryHV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
+ ItemList.Battery_RE_HV_Sodium.set(
+ addItem(
+ tLastID = 539,
+ "Large Sodium Battery",
+ "Reusable",
+ "batteryHV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L)));
setElectricStats(32000 + tLastID, 800000L, GT_Values.V[3], 3L, -3L, true);
OreDictionary.registerOre("HV", ItemList.Battery_RE_HV_Sodium.get(1));
- GT_ModHandler.addExtractionRecipe(
- ItemList.Battery_SU_LV_SulfuricAcid.get(1L), ItemList.Battery_Hull_LV.get(1L));
+ GT_ModHandler
+ .addExtractionRecipe(ItemList.Battery_SU_LV_SulfuricAcid.get(1L), ItemList.Battery_Hull_LV.get(1L));
GT_ModHandler.addExtractionRecipe(ItemList.Battery_SU_LV_Mercury.get(1L), ItemList.Battery_Hull_LV.get(1L));
- GT_ModHandler.addExtractionRecipe(
- ItemList.Battery_SU_MV_SulfuricAcid.get(1L), ItemList.Battery_Hull_MV.get(1L));
+ GT_ModHandler
+ .addExtractionRecipe(ItemList.Battery_SU_MV_SulfuricAcid.get(1L), ItemList.Battery_Hull_MV.get(1L));
GT_ModHandler.addExtractionRecipe(ItemList.Battery_SU_MV_Mercury.get(1L), ItemList.Battery_Hull_MV.get(1L));
- GT_ModHandler.addExtractionRecipe(
- ItemList.Battery_SU_HV_SulfuricAcid.get(1L), ItemList.Battery_Hull_HV.get(1L));
+ GT_ModHandler
+ .addExtractionRecipe(ItemList.Battery_SU_HV_SulfuricAcid.get(1L), ItemList.Battery_Hull_HV.get(1L));
GT_ModHandler.addExtractionRecipe(ItemList.Battery_SU_HV_Mercury.get(1L), ItemList.Battery_Hull_HV.get(1L));
GT_ModHandler.addExtractionRecipe(ItemList.Battery_RE_LV_Cadmium.get(1L), ItemList.Battery_Hull_LV.get(1L));
GT_ModHandler.addExtractionRecipe(ItemList.Battery_RE_LV_Lithium.get(1L), ItemList.Battery_Hull_LV.get(1L));
@@ -2026,642 +1790,580 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
2);
// IV Battery
- ItemList.Energy_LapotronicOrb.set(addItem(
- tLastID = 597,
- "Lapotronic Energy Orb",
- "Reusable battery",
- "batteryIV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
- OrePrefixes.battery.get(Materials.Ultimate)));
+ ItemList.Energy_LapotronicOrb.set(
+ addItem(
+ tLastID = 597,
+ "Lapotronic Energy Orb",
+ "Reusable battery",
+ "batteryIV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
+ OrePrefixes.battery.get(Materials.Ultimate)));
setElectricStats(32000 + tLastID, 100000000L, GT_Values.V[5], 5L, -3L, true);
OreDictionary.registerOre("IV", ItemList.Energy_LapotronicOrb.get(1));
// ZPM Module
- ItemList.ZPM.set(addItem(
- tLastID = 598,
- "Zero Point Module",
- "Single use battery",
- "batteryZPM",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
+ ItemList.ZPM.set(
+ addItem(
+ tLastID = 598,
+ "Zero Point Module",
+ "Single use battery",
+ "batteryZPM",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
setElectricStats(32000 + tLastID, 2000000000000L, GT_Values.V[7], 7L, -2L, true);
OreDictionary.registerOre("ZPM", ItemList.ZPM.get(1));
// LuV Lapotron orb cluster battery
- ItemList.Energy_LapotronicOrb2.set(addItem(
- tLastID = 599,
- "Lapotronic Energy Orb Cluster",
- "Reusable battery",
- "batteryLuV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
- OrePrefixes.battery.get(Materials.Ultimate)));
+ ItemList.Energy_LapotronicOrb2.set(
+ addItem(
+ tLastID = 599,
+ "Lapotronic Energy Orb Cluster",
+ "Reusable battery",
+ "batteryLuV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
+ OrePrefixes.battery.get(Materials.Ultimate)));
setElectricStats(32000 + tLastID, 1000000000L, GT_Values.V[6], 6L, -3L, true);
OreDictionary.registerOre("LuV", ItemList.Energy_LapotronicOrb2.get(1));
// UV Battery
- ItemList.ZPM2.set(addItem(
- tLastID = 605,
- "Ultimate Battery",
- "Fill this to win minecraft",
- "batteryUV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
+ ItemList.ZPM2.set(
+ addItem(
+ tLastID = 605,
+ "Ultimate Battery",
+ "Fill this to win minecraft",
+ "batteryUV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
setElectricStats(32000 + tLastID, Long.MAX_VALUE, GT_Values.V[8], 8L, -3L, true);
OreDictionary.registerOre("UV", ItemList.ZPM2.get(1));
// UMV Battery
- ItemList.ZPM3.set(addItem(
- tLastID = 609,
- "Really Ultimate Battery",
- "Fill this to be way older",
- "batteryUMV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
+ ItemList.ZPM3.set(
+ addItem(
+ tLastID = 609,
+ "Really Ultimate Battery",
+ "Fill this to be way older",
+ "batteryUMV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
setElectricStats(32000 + tLastID, Long.MAX_VALUE, GT_Values.V[12], 12L, -3L, true);
OreDictionary.registerOre("UMV", ItemList.ZPM3.get(1));
// ZPM Cluster
- ItemList.Energy_Module.set(addItem(
- tLastID = 736,
- "Energy Module",
- "Reusable battery",
- "batteryZPM",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
- OrePrefixes.battery.get(Materials.Ultimate)));
+ ItemList.Energy_Module.set(
+ addItem(
+ tLastID = 736,
+ "Energy Module",
+ "Reusable battery",
+ "batteryZPM",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
+ OrePrefixes.battery.get(Materials.Ultimate)));
setElectricStats(32000 + tLastID, 10000000000L, GT_Values.V[7], 7L, -3L, true);
OreDictionary.registerOre("ZPM", ItemList.Energy_Module.get(1));
// UV Cluster
- ItemList.Energy_Cluster.set(addItem(
- tLastID = 737,
- "Energy Cluster",
- "Reusable battery",
- "batteryUV",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
+ ItemList.Energy_Cluster.set(
+ addItem(
+ tLastID = 737,
+ "Energy Cluster",
+ "Reusable battery",
+ "batteryUV",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L)));
setElectricStats(32000 + tLastID, 100000000000L, GT_Values.V[8], 8L, -3L, true);
OreDictionary.registerOre("UV", ItemList.Energy_Cluster.get(1));
// UIV, UMV, UXV and MAX component textures backported from gregicality.
- ItemList.Electric_Motor_LV.set(addItem(
- 600,
- "Electric Motor (LV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
- ItemList.Electric_Motor_MV.set(addItem(
- 601,
- "Electric Motor (MV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
- ItemList.Electric_Motor_HV.set(addItem(
- 602,
- "Electric Motor (HV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 4L)));
- ItemList.Electric_Motor_EV.set(addItem(
- 603,
- "Electric Motor (EV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 8L)));
- ItemList.Electric_Motor_IV.set(addItem(
- 604,
- "Electric Motor (IV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 16L)));
- ItemList.Electric_Motor_LuV.set(addItem(
- 606,
- "Electric Motor (LuV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 32L)));
- ItemList.Electric_Motor_ZPM.set(addItem(
- 607,
- "Electric Motor (ZPM)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 64L)));
- ItemList.Electric_Motor_UV.set(addItem(
- 608,
- "Electric Motor (UV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 128L)));
- ItemList.Electric_Motor_UHV.set(addItem(
- 596,
- "Electric Motor (UHV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 256L)));
- ItemList.Electric_Motor_UEV.set(addItem(
- 595,
- "Electric Motor (UEV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Motor_UIV.set(addItem(
- 17,
- "Electric Motor (UIV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Motor_UMV.set(addItem(
- 18,
- "Electric Motor (UMV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Motor_UXV.set(addItem(
- 19,
- "Electric Motor (UXV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Motor_MAX.set(addItem(
- 20,
- "Electric Motor (MAX)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Motor_LV.set(
+ addItem(
+ 600,
+ "Electric Motor (LV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
+ ItemList.Electric_Motor_MV.set(
+ addItem(
+ 601,
+ "Electric Motor (MV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
+ ItemList.Electric_Motor_HV.set(
+ addItem(
+ 602,
+ "Electric Motor (HV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 4L)));
+ ItemList.Electric_Motor_EV.set(
+ addItem(
+ 603,
+ "Electric Motor (EV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 8L)));
+ ItemList.Electric_Motor_IV.set(
+ addItem(
+ 604,
+ "Electric Motor (IV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 16L)));
+ ItemList.Electric_Motor_LuV.set(
+ addItem(
+ 606,
+ "Electric Motor (LuV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 32L)));
+ ItemList.Electric_Motor_ZPM.set(
+ addItem(
+ 607,
+ "Electric Motor (ZPM)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 64L)));
+ ItemList.Electric_Motor_UV.set(
+ addItem(
+ 608,
+ "Electric Motor (UV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 128L)));
+ ItemList.Electric_Motor_UHV.set(
+ addItem(
+ 596,
+ "Electric Motor (UHV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 256L)));
+ ItemList.Electric_Motor_UEV.set(
+ addItem(
+ 595,
+ "Electric Motor (UEV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Motor_UIV.set(
+ addItem(
+ 17,
+ "Electric Motor (UIV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Motor_UMV.set(
+ addItem(
+ 18,
+ "Electric Motor (UMV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Motor_UXV.set(
+ addItem(
+ 19,
+ "Electric Motor (UXV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Motor_MAX.set(
+ addItem(
+ 20,
+ "Electric Motor (MAX)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Motor_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CWR",
- "WIW",
- "RWC",
- 'I',
- OrePrefixes.stick.get(Materials.IronMagnetic),
- 'R',
- OrePrefixes.stick.get(Materials.AnyIron),
- 'W',
- OrePrefixes.wireGt01.get(Materials.AnyCopper),
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tin)
- });
+ new Object[] { "CWR", "WIW", "RWC", 'I', OrePrefixes.stick.get(Materials.IronMagnetic), 'R',
+ OrePrefixes.stick.get(Materials.AnyIron), 'W', OrePrefixes.wireGt01.get(Materials.AnyCopper),
+ 'C', OrePrefixes.cableGt01.get(Materials.Tin) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Motor_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CWR",
- "WIW",
- "RWC",
- 'I',
- OrePrefixes.stick.get(Materials.SteelMagnetic),
- 'R',
- OrePrefixes.stick.get(Materials.Steel),
- 'W',
- OrePrefixes.wireGt01.get(Materials.AnyCopper),
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tin)
- });
+ new Object[] { "CWR", "WIW", "RWC", 'I', OrePrefixes.stick.get(Materials.SteelMagnetic), 'R',
+ OrePrefixes.stick.get(Materials.Steel), 'W', OrePrefixes.wireGt01.get(Materials.AnyCopper), 'C',
+ OrePrefixes.cableGt01.get(Materials.Tin) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Motor_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CWR",
- "WIW",
- "RWC",
- 'I',
- OrePrefixes.stick.get(Materials.SteelMagnetic),
- 'R',
- OrePrefixes.stick.get(Materials.Aluminium),
- 'W',
- OrePrefixes.wireGt02.get(Materials.Cupronickel),
- 'C',
- OrePrefixes.cableGt01.get(Materials.AnyCopper)
- });
+ new Object[] { "CWR", "WIW", "RWC", 'I', OrePrefixes.stick.get(Materials.SteelMagnetic), 'R',
+ OrePrefixes.stick.get(Materials.Aluminium), 'W',
+ OrePrefixes.wireGt02.get(Materials.Cupronickel), 'C',
+ OrePrefixes.cableGt01.get(Materials.AnyCopper) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Motor_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CWR",
- "WIW",
- "RWC",
- 'I',
- OrePrefixes.stick.get(Materials.SteelMagnetic),
- 'R',
- OrePrefixes.stick.get(Materials.StainlessSteel),
- 'W',
- OrePrefixes.wireGt04.get(Materials.Electrum),
- 'C',
- OrePrefixes.cableGt02.get(Materials.Silver)
- });
+ new Object[] { "CWR", "WIW", "RWC", 'I', OrePrefixes.stick.get(Materials.SteelMagnetic), 'R',
+ OrePrefixes.stick.get(Materials.StainlessSteel), 'W',
+ OrePrefixes.wireGt04.get(Materials.Electrum), 'C',
+ OrePrefixes.cableGt02.get(Materials.Silver) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Motor_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CWR",
- "WIW",
- "RWC",
- 'I',
- OrePrefixes.stick.get(Materials.NeodymiumMagnetic),
- 'R',
- OrePrefixes.stick.get(Materials.Titanium),
- 'W',
- OrePrefixes.wireGt04.get(Materials.BlackSteel),
- 'C',
- OrePrefixes.cableGt02.get(Materials.Aluminium)
- });
+ new Object[] { "CWR", "WIW", "RWC", 'I', OrePrefixes.stick.get(Materials.NeodymiumMagnetic), 'R',
+ OrePrefixes.stick.get(Materials.Titanium), 'W', OrePrefixes.wireGt04.get(Materials.BlackSteel),
+ 'C', OrePrefixes.cableGt02.get(Materials.Aluminium) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Motor_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CWR",
- "WIW",
- "RWC",
- 'I',
- OrePrefixes.stick.get(Materials.NeodymiumMagnetic),
- 'R',
- OrePrefixes.stick.get(Materials.TungstenSteel),
- 'W',
- OrePrefixes.wireGt04.get(Materials.Graphene),
- 'C',
- OrePrefixes.cableGt02.get(Materials.Tungsten)
- });
-
- ItemList.Tesseract.set(addItem(
- 415,
- "Raw Tesseract",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
- ItemList.GigaChad.set(addItem(
- 416, "Giga Chad Token", "You are worthy", new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1000L)));
- ItemList.EnergisedTesseract.set(addItem(
- 417,
- "Energised Tesseract",
- "Higher dimensional engineering",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 10L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
-
- ItemList.Electric_Piston_LV.set(addItem(
- 640,
- "Electric Piston (LV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
- ItemList.Electric_Piston_MV.set(addItem(
- 641,
- "Electric Piston (MV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
- ItemList.Electric_Piston_HV.set(addItem(
- 642,
- "Electric Piston (HV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 4L)));
- ItemList.Electric_Piston_EV.set(addItem(
- 643,
- "Electric Piston (EV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 8L)));
- ItemList.Electric_Piston_IV.set(addItem(
- 644,
- "Electric Piston (IV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 16L)));
- ItemList.Electric_Piston_LuV.set(addItem(
- 645,
- "Electric Piston (LuV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 32L)));
- ItemList.Electric_Piston_ZPM.set(addItem(
- 646,
- "Electric Piston (ZPM)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 64L)));
- ItemList.Electric_Piston_UV.set(addItem(
- 647,
- "Electric Piston (UV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 128L)));
- ItemList.Electric_Piston_UHV.set(addItem(
- 648,
- "Electric Piston (UHV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 256L)));
- ItemList.Electric_Piston_UEV.set(addItem(
- 649,
- "Electric Piston (UEV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Piston_UIV.set(addItem(
- 21,
- "Electric Piston (UIV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Piston_UMV.set(addItem(
- 22,
- "Electric Piston (UMV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Piston_UXV.set(addItem(
- 23,
- "Electric Piston (UXV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
- ItemList.Electric_Piston_MAX.set(addItem(
- 24,
- "Electric Piston (MAX)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ new Object[] { "CWR", "WIW", "RWC", 'I', OrePrefixes.stick.get(Materials.NeodymiumMagnetic), 'R',
+ OrePrefixes.stick.get(Materials.TungstenSteel), 'W',
+ OrePrefixes.wireGt04.get(Materials.Graphene), 'C',
+ OrePrefixes.cableGt02.get(Materials.Tungsten) });
+
+ ItemList.Tesseract.set(
+ addItem(
+ 415,
+ "Raw Tesseract",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
+ ItemList.GigaChad.set(
+ addItem(
+ 416,
+ "Giga Chad Token",
+ "You are worthy",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1000L)));
+ ItemList.EnergisedTesseract.set(
+ addItem(
+ 417,
+ "Energised Tesseract",
+ "Higher dimensional engineering",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 10L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
+
+ ItemList.Electric_Piston_LV.set(
+ addItem(
+ 640,
+ "Electric Piston (LV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
+ ItemList.Electric_Piston_MV.set(
+ addItem(
+ 641,
+ "Electric Piston (MV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
+ ItemList.Electric_Piston_HV.set(
+ addItem(
+ 642,
+ "Electric Piston (HV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 4L)));
+ ItemList.Electric_Piston_EV.set(
+ addItem(
+ 643,
+ "Electric Piston (EV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 8L)));
+ ItemList.Electric_Piston_IV.set(
+ addItem(
+ 644,
+ "Electric Piston (IV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 16L)));
+ ItemList.Electric_Piston_LuV.set(
+ addItem(
+ 645,
+ "Electric Piston (LuV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 32L)));
+ ItemList.Electric_Piston_ZPM.set(
+ addItem(
+ 646,
+ "Electric Piston (ZPM)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 64L)));
+ ItemList.Electric_Piston_UV.set(
+ addItem(
+ 647,
+ "Electric Piston (UV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 128L)));
+ ItemList.Electric_Piston_UHV.set(
+ addItem(
+ 648,
+ "Electric Piston (UHV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 256L)));
+ ItemList.Electric_Piston_UEV.set(
+ addItem(
+ 649,
+ "Electric Piston (UEV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Piston_UIV.set(
+ addItem(
+ 21,
+ "Electric Piston (UIV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Piston_UMV.set(
+ addItem(
+ 22,
+ "Electric Piston (UMV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Piston_UXV.set(
+ addItem(
+ 23,
+ "Electric Piston (UXV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
+ ItemList.Electric_Piston_MAX.set(
+ addItem(
+ 24,
+ "Electric Piston (MAX)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Piston_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "PPP",
- "CSS",
- "CMG",
- 'P',
- OrePrefixes.plate.get(Materials.Steel),
- 'S',
- OrePrefixes.stick.get(Materials.Steel),
- 'G',
- OrePrefixes.gearGtSmall.get(Materials.Steel),
- 'M',
- ItemList.Electric_Motor_LV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tin)
- });
+ new Object[] { "PPP", "CSS", "CMG", 'P', OrePrefixes.plate.get(Materials.Steel), 'S',
+ OrePrefixes.stick.get(Materials.Steel), 'G', OrePrefixes.gearGtSmall.get(Materials.Steel), 'M',
+ ItemList.Electric_Motor_LV, 'C', OrePrefixes.cableGt01.get(Materials.Tin) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Piston_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "PPP",
- "CSS",
- "CMG",
- 'P',
- OrePrefixes.plate.get(Materials.Aluminium),
- 'S',
- OrePrefixes.stick.get(Materials.Aluminium),
- 'G',
- OrePrefixes.gearGtSmall.get(Materials.Aluminium),
- 'M',
- ItemList.Electric_Motor_MV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.AnyCopper)
- });
+ new Object[] { "PPP", "CSS", "CMG", 'P', OrePrefixes.plate.get(Materials.Aluminium), 'S',
+ OrePrefixes.stick.get(Materials.Aluminium), 'G',
+ OrePrefixes.gearGtSmall.get(Materials.Aluminium), 'M', ItemList.Electric_Motor_MV, 'C',
+ OrePrefixes.cableGt01.get(Materials.AnyCopper) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Piston_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "PPP",
- "CSS",
- "CMG",
- 'P',
- OrePrefixes.plate.get(Materials.StainlessSteel),
- 'S',
- OrePrefixes.stick.get(Materials.StainlessSteel),
- 'G',
- OrePrefixes.gearGtSmall.get(Materials.StainlessSteel),
- 'M',
- ItemList.Electric_Motor_HV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Gold)
- });
+ new Object[] { "PPP", "CSS", "CMG", 'P', OrePrefixes.plate.get(Materials.StainlessSteel), 'S',
+ OrePrefixes.stick.get(Materials.StainlessSteel), 'G',
+ OrePrefixes.gearGtSmall.get(Materials.StainlessSteel), 'M', ItemList.Electric_Motor_HV, 'C',
+ OrePrefixes.cableGt01.get(Materials.Gold) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Piston_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "PPP",
- "CSS",
- "CMG",
- 'P',
- OrePrefixes.plate.get(Materials.Titanium),
- 'S',
- OrePrefixes.stick.get(Materials.Titanium),
- 'G',
- OrePrefixes.gearGtSmall.get(Materials.Titanium),
- 'M',
- ItemList.Electric_Motor_EV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Aluminium)
- });
+ new Object[] { "PPP", "CSS", "CMG", 'P', OrePrefixes.plate.get(Materials.Titanium), 'S',
+ OrePrefixes.stick.get(Materials.Titanium), 'G', OrePrefixes.gearGtSmall.get(Materials.Titanium),
+ 'M', ItemList.Electric_Motor_EV, 'C', OrePrefixes.cableGt01.get(Materials.Aluminium) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Piston_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "PPP",
- "CSS",
- "CMG",
- 'P',
- OrePrefixes.plate.get(Materials.TungstenSteel),
- 'S',
- OrePrefixes.stick.get(Materials.TungstenSteel),
- 'G',
- OrePrefixes.gearGtSmall.get(Materials.TungstenSteel),
- 'M',
- ItemList.Electric_Motor_IV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tungsten)
- });
-
- ItemList.Electric_Pump_LV.set(addItem(
- 610,
- "Electric Pump (LV)",
- GT_Utility.formatNumbers(32) + PartCoverText + GT_Utility.formatNumbers(32 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
- ItemList.Electric_Pump_MV.set(addItem(
- 611,
- "Electric Pump (MV)",
- GT_Utility.formatNumbers(128) + PartCoverText + GT_Utility.formatNumbers(128 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
- ItemList.Electric_Pump_HV.set(addItem(
- 612,
- "Electric Pump (HV)",
- GT_Utility.formatNumbers(512) + PartCoverText + GT_Utility.formatNumbers(512 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 4L)));
- ItemList.Electric_Pump_EV.set(addItem(
- 613,
- "Electric Pump (EV)",
- GT_Utility.formatNumbers(2048) + PartCoverText + GT_Utility.formatNumbers(2048 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 8L)));
- ItemList.Electric_Pump_IV.set(addItem(
- 614,
- "Electric Pump (IV)",
- GT_Utility.formatNumbers(8192) + PartCoverText + GT_Utility.formatNumbers(8192 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 16L)));
- ItemList.Electric_Pump_LuV.set(addItem(
- 615,
- "Electric Pump (LuV)",
- GT_Utility.formatNumbers(32768) + PartCoverText + GT_Utility.formatNumbers(32768 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 32L)));
- ItemList.Electric_Pump_ZPM.set(addItem(
- 616,
- "Electric Pump (ZPM)",
- GT_Utility.formatNumbers(131072)
- + PartCoverText
- + GT_Utility.formatNumbers(131072 * 20)
- + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 64L)));
- ItemList.Electric_Pump_UV.set(addItem(
- 617,
- "Electric Pump (UV)",
- GT_Utility.formatNumbers(524288)
- + PartCoverText
- + GT_Utility.formatNumbers(524288 * 20)
- + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 128L)));
- ItemList.Electric_Pump_UHV.set(addItem(
- 618,
- "Electric Pump (UHV)",
- GT_Utility.formatNumbers(1048576)
- + PartCoverText
- + GT_Utility.formatNumbers(1048576 * 20)
- + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 256L)));
- ItemList.Electric_Pump_UEV.set(addItem(
- 619,
- "Electric Pump (UEV)",
- GT_Utility.formatNumbers(2097152)
- + PartCoverText
- + GT_Utility.formatNumbers(2097152 * 20)
- + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
- ItemList.Electric_Pump_UIV.set(addItem(
- 25,
- "Electric Pump (UIV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
- ItemList.Electric_Pump_UMV.set(addItem(
- 26,
- "Electric Pump (UMV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
- ItemList.Electric_Pump_UXV.set(addItem(
- 27,
- "Electric Pump (UXV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
- ItemList.Electric_Pump_MAX.set(addItem(
- 28,
- "Electric Pump (MAX)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
+ new Object[] { "PPP", "CSS", "CMG", 'P', OrePrefixes.plate.get(Materials.TungstenSteel), 'S',
+ OrePrefixes.stick.get(Materials.TungstenSteel), 'G',
+ OrePrefixes.gearGtSmall.get(Materials.TungstenSteel), 'M', ItemList.Electric_Motor_IV, 'C',
+ OrePrefixes.cableGt01.get(Materials.Tungsten) });
+
+ ItemList.Electric_Pump_LV.set(
+ addItem(
+ 610,
+ "Electric Pump (LV)",
+ GT_Utility.formatNumbers(32) + PartCoverText
+ + GT_Utility.formatNumbers(32 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
+ ItemList.Electric_Pump_MV.set(
+ addItem(
+ 611,
+ "Electric Pump (MV)",
+ GT_Utility.formatNumbers(128) + PartCoverText
+ + GT_Utility.formatNumbers(128 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+ ItemList.Electric_Pump_HV.set(
+ addItem(
+ 612,
+ "Electric Pump (HV)",
+ GT_Utility.formatNumbers(512) + PartCoverText
+ + GT_Utility.formatNumbers(512 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 4L)));
+ ItemList.Electric_Pump_EV.set(
+ addItem(
+ 613,
+ "Electric Pump (EV)",
+ GT_Utility.formatNumbers(2048) + PartCoverText
+ + GT_Utility.formatNumbers(2048 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 8L)));
+ ItemList.Electric_Pump_IV.set(
+ addItem(
+ 614,
+ "Electric Pump (IV)",
+ GT_Utility.formatNumbers(8192) + PartCoverText
+ + GT_Utility.formatNumbers(8192 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 16L)));
+ ItemList.Electric_Pump_LuV.set(
+ addItem(
+ 615,
+ "Electric Pump (LuV)",
+ GT_Utility.formatNumbers(32768) + PartCoverText
+ + GT_Utility.formatNumbers(32768 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 32L)));
+ ItemList.Electric_Pump_ZPM.set(
+ addItem(
+ 616,
+ "Electric Pump (ZPM)",
+ GT_Utility.formatNumbers(131072) + PartCoverText
+ + GT_Utility.formatNumbers(131072 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 64L)));
+ ItemList.Electric_Pump_UV.set(
+ addItem(
+ 617,
+ "Electric Pump (UV)",
+ GT_Utility.formatNumbers(524288) + PartCoverText
+ + GT_Utility.formatNumbers(524288 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 128L)));
+ ItemList.Electric_Pump_UHV.set(
+ addItem(
+ 618,
+ "Electric Pump (UHV)",
+ GT_Utility.formatNumbers(1048576) + PartCoverText
+ + GT_Utility.formatNumbers(1048576 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 256L)));
+ ItemList.Electric_Pump_UEV.set(
+ addItem(
+ 619,
+ "Electric Pump (UEV)",
+ GT_Utility.formatNumbers(2097152) + PartCoverText
+ + GT_Utility.formatNumbers(2097152 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
+ ItemList.Electric_Pump_UIV.set(
+ addItem(
+ 25,
+ "Electric Pump (UIV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
+ ItemList.Electric_Pump_UMV.set(
+ addItem(
+ 26,
+ "Electric Pump (UMV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
+ ItemList.Electric_Pump_UXV.set(
+ addItem(
+ 27,
+ "Electric Pump (UXV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
+ ItemList.Electric_Pump_MAX.set(
+ addItem(
+ 28,
+ "Electric Pump (MAX)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 512L)));
GregTech_API.registerCover(
ItemList.Electric_Pump_LV.get(1L),
@@ -2706,155 +2408,103 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Pump_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SXO",
- "dPw",
- "OMW",
- 'M',
- ItemList.Electric_Motor_LV,
- 'O',
- OrePrefixes.ring.get(Materials.AnyRubber),
- 'X',
- OrePrefixes.rotor.get(Materials.Tin),
- 'S',
- OrePrefixes.screw.get(Materials.Tin),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Tin),
- 'P',
- OrePrefixes.pipeMedium.get(Materials.Bronze)
- });
+ new Object[] { "SXO", "dPw", "OMW", 'M', ItemList.Electric_Motor_LV, 'O',
+ OrePrefixes.ring.get(Materials.AnyRubber), 'X', OrePrefixes.rotor.get(Materials.Tin), 'S',
+ OrePrefixes.screw.get(Materials.Tin), 'W', OrePrefixes.cableGt01.get(Materials.Tin), 'P',
+ OrePrefixes.pipeMedium.get(Materials.Bronze) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Pump_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SXO",
- "dPw",
- "OMW",
- 'M',
- ItemList.Electric_Motor_MV,
- 'O',
- OrePrefixes.ring.get(Materials.AnyRubber),
- 'X',
- OrePrefixes.rotor.get(Materials.Bronze),
- 'S',
- OrePrefixes.screw.get(Materials.Bronze),
- 'W',
- OrePrefixes.cableGt01.get(Materials.AnyCopper),
- 'P',
- OrePrefixes.pipeMedium.get(Materials.Steel)
- });
+ new Object[] { "SXO", "dPw", "OMW", 'M', ItemList.Electric_Motor_MV, 'O',
+ OrePrefixes.ring.get(Materials.AnyRubber), 'X', OrePrefixes.rotor.get(Materials.Bronze), 'S',
+ OrePrefixes.screw.get(Materials.Bronze), 'W', OrePrefixes.cableGt01.get(Materials.AnyCopper),
+ 'P', OrePrefixes.pipeMedium.get(Materials.Steel) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Pump_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SXO",
- "dPw",
- "OMW",
- 'M',
- ItemList.Electric_Motor_HV,
- 'O',
- OrePrefixes.ring.get(Materials.AnyRubber),
- 'X',
- OrePrefixes.rotor.get(Materials.Steel),
- 'S',
- OrePrefixes.screw.get(Materials.Steel),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Gold),
- 'P',
- OrePrefixes.pipeMedium.get(Materials.StainlessSteel)
- });
+ new Object[] { "SXO", "dPw", "OMW", 'M', ItemList.Electric_Motor_HV, 'O',
+ OrePrefixes.ring.get(Materials.AnyRubber), 'X', OrePrefixes.rotor.get(Materials.Steel), 'S',
+ OrePrefixes.screw.get(Materials.Steel), 'W', OrePrefixes.cableGt01.get(Materials.Gold), 'P',
+ OrePrefixes.pipeMedium.get(Materials.StainlessSteel) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Pump_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SXO",
- "dPw",
- "OMW",
- 'M',
- ItemList.Electric_Motor_EV,
- 'O',
- OrePrefixes.ring.get(Materials.AnyRubber),
- 'X',
- OrePrefixes.rotor.get(Materials.StainlessSteel),
- 'S',
- OrePrefixes.screw.get(Materials.StainlessSteel),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Aluminium),
- 'P',
- OrePrefixes.pipeMedium.get(Materials.Titanium)
- });
+ new Object[] { "SXO", "dPw", "OMW", 'M', ItemList.Electric_Motor_EV, 'O',
+ OrePrefixes.ring.get(Materials.AnyRubber), 'X', OrePrefixes.rotor.get(Materials.StainlessSteel),
+ 'S', OrePrefixes.screw.get(Materials.StainlessSteel), 'W',
+ OrePrefixes.cableGt01.get(Materials.Aluminium), 'P',
+ OrePrefixes.pipeMedium.get(Materials.Titanium) });
GT_ModHandler.addCraftingRecipe(
ItemList.Electric_Pump_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SXO",
- "dPw",
- "OMW",
- 'M',
- ItemList.Electric_Motor_IV,
- 'O',
- OrePrefixes.ring.get(Materials.AnySyntheticRubber),
- 'X',
- OrePrefixes.rotor.get(Materials.TungstenSteel),
- 'S',
- OrePrefixes.screw.get(Materials.TungstenSteel),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Tungsten),
- 'P',
- OrePrefixes.pipeMedium.get(Materials.TungstenSteel)
- });
-
- ItemList.Steam_Valve_LV.set(addItem(
- 620,
- "Steam Valve (LV)",
- GT_Utility.formatNumbers(1024) + PartCoverText + GT_Utility.formatNumbers(1024 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
- ItemList.Steam_Valve_MV.set(addItem(
- 621,
- "Steam Valve (MV)",
- GT_Utility.formatNumbers(2048) + PartCoverText + GT_Utility.formatNumbers(2048 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
- ItemList.Steam_Valve_HV.set(addItem(
- 622,
- "Steam Valve (HV)",
- GT_Utility.formatNumbers(4096) + PartCoverText + GT_Utility.formatNumbers(4096 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 4L)));
- ItemList.Steam_Valve_EV.set(addItem(
- 623,
- "Steam Valve (EV)",
- GT_Utility.formatNumbers(8192) + PartCoverText + GT_Utility.formatNumbers(8192 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 8L)));
- ItemList.Steam_Valve_IV.set(addItem(
- 624,
- "Steam Valve (IV)",
- GT_Utility.formatNumbers(16384) + PartCoverText + GT_Utility.formatNumbers(16384 * 20) + PartCoverText2,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 16L)));
+ new Object[] { "SXO", "dPw", "OMW", 'M', ItemList.Electric_Motor_IV, 'O',
+ OrePrefixes.ring.get(Materials.AnySyntheticRubber), 'X',
+ OrePrefixes.rotor.get(Materials.TungstenSteel), 'S',
+ OrePrefixes.screw.get(Materials.TungstenSteel), 'W',
+ OrePrefixes.cableGt01.get(Materials.Tungsten), 'P',
+ OrePrefixes.pipeMedium.get(Materials.TungstenSteel) });
+
+ ItemList.Steam_Valve_LV.set(
+ addItem(
+ 620,
+ "Steam Valve (LV)",
+ GT_Utility.formatNumbers(1024) + PartCoverText
+ + GT_Utility.formatNumbers(1024 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
+ ItemList.Steam_Valve_MV.set(
+ addItem(
+ 621,
+ "Steam Valve (MV)",
+ GT_Utility.formatNumbers(2048) + PartCoverText
+ + GT_Utility.formatNumbers(2048 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+ ItemList.Steam_Valve_HV.set(
+ addItem(
+ 622,
+ "Steam Valve (HV)",
+ GT_Utility.formatNumbers(4096) + PartCoverText
+ + GT_Utility.formatNumbers(4096 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 4L)));
+ ItemList.Steam_Valve_EV.set(
+ addItem(
+ 623,
+ "Steam Valve (EV)",
+ GT_Utility.formatNumbers(8192) + PartCoverText
+ + GT_Utility.formatNumbers(8192 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 8L)));
+ ItemList.Steam_Valve_IV.set(
+ addItem(
+ 624,
+ "Steam Valve (IV)",
+ GT_Utility.formatNumbers(16384) + PartCoverText
+ + GT_Utility.formatNumbers(16384 * 20)
+ + PartCoverText2,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 16L)));
GregTech_API.registerCover(
ItemList.Steam_Valve_LV.get(1L),
@@ -2877,8 +2527,8 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
TextureFactory.of(MACHINE_CASINGS[5][0], TextureFactory.of(OVERLAY_VALVE)),
new GT_Cover_SteamValve(16384, TextureFactory.of(OVERLAY_VALVE)));
- ItemList.FluidRegulator_LV.set(
- addItem(tLastID = 660, "Fluid Regulator (LV)", FRText1 + GT_Utility.formatNumbers(640) + FRText2));
+ ItemList.FluidRegulator_LV
+ .set(addItem(tLastID = 660, "Fluid Regulator (LV)", FRText1 + GT_Utility.formatNumbers(640) + FRText2));
ItemList.FluidRegulator_MV.set(
addItem(tLastID = 661, "Fluid Regulator (MV)", FRText1 + GT_Utility.formatNumbers(2560) + FRText2));
ItemList.FluidRegulator_HV.set(
@@ -2927,214 +2577,183 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
TextureFactory.of(MACHINE_CASINGS[8][0], TextureFactory.of(OVERLAY_PUMP)),
new GT_Cover_FluidRegulator(524288, TextureFactory.of(OVERLAY_PUMP)));
- ItemList.FluidFilter.set(
- addItem(669, "Fluid Filter Cover", "Set with Fluid Container to only accept one Fluid Type"));
+ ItemList.FluidFilter
+ .set(addItem(669, "Fluid Filter Cover", "Set with Fluid Container to only accept one Fluid Type"));
GregTech_API.registerCover(
ItemList.FluidFilter.get(1L),
TextureFactory.of(MACHINE_CASINGS[1][0], TextureFactory.of(OVERLAY_SHUTTER)),
new GT_Cover_Fluidfilter(TextureFactory.of(OVERLAY_SHUTTER)));
- ItemList.ItemFilter_Export.set(addItem(
- 270,
- "Item Filter Cover (Export)",
- "Right click with an item to set filter (Only supports Export Mode)"));
+ ItemList.ItemFilter_Export.set(
+ addItem(
+ 270,
+ "Item Filter Cover (Export)",
+ "Right click with an item to set filter (Only supports Export Mode)"));
GregTech_API.registerCover(
ItemList.ItemFilter_Export.get(1L),
TextureFactory.of(MACHINE_CASINGS[5][0], TextureFactory.of(OVERLAY_CONVEYOR)),
new GT_Cover_ItemFilter(true, TextureFactory.of(OVERLAY_CONVEYOR)));
- ItemList.ItemFilter_Import.set(addItem(
- 271,
- "Item Filter Cover (Import)",
- "Right click with an item to set filter (Only supports Import Mode)"));
+ ItemList.ItemFilter_Import.set(
+ addItem(
+ 271,
+ "Item Filter Cover (Import)",
+ "Right click with an item to set filter (Only supports Import Mode)"));
GregTech_API.registerCover(
ItemList.ItemFilter_Import.get(1L),
TextureFactory.of(MACHINE_CASINGS[5][0], TextureFactory.of(OVERLAY_CONVEYOR)),
new GT_Cover_ItemFilter(false, TextureFactory.of(OVERLAY_CONVEYOR)));
- ItemList.Cover_FluidLimiter.set(
- addItem(272, "Fluid Limiter Cover", "Limits fluid input depending on fill level"));
+ ItemList.Cover_FluidLimiter
+ .set(addItem(272, "Fluid Limiter Cover", "Limits fluid input depending on fill level"));
GregTech_API.registerCover(
ItemList.Cover_FluidLimiter.get(1L),
TextureFactory.of(MACHINE_CASINGS[1][0], TextureFactory.of(OVERLAY_SHUTTER)),
new GT_Cover_FluidLimiter(TextureFactory.of(OVERLAY_SHUTTER)));
- ItemList.Conveyor_Module_LV.set(addItem(
- 630,
- "Conveyor Module (LV)",
- "1 stack every 20 secs (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
- ItemList.Conveyor_Module_MV.set(addItem(
- 631,
- "Conveyor Module (MV)",
- "1 stack every 5 secs (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L)));
- ItemList.Conveyor_Module_HV.set(addItem(
- 632,
- "Conveyor Module (HV)",
- "1 stack every 1 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 4L)));
- ItemList.Conveyor_Module_EV.set(addItem(
- 633,
- "Conveyor Module (EV)",
- "1 stack every 1/5 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 8L)));
- ItemList.Conveyor_Module_IV.set(addItem(
- 634,
- "Conveyor Module (IV)",
- "1 stack every 1/20 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 16L)));
- ItemList.Conveyor_Module_LuV.set(addItem(
- 635,
- "Conveyor Module (LuV)",
- "2 stacks every 1/20 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 32L)));
- ItemList.Conveyor_Module_ZPM.set(addItem(
- 636,
- "Conveyor Module (ZPM)",
- "4 stacks every 1/20 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 64L)));
- ItemList.Conveyor_Module_UV.set(addItem(
- 637,
- "Conveyor Module (UV)",
- "8 stacks every 1/20 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 128L)));
- ItemList.Conveyor_Module_UHV.set(addItem(
- 638,
- "Conveyor Module (UHV)",
- "16 stacks every 1/20 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 256L)));
- ItemList.Conveyor_Module_UEV.set(addItem(
- 639,
- "Conveyor Module (UEV)",
- "32 stacks every 1/20 sec (as Cover)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
- ItemList.Conveyor_Module_UIV.set(addItem(
- 29,
- "Conveyor Module (UIV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
- ItemList.Conveyor_Module_UMV.set(addItem(
- 30,
- "Conveyor Module (UMV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
- ItemList.Conveyor_Module_UXV.set(addItem(
- 31,
- "Conveyor Module (UXV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
- ItemList.Conveyor_Module_MAX.set(addItem(
- 32,
- "Conveyor Module (MAX)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
+ ItemList.Conveyor_Module_LV.set(
+ addItem(
+ 630,
+ "Conveyor Module (LV)",
+ "1 stack every 20 secs (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
+ ItemList.Conveyor_Module_MV.set(
+ addItem(
+ 631,
+ "Conveyor Module (MV)",
+ "1 stack every 5 secs (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 2L)));
+ ItemList.Conveyor_Module_HV.set(
+ addItem(
+ 632,
+ "Conveyor Module (HV)",
+ "1 stack every 1 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 4L)));
+ ItemList.Conveyor_Module_EV.set(
+ addItem(
+ 633,
+ "Conveyor Module (EV)",
+ "1 stack every 1/5 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 8L)));
+ ItemList.Conveyor_Module_IV.set(
+ addItem(
+ 634,
+ "Conveyor Module (IV)",
+ "1 stack every 1/20 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 16L)));
+ ItemList.Conveyor_Module_LuV.set(
+ addItem(
+ 635,
+ "Conveyor Module (LuV)",
+ "2 stacks every 1/20 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 32L)));
+ ItemList.Conveyor_Module_ZPM.set(
+ addItem(
+ 636,
+ "Conveyor Module (ZPM)",
+ "4 stacks every 1/20 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 64L)));
+ ItemList.Conveyor_Module_UV.set(
+ addItem(
+ 637,
+ "Conveyor Module (UV)",
+ "8 stacks every 1/20 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 128L)));
+ ItemList.Conveyor_Module_UHV.set(
+ addItem(
+ 638,
+ "Conveyor Module (UHV)",
+ "16 stacks every 1/20 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 256L)));
+ ItemList.Conveyor_Module_UEV.set(
+ addItem(
+ 639,
+ "Conveyor Module (UEV)",
+ "32 stacks every 1/20 sec (as Cover)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
+ ItemList.Conveyor_Module_UIV.set(
+ addItem(
+ 29,
+ "Conveyor Module (UIV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
+ ItemList.Conveyor_Module_UMV.set(
+ addItem(
+ 30,
+ "Conveyor Module (UMV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
+ ItemList.Conveyor_Module_UXV.set(
+ addItem(
+ 31,
+ "Conveyor Module (UXV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
+ ItemList.Conveyor_Module_MAX.set(
+ addItem(
+ 32,
+ "Conveyor Module (MAX)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 512L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Conveyor_Module_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "RRR",
- "MCM",
- "RRR",
- 'M',
- ItemList.Electric_Motor_LV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tin),
- 'R',
- OrePrefixes.plate.get(Materials.AnyRubber)
- });
+ new Object[] { "RRR", "MCM", "RRR", 'M', ItemList.Electric_Motor_LV, 'C',
+ OrePrefixes.cableGt01.get(Materials.Tin), 'R', OrePrefixes.plate.get(Materials.AnyRubber) });
GT_ModHandler.addCraftingRecipe(
ItemList.Conveyor_Module_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "RRR",
- "MCM",
- "RRR",
- 'M',
- ItemList.Electric_Motor_MV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.AnyCopper),
- 'R',
- OrePrefixes.plate.get(Materials.AnyRubber)
- });
+ new Object[] { "RRR", "MCM", "RRR", 'M', ItemList.Electric_Motor_MV, 'C',
+ OrePrefixes.cableGt01.get(Materials.AnyCopper), 'R',
+ OrePrefixes.plate.get(Materials.AnyRubber) });
GT_ModHandler.addCraftingRecipe(
ItemList.Conveyor_Module_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "RRR",
- "MCM",
- "RRR",
- 'M',
- ItemList.Electric_Motor_HV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Gold),
- 'R',
- OrePrefixes.plate.get(Materials.AnyRubber)
- });
+ new Object[] { "RRR", "MCM", "RRR", 'M', ItemList.Electric_Motor_HV, 'C',
+ OrePrefixes.cableGt01.get(Materials.Gold), 'R', OrePrefixes.plate.get(Materials.AnyRubber) });
GT_ModHandler.addCraftingRecipe(
ItemList.Conveyor_Module_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "RRR",
- "MCM",
- "RRR",
- 'M',
- ItemList.Electric_Motor_EV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Aluminium),
- 'R',
- OrePrefixes.plate.get(Materials.AnyRubber)
- });
+ new Object[] { "RRR", "MCM", "RRR", 'M', ItemList.Electric_Motor_EV, 'C',
+ OrePrefixes.cableGt01.get(Materials.Aluminium), 'R',
+ OrePrefixes.plate.get(Materials.AnyRubber) });
GT_ModHandler.addCraftingRecipe(
ItemList.Conveyor_Module_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "RRR",
- "MCM",
- "RRR",
- 'M',
- ItemList.Electric_Motor_IV,
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tungsten),
- 'R',
- OrePrefixes.plate.get(Materials.AnySyntheticRubber)
- });
+ new Object[] { "RRR", "MCM", "RRR", 'M', ItemList.Electric_Motor_IV, 'C',
+ OrePrefixes.cableGt01.get(Materials.Tungsten), 'R',
+ OrePrefixes.plate.get(Materials.AnySyntheticRubber) });
GregTech_API.registerCover(
ItemList.Conveyor_Module_LV.get(1L),
@@ -3177,219 +2796,168 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
TextureFactory.of(MACHINE_CASINGS[10][0], TextureFactory.of(OVERLAY_CONVEYOR)),
new GT_Cover_Conveyor(1, 32, TextureFactory.of(OVERLAY_CONVEYOR)));
- ItemList.Robot_Arm_LV.set(addItem(
- 650,
- "Robot Arm (LV)",
- "1 stack every 20 secs (as Cover)/n " + RAText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L)));
- ItemList.Robot_Arm_MV.set(addItem(
- 651,
- "Robot Arm (MV)",
- "1 stack every 5 secs (as Cover)/n " + RAText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
- ItemList.Robot_Arm_HV.set(addItem(
- 652,
- "Robot Arm (HV)",
- "1 stack every 1 sec (as Cover)/n " + RAText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 4L)));
- ItemList.Robot_Arm_EV.set(addItem(
- 653,
- "Robot Arm (EV)",
- "1 stack every 1/5 sec (as Cover)/n " + RAText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 8L)));
- ItemList.Robot_Arm_IV.set(addItem(
- 654,
- "Robot Arm (IV)",
- "1 stack every 1/20 sec (as Cover)/n " + RAText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 16L)));
- ItemList.Robot_Arm_LuV.set(addItem(
- 655,
- "Robot Arm (LuV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 32L)));
- ItemList.Robot_Arm_ZPM.set(addItem(
- 656,
- "Robot Arm (ZPM)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 64L)));
- ItemList.Robot_Arm_UV.set(addItem(
- 657,
- "Robot Arm (UV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 128L)));
- ItemList.Robot_Arm_UHV.set(addItem(
- 658,
- "Robot Arm (UHV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 256L)));
- ItemList.Robot_Arm_UEV.set(addItem(
- 659,
- "Robot Arm (UEV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
- ItemList.Robot_Arm_UIV.set(addItem(
- 33,
- "Robot Arm (UIV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
- ItemList.Robot_Arm_UMV.set(addItem(
- 34,
- "Robot Arm (UMV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
- ItemList.Robot_Arm_UXV.set(addItem(
- 35,
- "Robot Arm (UXV)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
- ItemList.Robot_Arm_MAX.set(addItem(
- 36,
- "Robot Arm (MAX)",
- PartNotCoverText,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
+ ItemList.Robot_Arm_LV.set(
+ addItem(
+ 650,
+ "Robot Arm (LV)",
+ "1 stack every 20 secs (as Cover)/n " + RAText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L)));
+ ItemList.Robot_Arm_MV.set(
+ addItem(
+ 651,
+ "Robot Arm (MV)",
+ "1 stack every 5 secs (as Cover)/n " + RAText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L)));
+ ItemList.Robot_Arm_HV.set(
+ addItem(
+ 652,
+ "Robot Arm (HV)",
+ "1 stack every 1 sec (as Cover)/n " + RAText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 4L)));
+ ItemList.Robot_Arm_EV.set(
+ addItem(
+ 653,
+ "Robot Arm (EV)",
+ "1 stack every 1/5 sec (as Cover)/n " + RAText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 8L)));
+ ItemList.Robot_Arm_IV.set(
+ addItem(
+ 654,
+ "Robot Arm (IV)",
+ "1 stack every 1/20 sec (as Cover)/n " + RAText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 16L)));
+ ItemList.Robot_Arm_LuV.set(
+ addItem(
+ 655,
+ "Robot Arm (LuV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 32L)));
+ ItemList.Robot_Arm_ZPM.set(
+ addItem(
+ 656,
+ "Robot Arm (ZPM)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 64L)));
+ ItemList.Robot_Arm_UV.set(
+ addItem(
+ 657,
+ "Robot Arm (UV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 128L)));
+ ItemList.Robot_Arm_UHV.set(
+ addItem(
+ 658,
+ "Robot Arm (UHV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 256L)));
+ ItemList.Robot_Arm_UEV.set(
+ addItem(
+ 659,
+ "Robot Arm (UEV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
+ ItemList.Robot_Arm_UIV.set(
+ addItem(
+ 33,
+ "Robot Arm (UIV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
+ ItemList.Robot_Arm_UMV.set(
+ addItem(
+ 34,
+ "Robot Arm (UMV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
+ ItemList.Robot_Arm_UXV.set(
+ addItem(
+ 35,
+ "Robot Arm (UXV)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
+ ItemList.Robot_Arm_MAX.set(
+ addItem(
+ 36,
+ "Robot Arm (MAX)",
+ PartNotCoverText,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 512L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Robot_Arm_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CCC",
- "MSM",
- "PES",
- 'S',
- OrePrefixes.stick.get(Materials.Steel),
- 'M',
- ItemList.Electric_Motor_LV,
- 'P',
- ItemList.Electric_Piston_LV,
- 'E',
- OrePrefixes.circuit.get(Materials.Basic),
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tin)
- });
+ new Object[] { "CCC", "MSM", "PES", 'S', OrePrefixes.stick.get(Materials.Steel), 'M',
+ ItemList.Electric_Motor_LV, 'P', ItemList.Electric_Piston_LV, 'E',
+ OrePrefixes.circuit.get(Materials.Basic), 'C', OrePrefixes.cableGt01.get(Materials.Tin) });
GT_ModHandler.addCraftingRecipe(
ItemList.Robot_Arm_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CCC",
- "MSM",
- "PES",
- 'S',
- OrePrefixes.stick.get(Materials.Aluminium),
- 'M',
- ItemList.Electric_Motor_MV,
- 'P',
- ItemList.Electric_Piston_MV,
- 'E',
- OrePrefixes.circuit.get(Materials.Good),
- 'C',
- OrePrefixes.cableGt01.get(Materials.AnyCopper)
- });
+ new Object[] { "CCC", "MSM", "PES", 'S', OrePrefixes.stick.get(Materials.Aluminium), 'M',
+ ItemList.Electric_Motor_MV, 'P', ItemList.Electric_Piston_MV, 'E',
+ OrePrefixes.circuit.get(Materials.Good), 'C', OrePrefixes.cableGt01.get(Materials.AnyCopper) });
GT_ModHandler.addCraftingRecipe(
ItemList.Robot_Arm_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CCC",
- "MSM",
- "PES",
- 'S',
- OrePrefixes.stick.get(Materials.StainlessSteel),
- 'M',
- ItemList.Electric_Motor_HV,
- 'P',
- ItemList.Electric_Piston_HV,
- 'E',
- OrePrefixes.circuit.get(Materials.Advanced),
- 'C',
- OrePrefixes.cableGt01.get(Materials.Gold)
- });
+ new Object[] { "CCC", "MSM", "PES", 'S', OrePrefixes.stick.get(Materials.StainlessSteel), 'M',
+ ItemList.Electric_Motor_HV, 'P', ItemList.Electric_Piston_HV, 'E',
+ OrePrefixes.circuit.get(Materials.Advanced), 'C', OrePrefixes.cableGt01.get(Materials.Gold) });
GT_ModHandler.addCraftingRecipe(
ItemList.Robot_Arm_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CCC",
- "MSM",
- "PES",
- 'S',
- OrePrefixes.stick.get(Materials.Titanium),
- 'M',
- ItemList.Electric_Motor_EV,
- 'P',
- ItemList.Electric_Piston_EV,
- 'E',
- OrePrefixes.circuit.get(Materials.Data),
- 'C',
- OrePrefixes.cableGt01.get(Materials.Aluminium)
- });
+ new Object[] { "CCC", "MSM", "PES", 'S', OrePrefixes.stick.get(Materials.Titanium), 'M',
+ ItemList.Electric_Motor_EV, 'P', ItemList.Electric_Piston_EV, 'E',
+ OrePrefixes.circuit.get(Materials.Data), 'C', OrePrefixes.cableGt01.get(Materials.Aluminium) });
GT_ModHandler.addCraftingRecipe(
ItemList.Robot_Arm_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "CCC",
- "MSM",
- "PES",
- 'S',
- OrePrefixes.stick.get(Materials.TungstenSteel),
- 'M',
- ItemList.Electric_Motor_IV,
- 'P',
- ItemList.Electric_Piston_IV,
- 'E',
- OrePrefixes.circuit.get(Materials.Elite),
- 'C',
- OrePrefixes.cableGt01.get(Materials.Tungsten)
- });
+ new Object[] { "CCC", "MSM", "PES", 'S', OrePrefixes.stick.get(Materials.TungstenSteel), 'M',
+ ItemList.Electric_Motor_IV, 'P', ItemList.Electric_Piston_IV, 'E',
+ OrePrefixes.circuit.get(Materials.Elite), 'C', OrePrefixes.cableGt01.get(Materials.Tungsten) });
GregTech_API.registerCover(
ItemList.Robot_Arm_LV.get(1L),
@@ -3416,607 +2984,552 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemList.QuantumStar.set(addItem(tLastID = 725, "Quantum Star", "Improved Nether Star"));
ItemList.Gravistar.set(addItem(tLastID = 726, "Gravi Star", "Ultimate Nether Star"));
- ItemList.Emitter_LV.set(addItem(
- 680,
- "Emitter (LV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 1L)));
- ItemList.Emitter_MV.set(addItem(
- 681,
- "Emitter (MV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 2L)));
- ItemList.Emitter_HV.set(addItem(
- 682,
- "Emitter (HV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 4L)));
- ItemList.Emitter_EV.set(addItem(
- 683,
- "Emitter (EV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 8L)));
- ItemList.Emitter_IV.set(addItem(
- 684,
- "Emitter (IV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 16L)));
- ItemList.Emitter_LuV.set(addItem(
- 685,
- "Emitter (LuV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 32L)));
- ItemList.Emitter_ZPM.set(addItem(
- 686,
- "Emitter (ZPM)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 64L)));
- ItemList.Emitter_UV.set(addItem(
- 687,
- "Emitter (UV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 128L)));
- ItemList.Emitter_UHV.set(addItem(
- 688,
- "Emitter (UHV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 256L)));
- ItemList.Emitter_UEV.set(addItem(
- 689,
- "Emitter (UEV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
- ItemList.Emitter_UIV.set(addItem(
- 37,
- "Emitter (UIV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
- ItemList.Emitter_UMV.set(addItem(
- 38,
- "Emitter (UMV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
- ItemList.Emitter_UXV.set(addItem(
- 39,
- "Emitter (UXV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
- ItemList.Emitter_MAX.set(addItem(
- 40,
- "Emitter (MAX)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
+ ItemList.Emitter_LV.set(
+ addItem(
+ 680,
+ "Emitter (LV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 1L)));
+ ItemList.Emitter_MV.set(
+ addItem(
+ 681,
+ "Emitter (MV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 2L)));
+ ItemList.Emitter_HV.set(
+ addItem(
+ 682,
+ "Emitter (HV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 4L)));
+ ItemList.Emitter_EV.set(
+ addItem(
+ 683,
+ "Emitter (EV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 8L)));
+ ItemList.Emitter_IV.set(
+ addItem(
+ 684,
+ "Emitter (IV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 16L)));
+ ItemList.Emitter_LuV.set(
+ addItem(
+ 685,
+ "Emitter (LuV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 32L)));
+ ItemList.Emitter_ZPM.set(
+ addItem(
+ 686,
+ "Emitter (ZPM)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 64L)));
+ ItemList.Emitter_UV.set(
+ addItem(
+ 687,
+ "Emitter (UV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 128L)));
+ ItemList.Emitter_UHV.set(
+ addItem(
+ 688,
+ "Emitter (UHV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 256L)));
+ ItemList.Emitter_UEV.set(
+ addItem(
+ 689,
+ "Emitter (UEV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
+ ItemList.Emitter_UIV.set(
+ addItem(
+ 37,
+ "Emitter (UIV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
+ ItemList.Emitter_UMV.set(
+ addItem(
+ 38,
+ "Emitter (UMV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
+ ItemList.Emitter_UXV.set(
+ addItem(
+ 39,
+ "Emitter (UXV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
+ ItemList.Emitter_MAX.set(
+ addItem(
+ 40,
+ "Emitter (MAX)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 512L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Emitter_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SSC",
- "WQS",
- "CWS",
- 'Q',
- OrePrefixes.gem.get(Materials.CertusQuartz),
- 'S',
- OrePrefixes.stick.get(Materials.Brass),
- 'C',
- OrePrefixes.circuit.get(Materials.Basic),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Tin)
- });
+ new Object[] { "SSC", "WQS", "CWS", 'Q', OrePrefixes.gem.get(Materials.CertusQuartz), 'S',
+ OrePrefixes.stick.get(Materials.Brass), 'C', OrePrefixes.circuit.get(Materials.Basic), 'W',
+ OrePrefixes.cableGt01.get(Materials.Tin) });
GT_ModHandler.addCraftingRecipe(
ItemList.Emitter_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SSC",
- "WQS",
- "CWS",
- 'Q',
- OrePrefixes.gem.get(Materials.EnderPearl),
- 'S',
- OrePrefixes.stick.get(Materials.Electrum),
- 'C',
- OrePrefixes.circuit.get(Materials.Good),
- 'W',
- OrePrefixes.cableGt01.get(Materials.AnyCopper)
- });
+ new Object[] { "SSC", "WQS", "CWS", 'Q', OrePrefixes.gem.get(Materials.EnderPearl), 'S',
+ OrePrefixes.stick.get(Materials.Electrum), 'C', OrePrefixes.circuit.get(Materials.Good), 'W',
+ OrePrefixes.cableGt01.get(Materials.AnyCopper) });
GT_ModHandler.addCraftingRecipe(
ItemList.Emitter_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SSC",
- "WQS",
- "CWS",
- 'Q',
- OrePrefixes.gem.get(Materials.EnderEye),
- 'S',
- OrePrefixes.stick.get(Materials.Chrome),
- 'C',
- OrePrefixes.circuit.get(Materials.Advanced),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Gold)
- });
+ new Object[] { "SSC", "WQS", "CWS", 'Q', OrePrefixes.gem.get(Materials.EnderEye), 'S',
+ OrePrefixes.stick.get(Materials.Chrome), 'C', OrePrefixes.circuit.get(Materials.Advanced), 'W',
+ OrePrefixes.cableGt01.get(Materials.Gold) });
GT_ModHandler.addCraftingRecipe(
ItemList.Emitter_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SSC",
- "WQS",
- "CWS",
- 'Q',
- ItemList.QuantumEye,
- 'S',
- OrePrefixes.stick.get(Materials.Platinum),
- 'C',
- OrePrefixes.circuit.get(Materials.Data),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Aluminium)
- });
+ new Object[] { "SSC", "WQS", "CWS", 'Q', ItemList.QuantumEye, 'S',
+ OrePrefixes.stick.get(Materials.Platinum), 'C', OrePrefixes.circuit.get(Materials.Data), 'W',
+ OrePrefixes.cableGt01.get(Materials.Aluminium) });
GT_ModHandler.addCraftingRecipe(
ItemList.Emitter_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "SSC",
- "WQS",
- "CWS",
- 'Q',
- ItemList.QuantumStar,
- 'S',
- OrePrefixes.stick.get(Materials.Iridium),
- 'C',
- OrePrefixes.circuit.get(Materials.Elite),
- 'W',
- OrePrefixes.cableGt01.get(Materials.Tungsten)
- });
-
- ItemList.Sensor_LV.set(addItem(
- 690,
- "Sensor (LV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L)));
- ItemList.Sensor_MV.set(addItem(
- 691,
- "Sensor (MV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L)));
- ItemList.Sensor_HV.set(addItem(
- 692,
- "Sensor (HV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 4L)));
- ItemList.Sensor_EV.set(addItem(
- 693,
- "Sensor (EV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 8L)));
- ItemList.Sensor_IV.set(addItem(
- 694,
- "Sensor (IV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 16L)));
- ItemList.Sensor_LuV.set(addItem(
- 695,
- "Sensor (LuV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 32L)));
- ItemList.Sensor_ZPM.set(addItem(
- 696,
- "Sensor (ZPM)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 64L)));
- ItemList.Sensor_UV.set(addItem(
- 697,
- "Sensor (UV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 128L)));
- ItemList.Sensor_UHV.set(addItem(
- 698,
- "Sensor (UHV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 256L)));
- ItemList.Sensor_UEV.set(addItem(
- 699,
- "Sensor (UEV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
- ItemList.Sensor_UIV.set(addItem(
- 41,
- "Sensor (UIV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
- ItemList.Sensor_UMV.set(addItem(
- 42,
- "Sensor (UMV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
- ItemList.Sensor_UXV.set(addItem(
- 43,
- "Sensor (UXV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
- ItemList.Sensor_MAX.set(addItem(
- 44,
- "Sensor (MAX)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
+ new Object[] { "SSC", "WQS", "CWS", 'Q', ItemList.QuantumStar, 'S',
+ OrePrefixes.stick.get(Materials.Iridium), 'C', OrePrefixes.circuit.get(Materials.Elite), 'W',
+ OrePrefixes.cableGt01.get(Materials.Tungsten) });
+
+ ItemList.Sensor_LV.set(
+ addItem(
+ 690,
+ "Sensor (LV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L)));
+ ItemList.Sensor_MV.set(
+ addItem(
+ 691,
+ "Sensor (MV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L)));
+ ItemList.Sensor_HV.set(
+ addItem(
+ 692,
+ "Sensor (HV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 4L)));
+ ItemList.Sensor_EV.set(
+ addItem(
+ 693,
+ "Sensor (EV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 8L)));
+ ItemList.Sensor_IV.set(
+ addItem(
+ 694,
+ "Sensor (IV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 16L)));
+ ItemList.Sensor_LuV.set(
+ addItem(
+ 695,
+ "Sensor (LuV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 32L)));
+ ItemList.Sensor_ZPM.set(
+ addItem(
+ 696,
+ "Sensor (ZPM)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 64L)));
+ ItemList.Sensor_UV.set(
+ addItem(
+ 697,
+ "Sensor (UV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 128L)));
+ ItemList.Sensor_UHV.set(
+ addItem(
+ 698,
+ "Sensor (UHV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 256L)));
+ ItemList.Sensor_UEV.set(
+ addItem(
+ 699,
+ "Sensor (UEV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
+ ItemList.Sensor_UIV.set(
+ addItem(
+ 41,
+ "Sensor (UIV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
+ ItemList.Sensor_UMV.set(
+ addItem(
+ 42,
+ "Sensor (UMV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
+ ItemList.Sensor_UXV.set(
+ addItem(
+ 43,
+ "Sensor (UXV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
+ ItemList.Sensor_MAX.set(
+ addItem(
+ 44,
+ "Sensor (MAX)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 512L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Sensor_LV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "P Q",
- "PS ",
- "CPP",
- 'Q',
- OrePrefixes.gem.get(Materials.CertusQuartz),
- 'S',
- OrePrefixes.stick.get(Materials.Brass),
- 'P',
- OrePrefixes.plate.get(Materials.Steel),
- 'C',
- OrePrefixes.circuit.get(Materials.Basic)
- });
+ new Object[] { "P Q", "PS ", "CPP", 'Q', OrePrefixes.gem.get(Materials.CertusQuartz), 'S',
+ OrePrefixes.stick.get(Materials.Brass), 'P', OrePrefixes.plate.get(Materials.Steel), 'C',
+ OrePrefixes.circuit.get(Materials.Basic) });
GT_ModHandler.addCraftingRecipe(
ItemList.Sensor_MV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "P Q",
- "PS ",
- "CPP",
- 'Q',
- OrePrefixes.gemFlawless.get(Materials.Emerald),
- 'S',
- OrePrefixes.stick.get(Materials.Electrum),
- 'P',
- OrePrefixes.plate.get(Materials.Aluminium),
- 'C',
- OrePrefixes.circuit.get(Materials.Good)
- });
+ new Object[] { "P Q", "PS ", "CPP", 'Q', OrePrefixes.gemFlawless.get(Materials.Emerald), 'S',
+ OrePrefixes.stick.get(Materials.Electrum), 'P', OrePrefixes.plate.get(Materials.Aluminium), 'C',
+ OrePrefixes.circuit.get(Materials.Good) });
GT_ModHandler.addCraftingRecipe(
ItemList.Sensor_HV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "P Q",
- "PS ",
- "CPP",
- 'Q',
- OrePrefixes.gem.get(Materials.EnderEye),
- 'S',
- OrePrefixes.stick.get(Materials.Chrome),
- 'P',
- OrePrefixes.plate.get(Materials.StainlessSteel),
- 'C',
- OrePrefixes.circuit.get(Materials.Advanced)
- });
+ new Object[] { "P Q", "PS ", "CPP", 'Q', OrePrefixes.gem.get(Materials.EnderEye), 'S',
+ OrePrefixes.stick.get(Materials.Chrome), 'P', OrePrefixes.plate.get(Materials.StainlessSteel),
+ 'C', OrePrefixes.circuit.get(Materials.Advanced) });
GT_ModHandler.addCraftingRecipe(
ItemList.Sensor_EV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "P Q",
- "PS ",
- "CPP",
- 'Q',
- ItemList.QuantumEye,
- 'S',
- OrePrefixes.stick.get(Materials.Platinum),
- 'P',
- OrePrefixes.plate.get(Materials.Titanium),
- 'C',
- OrePrefixes.circuit.get(Materials.Data)
- });
+ new Object[] { "P Q", "PS ", "CPP", 'Q', ItemList.QuantumEye, 'S',
+ OrePrefixes.stick.get(Materials.Platinum), 'P', OrePrefixes.plate.get(Materials.Titanium), 'C',
+ OrePrefixes.circuit.get(Materials.Data) });
GT_ModHandler.addCraftingRecipe(
ItemList.Sensor_IV.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "P Q",
- "PS ",
- "CPP",
- 'Q',
- ItemList.QuantumStar,
- 'S',
- OrePrefixes.stick.get(Materials.Iridium),
- 'P',
- OrePrefixes.plate.get(Materials.TungstenSteel),
- 'C',
- OrePrefixes.circuit.get(Materials.Elite)
- });
-
- ItemList.Field_Generator_LV.set(addItem(
- 670,
- "Field Generator (LV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
- ItemList.Field_Generator_MV.set(addItem(
- 671,
- "Field Generator (MV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 2L)));
- ItemList.Field_Generator_HV.set(addItem(
- 672,
- "Field Generator (HV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 4L)));
- ItemList.Field_Generator_EV.set(addItem(
- 673,
- "Field Generator (EV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 8L)));
- ItemList.Field_Generator_IV.set(addItem(
- 674,
- "Field Generator (IV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 16L)));
- ItemList.Field_Generator_LuV.set(addItem(
- 675,
- "Field Generator (LuV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 32L)));
- ItemList.Field_Generator_ZPM.set(addItem(
- 676,
- "Field Generator (ZPM)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 64L)));
- ItemList.Field_Generator_UV.set(addItem(
- 677,
- "Field Generator (UV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 128L)));
- ItemList.Field_Generator_UHV.set(addItem(
- 678,
- "Field Generator (UHV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 256L)));
- ItemList.Field_Generator_UEV.set(addItem(
- 679,
- "Field Generator (UEV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
- ItemList.Field_Generator_UIV.set(addItem(
- 45,
- "Field Generator (UIV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
- ItemList.Field_Generator_UMV.set(addItem(
- 46,
- "Field Generator (UMV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
- ItemList.Field_Generator_UXV.set(addItem(
- 47,
- "Field Generator (UXV)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
- ItemList.Field_Generator_MAX.set(addItem(
- 48,
- "Field Generator (MAX)",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
-
- ItemList.StableAdhesive.set(addItem(
- 427,
- "Hyper-Stable Self-Healing Adhesive",
- "Complete and selective adhesion, even when torn or damaged",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 30L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 20L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LIMUS, 10L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VINCULUM, 5L)));
- ItemList.SuperconductorComposite.set(addItem(
- 428,
- "Superconductor Rare-Earth Composite",
- "Zero resistance to electrical and quantum flow, regardless of temperature",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 50L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 25L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TERRA, 15L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 10L)));
- ItemList.NaquadriaSupersolid.set(addItem(
- 429,
- "Black Body Naquadria Supersolid",
- "Flows like a fluid and reflects nothing, perfect absorption and transfer",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 100L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 60L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERMUTATIO, 40L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.RADIO, 20L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ALIENIS, 10L)));
+ new Object[] { "P Q", "PS ", "CPP", 'Q', ItemList.QuantumStar, 'S',
+ OrePrefixes.stick.get(Materials.Iridium), 'P', OrePrefixes.plate.get(Materials.TungstenSteel),
+ 'C', OrePrefixes.circuit.get(Materials.Elite) });
+
+ ItemList.Field_Generator_LV.set(
+ addItem(
+ 670,
+ "Field Generator (LV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
+ ItemList.Field_Generator_MV.set(
+ addItem(
+ 671,
+ "Field Generator (MV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 2L)));
+ ItemList.Field_Generator_HV.set(
+ addItem(
+ 672,
+ "Field Generator (HV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 4L)));
+ ItemList.Field_Generator_EV.set(
+ addItem(
+ 673,
+ "Field Generator (EV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 8L)));
+ ItemList.Field_Generator_IV.set(
+ addItem(
+ 674,
+ "Field Generator (IV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 16L)));
+ ItemList.Field_Generator_LuV.set(
+ addItem(
+ 675,
+ "Field Generator (LuV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 32L)));
+ ItemList.Field_Generator_ZPM.set(
+ addItem(
+ 676,
+ "Field Generator (ZPM)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 64L)));
+ ItemList.Field_Generator_UV.set(
+ addItem(
+ 677,
+ "Field Generator (UV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 128L)));
+ ItemList.Field_Generator_UHV.set(
+ addItem(
+ 678,
+ "Field Generator (UHV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 256L)));
+ ItemList.Field_Generator_UEV.set(
+ addItem(
+ 679,
+ "Field Generator (UEV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
+ ItemList.Field_Generator_UIV.set(
+ addItem(
+ 45,
+ "Field Generator (UIV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
+ ItemList.Field_Generator_UMV.set(
+ addItem(
+ 46,
+ "Field Generator (UMV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
+ ItemList.Field_Generator_UXV.set(
+ addItem(
+ 47,
+ "Field Generator (UXV)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
+ ItemList.Field_Generator_MAX.set(
+ addItem(
+ 48,
+ "Field Generator (MAX)",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1024L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 512L)));
+
+ ItemList.StableAdhesive.set(
+ addItem(
+ 427,
+ "Hyper-Stable Self-Healing Adhesive",
+ "Complete and selective adhesion, even when torn or damaged",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 30L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 20L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LIMUS, 10L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VINCULUM, 5L)));
+ ItemList.SuperconductorComposite.set(
+ addItem(
+ 428,
+ "Superconductor Rare-Earth Composite",
+ "Zero resistance to electrical and quantum flow, regardless of temperature",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 50L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 25L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TERRA, 15L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 10L)));
+ ItemList.NaquadriaSupersolid.set(
+ addItem(
+ 429,
+ "Black Body Naquadria Supersolid",
+ "Flows like a fluid and reflects nothing, perfect absorption and transfer",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 100L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 60L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERMUTATIO, 40L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.RADIO, 20L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ALIENIS, 10L)));
// Circuits ULV - LuV.
- ItemList.Circuit_Primitive.set(addItem(
- tLastID = 700,
- "Vacuum Tube",
- "A very simple Circuit",
- OrePrefixes.circuit.get(Materials.Primitive),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Primitive.set(
+ addItem(
+ tLastID = 700,
+ "Vacuum Tube",
+ "A very simple Circuit",
+ OrePrefixes.circuit.get(Materials.Primitive),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("ULV", ItemList.Circuit_Primitive.get(1));
- ItemList.Circuit_Basic.set(addItem(
- tLastID = 701,
- "Integrated Logic Circuit",
- "A Basic Circuit",
- OrePrefixes.circuit.get(Materials.Basic),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Basic.set(
+ addItem(
+ tLastID = 701,
+ "Integrated Logic Circuit",
+ "A Basic Circuit",
+ OrePrefixes.circuit.get(Materials.Basic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("LV", ItemList.Circuit_Basic.get(1));
- ItemList.Circuit_Good.set(addItem(
- tLastID = 702,
- "Good Electronic Circuit",
- "A Good Circuit",
- OrePrefixes.circuit.get(Materials.Good),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Good.set(
+ addItem(
+ tLastID = 702,
+ "Good Electronic Circuit",
+ "A Good Circuit",
+ OrePrefixes.circuit.get(Materials.Good),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("MV", ItemList.Circuit_Good.get(1));
- ItemList.Circuit_Advanced.set(addItem(
- tLastID = 703,
- "Processor Assembly",
- "An Advanced Circuit",
- OrePrefixes.circuit.get(Materials.Advanced),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Advanced.set(
+ addItem(
+ tLastID = 703,
+ "Processor Assembly",
+ "An Advanced Circuit",
+ OrePrefixes.circuit.get(Materials.Advanced),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("HV", ItemList.Circuit_Advanced.get(1));
- ItemList.Circuit_Data.set(addItem(
- tLastID = 704,
- "Workstation",
- "An Extreme Circuit",
- OrePrefixes.circuit.get(Materials.Data),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Data.set(
+ addItem(
+ tLastID = 704,
+ "Workstation",
+ "An Extreme Circuit",
+ OrePrefixes.circuit.get(Materials.Data),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("EV", ItemList.Circuit_Data.get(1));
- ItemList.Circuit_Elite.set(addItem(
- tLastID = 705,
- "Mainframe",
- "An Elite Circuit",
- OrePrefixes.circuit.get(Materials.Elite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Elite.set(
+ addItem(
+ tLastID = 705,
+ "Mainframe",
+ "An Elite Circuit",
+ OrePrefixes.circuit.get(Materials.Elite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("IV", ItemList.Circuit_Elite.get(1));
- ItemList.Circuit_Master.set(addItem(
- tLastID = 706,
- "Nanoprocessor Mainframe",
- "A Master Circuit",
- OrePrefixes.circuit.get(Materials.Master),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Master.set(
+ addItem(
+ tLastID = 706,
+ "Nanoprocessor Mainframe",
+ "A Master Circuit",
+ OrePrefixes.circuit.get(Materials.Master),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("LuV", ItemList.Circuit_Master.get(1));
// Backwards compatibility.
ItemList.Circuit_Parts_Vacuum_Tube.set(ItemList.Circuit_Primitive.get(1));
ItemList.Circuit_Computer.set(ItemList.Circuit_Advanced.get(1));
- ItemList.Tool_DataOrb.set(addItem(
- tLastID = 707,
- "Data Orb",
- "A High Capacity Data Storage",
- SubTag.NO_UNIFICATION,
- new Behaviour_DataOrb()));
+ ItemList.Tool_DataOrb.set(
+ addItem(
+ tLastID = 707,
+ "Data Orb",
+ "A High Capacity Data Storage",
+ SubTag.NO_UNIFICATION,
+ new Behaviour_DataOrb()));
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Tool_DataOrb.get(1L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Tool_DataOrb.get(1L)});
- ItemList.Tool_DataStick.set(addItem(
- tLastID = 708,
- "Data Stick",
- "A Low Capacity Data Storage",
- SubTag.NO_UNIFICATION,
- new Behaviour_DataStick()));
+ new Object[] { ItemList.Tool_DataOrb.get(1L) });
+ ItemList.Tool_DataStick.set(
+ addItem(
+ tLastID = 708,
+ "Data Stick",
+ "A Low Capacity Data Storage",
+ SubTag.NO_UNIFICATION,
+ new Behaviour_DataStick()));
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Tool_DataStick.get(1L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ItemList.Tool_DataStick.get(1L)});
- ItemList.Tool_Cover_Copy_Paste.set(addItem(
- tLastID = 709,
- "Cover Copy/Paste tool",
- "Set Cover Massively.",
- Behaviour_Cover_Tool.INSTANCE,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 6L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 6L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 6L)));
+ new Object[] { ItemList.Tool_DataStick.get(1L) });
+ ItemList.Tool_Cover_Copy_Paste.set(
+ addItem(
+ tLastID = 709,
+ "Cover Copy/Paste tool",
+ "Set Cover Massively.",
+ Behaviour_Cover_Tool.INSTANCE,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 6L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 6L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 6L)));
setElectricStats(32000 + tLastID, 400000L, GT_Values.V[2], 2L, -1L, false);
ItemList.Circuit_Board_Basic.set(addItem(tLastID = 710, "Coated Circuit Board", "A Basic Board"));
ItemList.Circuit_Board_Coated.set(ItemList.Circuit_Board_Basic.get(1));
ItemList.Circuit_Board_Advanced.set(addItem(tLastID = 711, "Epoxy Circuit Board", "An Advanced Board"));
ItemList.Circuit_Board_Epoxy.set(ItemList.Circuit_Board_Advanced.get(1));
- ItemList.Circuit_Board_Elite.set(
- addItem(tLastID = 712, "Multilayer Fiber-Reinforced Circuit Board", "An Elite Board"));
+ ItemList.Circuit_Board_Elite
+ .set(addItem(tLastID = 712, "Multilayer Fiber-Reinforced Circuit Board", "An Elite Board"));
ItemList.Circuit_Board_Multifiberglass.set(ItemList.Circuit_Board_Elite.get(1));
- ItemList.Circuit_Parts_Crystal_Chip_Elite.set(
- addItem(tLastID = 713, "Engraved Crystal Chip", "Needed for Circuits"));
- ItemList.Circuit_Parts_Crystal_Chip_Master.set(
- addItem(tLastID = 714, "Engraved Lapotron Chip", "Needed for Circuits"));
+ ItemList.Circuit_Parts_Crystal_Chip_Elite
+ .set(addItem(tLastID = 713, "Engraved Crystal Chip", "Needed for Circuits"));
+ ItemList.Circuit_Parts_Crystal_Chip_Master
+ .set(addItem(tLastID = 714, "Engraved Lapotron Chip", "Needed for Circuits"));
ItemList.Circuit_Parts_Advanced.set(addItem(tLastID = 715, "Diode", "Basic Electronic Component"));
ItemList.Circuit_Parts_Diode.set(ItemList.Circuit_Parts_Advanced.get(1));
ItemList.Circuit_Parts_Wiring_Basic.set(addItem(tLastID = 716, "Resistor", "Basic Electronic Component"));
@@ -4030,239 +3543,204 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
ItemList.Empty_Board_Elite.set(addItem(tLastID = 720, "Fiber-Reinforced Circuit Board", "An Extreme Board"));
ItemList.Circuit_Board_Fiberglass.set(ItemList.Empty_Board_Elite.get(1));
- ItemList.Component_Sawblade_Diamond.set(addItem(
- tLastID = 721,
- "Diamond Sawblade",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 4L),
- OreDictNames.craftingDiamondBlade));
- ItemList.Component_Grinder_Diamond.set(addItem(
- tLastID = 722,
- "Diamond Grinding Head",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 6L),
- OreDictNames.craftingGrinder));
- ItemList.Component_Grinder_Tungsten.set(addItem(
- tLastID = 723,
- "Tungsten Grinding Head",
- "",
- new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 6L),
- OreDictNames.craftingGrinder));
+ ItemList.Component_Sawblade_Diamond.set(
+ addItem(
+ tLastID = 721,
+ "Diamond Sawblade",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 4L),
+ OreDictNames.craftingDiamondBlade));
+ ItemList.Component_Grinder_Diamond.set(
+ addItem(
+ tLastID = 722,
+ "Diamond Grinding Head",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 6L),
+ OreDictNames.craftingGrinder));
+ ItemList.Component_Grinder_Tungsten.set(
+ addItem(
+ tLastID = 723,
+ "Tungsten Grinding Head",
+ "",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 6L),
+ OreDictNames.craftingGrinder));
GT_ModHandler.addCraftingRecipe(
ItemList.Component_Sawblade_Diamond.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- " D ",
- "DGD",
- " D ",
- 'D',
- OrePrefixes.dustSmall.get(Materials.Diamond),
- 'G',
- OrePrefixes.gearGt.get(Materials.CobaltBrass)
- });
+ new Object[] { " D ", "DGD", " D ", 'D', OrePrefixes.dustSmall.get(Materials.Diamond), 'G',
+ OrePrefixes.gearGt.get(Materials.CobaltBrass) });
GT_ModHandler.addCraftingRecipe(
ItemList.Component_Grinder_Diamond.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "DSD",
- "SIS",
- "DSD",
- 'I',
- OrePrefixes.gem.get(Materials.Diamond),
- 'D',
- OrePrefixes.dust.get(Materials.Diamond),
- 'S',
- OrePrefixes.plateDouble.get(Materials.Steel)
- });
+ new Object[] { "DSD", "SIS", "DSD", 'I', OrePrefixes.gem.get(Materials.Diamond), 'D',
+ OrePrefixes.dust.get(Materials.Diamond), 'S', OrePrefixes.plateDouble.get(Materials.Steel) });
GT_ModHandler.addCraftingRecipe(
ItemList.Component_Grinder_Tungsten.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "TST",
- "SIS",
- "TST",
- 'I',
- OreDictNames.craftingIndustrialDiamond,
- 'T',
- OrePrefixes.plate.get(Materials.Tungsten),
- 'S',
- OrePrefixes.plateDouble.get(Materials.Steel)
- });
-
- ItemList.Upgrade_Muffler.set(addItem(
- tLastID = 727,
- "Muffler Upgrade",
- "Makes Machines silent",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 2L)));
- ItemList.Upgrade_Lock.set(addItem(
- tLastID = 728,
- "Lock Upgrade",
- "Protects your Machines",
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 4L)));
+ new Object[] { "TST", "SIS", "TST", 'I', OreDictNames.craftingIndustrialDiamond, 'T',
+ OrePrefixes.plate.get(Materials.Tungsten), 'S', OrePrefixes.plateDouble.get(Materials.Steel) });
+
+ ItemList.Upgrade_Muffler.set(
+ addItem(
+ tLastID = 727,
+ "Muffler Upgrade",
+ "Makes Machines silent",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 2L)));
+ ItemList.Upgrade_Lock.set(
+ addItem(
+ tLastID = 728,
+ "Lock Upgrade",
+ "Protects your Machines",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 4L)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Plastic, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Plastic, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Muffler.get(1L),
1600,
2);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Muffler.get(1L),
1600,
2);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Plastic, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Plastic, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Muffler.get(1L),
1600,
2);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Muffler.get(1L),
1600,
2);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Plastic, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Plastic, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Muffler.get(1L),
1600,
2);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 2L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wood, 2L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Muffler.get(1L),
1600,
2);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Lock.get(1L),
6400,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Lock.get(1L),
6400,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iridium, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Upgrade_Lock.get(1L),
6400,
16);
- ItemList.Component_Filter.set(addItem(
- tLastID = 729,
- "Item Filter",
- "",
- new ItemData(Materials.Zinc, OrePrefixes.foil.mMaterialAmount * 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L),
- OreDictNames.craftingFilter));
-
- ItemList.Cover_Controller.set(addItem(
- tLastID = 730,
- "Machine Controller Cover",
- "Turns Machines ON/OFF",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
- ItemList.Cover_ActivityDetector.set(addItem(
- tLastID = 731,
- "Activity Detector Cover",
- "Gives out Activity as Redstone",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
- ItemList.Cover_FluidDetector.set(addItem(
- tLastID = 732,
- "Fluid Detector Cover",
- "Gives out Fluid Amount as Redstone",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
- ItemList.Cover_ItemDetector.set(addItem(
- tLastID = 733,
- "Item Detector Cover",
- "Gives out Item Amount as Redstone",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TERRA, 1L)));
- ItemList.Cover_EnergyDetector.set(addItem(
- tLastID = 734,
- "Energy Detector Cover",
- "Gives out Energy Amount as Redstone",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
- ItemList.Cover_PlayerDetector.set(addItem(
- tLastID = 735,
- "Player Detector Cover",
- "Gives out close Players as Redstone",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
- ItemList.Cover_FluidStorageMonitor.set(addItem(
- tLastID = 577,
- "Fluid Storage Monitor Cover",
- "Displays the fluid stored in the Tank",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
+ ItemList.Component_Filter.set(
+ addItem(
+ tLastID = 729,
+ "Item Filter",
+ "",
+ new ItemData(Materials.Zinc, OrePrefixes.foil.mMaterialAmount * 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L),
+ OreDictNames.craftingFilter));
+
+ ItemList.Cover_Controller.set(
+ addItem(
+ tLastID = 730,
+ "Machine Controller Cover",
+ "Turns Machines ON/OFF",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_ActivityDetector.set(
+ addItem(
+ tLastID = 731,
+ "Activity Detector Cover",
+ "Gives out Activity as Redstone",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_FluidDetector.set(
+ addItem(
+ tLastID = 732,
+ "Fluid Detector Cover",
+ "Gives out Fluid Amount as Redstone",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
+ ItemList.Cover_ItemDetector.set(
+ addItem(
+ tLastID = 733,
+ "Item Detector Cover",
+ "Gives out Item Amount as Redstone",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TERRA, 1L)));
+ ItemList.Cover_EnergyDetector.set(
+ addItem(
+ tLastID = 734,
+ "Energy Detector Cover",
+ "Gives out Energy Amount as Redstone",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Cover_PlayerDetector.set(
+ addItem(
+ tLastID = 735,
+ "Player Detector Cover",
+ "Gives out close Players as Redstone",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_FluidStorageMonitor.set(
+ addItem(
+ tLastID = 577,
+ "Fluid Storage Monitor Cover",
+ "Displays the fluid stored in the Tank",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Sensor_EV.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Titanium, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Sensor_EV.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Titanium, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_PlayerDetector.get(1L),
3200,
@@ -4275,10 +3753,7 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
final ITexture doesWorkCoverTexture = TextureFactory.of(
TextureFactory.of(OVERLAY_ACTIVITYDETECTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_ACTIVITYDETECTOR_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(OVERLAY_ACTIVITYDETECTOR_GLOW).glow().build());
GregTech_API.registerCover(
ItemList.Cover_ActivityDetector.get(1L),
TextureFactory.of(MACHINE_CASINGS[2][0], doesWorkCoverTexture),
@@ -4298,10 +3773,7 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
final ITexture playerDectectorCoverTexture = TextureFactory.of(
TextureFactory.of(OVERLAY_ACTIVITYDETECTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_ACTIVITYDETECTOR_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(OVERLAY_ACTIVITYDETECTOR_GLOW).glow().build());
GregTech_API.registerCover(
ItemList.Cover_PlayerDetector.get(1L),
TextureFactory.of(MACHINE_CASINGS[2][0], playerDectectorCoverTexture),
@@ -4311,161 +3783,118 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
TextureFactory.of(OVERLAY_FLUID_STORAGE_MONITOR0),
new GT_Cover_FluidStorageMonitor());
- ItemList.Cover_Screen.set(addItem(
- tLastID = 740,
- "Computer Monitor Cover",
- "Displays Data and GUI",
- new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L)));
- ItemList.Cover_Crafting.set(addItem(
- tLastID = 744,
- "Crafting Table Cover",
- "Better than a wooden Workbench",
- new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 4L)));
- ItemList.Cover_Drain.set(addItem(
- tLastID = 745,
- "Drain Module Cover",
- "Absorbs Fluids and collects Rain",
- new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
-
- ItemList.Cover_Shutter.set(addItem(
- tLastID = 749,
- "Shutter Module Cover",
- "Blocks Inventory/Tank Side. Use together with Machine Controller.",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
+ ItemList.Cover_Screen.set(
+ addItem(
+ tLastID = 740,
+ "Computer Monitor Cover",
+ "Displays Data and GUI",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.COGNITIO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUX, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L)));
+ ItemList.Cover_Crafting.set(
+ addItem(
+ tLastID = 744,
+ "Crafting Table Cover",
+ "Better than a wooden Workbench",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FABRICO, 4L)));
+ ItemList.Cover_Drain.set(
+ addItem(
+ tLastID = 745,
+ "Drain Module Cover",
+ "Absorbs Fluids and collects Rain",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+
+ ItemList.Cover_Shutter.set(
+ addItem(
+ tLastID = 749,
+ "Shutter Module Cover",
+ "Blocks Inventory/Tank Side. Use together with Machine Controller.",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ITER, 1L)));
GT_ModHandler.addCraftingRecipe(
ItemList.Cover_Screen.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "AGA",
- "RPB",
- "ALA",
- 'A',
- OrePrefixes.plate.get(Materials.Aluminium),
- 'L',
- OrePrefixes.dust.get(Materials.Glowstone),
- 'R',
- Dyes.dyeRed,
- 'G',
- Dyes.dyeLime,
- 'B',
- Dyes.dyeBlue,
- 'P',
- OrePrefixes.plate.get(Materials.Glass)
- });
+ new Object[] { "AGA", "RPB", "ALA", 'A', OrePrefixes.plate.get(Materials.Aluminium), 'L',
+ OrePrefixes.dust.get(Materials.Glowstone), 'R', Dyes.dyeRed, 'G', Dyes.dyeLime, 'B',
+ Dyes.dyeBlue, 'P', OrePrefixes.plate.get(Materials.Glass) });
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
- ItemList.Cover_Drain.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
+ ItemList.Cover_Drain.get(1L), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Shutter.get(1L),
200,
64);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
- ItemList.Cover_Drain.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
+ ItemList.Cover_Drain.get(1L), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Shutter.get(1L),
800,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
- ItemList.Cover_Drain.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
+ ItemList.Cover_Drain.get(1L), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Shutter.get(1L),
400,
30);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 2L),
- new ItemStack(Blocks.iron_bars, 2),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 2L),
+ new ItemStack(Blocks.iron_bars, 2), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Drain.get(1L),
200,
64);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 2L),
- new ItemStack(Blocks.iron_bars, 2),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 2L),
+ new ItemStack(Blocks.iron_bars, 2), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Drain.get(1L),
800,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 2L),
- new ItemStack(Blocks.iron_bars, 2),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 2L),
+ new ItemStack(Blocks.iron_bars, 2), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Drain.get(1L),
400,
30);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
- new ItemStack(Blocks.crafting_table, 1),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
+ new ItemStack(Blocks.crafting_table, 1), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Crafting.get(1L),
200,
64);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
- new ItemStack(Blocks.crafting_table, 1),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Iron, 1L),
+ new ItemStack(Blocks.crafting_table, 1), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Crafting.get(1L),
800,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
- new ItemStack(Blocks.crafting_table, 1),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.WroughtIron, 1L),
+ new ItemStack(Blocks.crafting_table, 1), GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_Crafting.get(1L),
800,
16);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_Shutter.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Basic, 1),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_Shutter.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Basic, 1),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.FluidFilter.get(1L),
800,
4);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_Screen.get(1L),
- ItemList.Cover_FluidDetector.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_Screen.get(1L), ItemList.Cover_FluidDetector.get(1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_FluidStorageMonitor.get(1L),
1200,
@@ -4491,91 +3920,115 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
TextureFactory.of(MACHINE_CASINGS[1][0], TextureFactory.of(OVERLAY_SHUTTER)),
new GT_Cover_Shutter(TextureFactory.of(OVERLAY_SHUTTER)));
- ItemList.Cover_SolarPanel.set(addItem(
- tLastID = 750,
- "Solar Panel",
- "May the Sun be with you (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 1L)));
- ItemList.Cover_SolarPanel_8V.set(addItem(
- tLastID = 751,
- "Solar Panel (8V)",
- "8 Volt Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 2L)));
- ItemList.Cover_SolarPanel_LV.set(addItem(
- tLastID = 752,
- "Solar Panel (LV)",
- "Low Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 4L)));
- ItemList.Cover_SolarPanel_MV.set(addItem(
- tLastID = 753,
- "Solar Panel (MV)",
- "Medium Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 8L)));
- ItemList.Cover_SolarPanel_HV.set(addItem(
- tLastID = 754,
- "Solar Panel (HV)",
- "High Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 16L)));
- ItemList.Cover_SolarPanel_EV.set(addItem(
- tLastID = 755,
- "Solar Panel (EV)",
- "Extreme Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 32L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 32L)));
- ItemList.Cover_SolarPanel_IV.set(addItem(
- tLastID = 756,
- "Solar Panel (IV)",
- "Insane Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
- ItemList.Cover_SolarPanel_LuV.set(addItem(
- tLastID = 757,
- "Solar Panel (LuV)",
- "Ludicrous Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
- ItemList.Cover_SolarPanel_ZPM.set(addItem(
- tLastID = 758,
- "Solar Panel (ZPM)",
- "ZPM Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
- ItemList.Cover_SolarPanel_UV.set(addItem(
- tLastID = 759,
- "Solar Panel (UV)",
- "Ultimate Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
+ ItemList.Cover_SolarPanel.set(
+ addItem(
+ tLastID = 750,
+ "Solar Panel",
+ "May the Sun be with you (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 1L)));
+ ItemList.Cover_SolarPanel_8V.set(
+ addItem(
+ tLastID = 751,
+ "Solar Panel (8V)",
+ "8 Volt Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 2L)));
+ ItemList.Cover_SolarPanel_LV.set(
+ addItem(
+ tLastID = 752,
+ "Solar Panel (LV)",
+ "Low Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 4L)));
+ ItemList.Cover_SolarPanel_MV.set(
+ addItem(
+ tLastID = 753,
+ "Solar Panel (MV)",
+ "Medium Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 8L)));
+ ItemList.Cover_SolarPanel_HV.set(
+ addItem(
+ tLastID = 754,
+ "Solar Panel (HV)",
+ "High Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 16L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 16L)));
+ ItemList.Cover_SolarPanel_EV.set(
+ addItem(
+ tLastID = 755,
+ "Solar Panel (EV)",
+ "Extreme Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 32L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 32L)));
+ ItemList.Cover_SolarPanel_IV.set(
+ addItem(
+ tLastID = 756,
+ "Solar Panel (IV)",
+ "Insane Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
+ ItemList.Cover_SolarPanel_LuV.set(
+ addItem(
+ tLastID = 757,
+ "Solar Panel (LuV)",
+ "Ludicrous Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
+ ItemList.Cover_SolarPanel_ZPM.set(
+ addItem(
+ tLastID = 758,
+ "Solar Panel (ZPM)",
+ "ZPM Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
+ ItemList.Cover_SolarPanel_UV.set(
+ addItem(
+ tLastID = 759,
+ "Solar Panel (UV)",
+ "Ultimate Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 64L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 64L)));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel.get(1L), TextureFactory.of(SOLARPANEL), new GT_Cover_SolarPanel(1));
+ ItemList.Cover_SolarPanel.get(1L),
+ TextureFactory.of(SOLARPANEL),
+ new GT_Cover_SolarPanel(1));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel_8V.get(1L), TextureFactory.of(SOLARPANEL_8V), new GT_Cover_SolarPanel(8));
+ ItemList.Cover_SolarPanel_8V.get(1L),
+ TextureFactory.of(SOLARPANEL_8V),
+ new GT_Cover_SolarPanel(8));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel_LV.get(1L), TextureFactory.of(SOLARPANEL_LV), new GT_Cover_SolarPanel(32));
+ ItemList.Cover_SolarPanel_LV.get(1L),
+ TextureFactory.of(SOLARPANEL_LV),
+ new GT_Cover_SolarPanel(32));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel_MV.get(1L), TextureFactory.of(SOLARPANEL_MV), new GT_Cover_SolarPanel(128));
+ ItemList.Cover_SolarPanel_MV.get(1L),
+ TextureFactory.of(SOLARPANEL_MV),
+ new GT_Cover_SolarPanel(128));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel_HV.get(1L), TextureFactory.of(SOLARPANEL_HV), new GT_Cover_SolarPanel(512));
+ ItemList.Cover_SolarPanel_HV.get(1L),
+ TextureFactory.of(SOLARPANEL_HV),
+ new GT_Cover_SolarPanel(512));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel_EV.get(1L), TextureFactory.of(SOLARPANEL_EV), new GT_Cover_SolarPanel(2048));
+ ItemList.Cover_SolarPanel_EV.get(1L),
+ TextureFactory.of(SOLARPANEL_EV),
+ new GT_Cover_SolarPanel(2048));
GregTech_API.registerCover(
- ItemList.Cover_SolarPanel_IV.get(1L), TextureFactory.of(SOLARPANEL_IV), new GT_Cover_SolarPanel(8192));
+ ItemList.Cover_SolarPanel_IV.get(1L),
+ TextureFactory.of(SOLARPANEL_IV),
+ new GT_Cover_SolarPanel(8192));
GregTech_API.registerCover(
ItemList.Cover_SolarPanel_LuV.get(1L),
TextureFactory.of(SOLARPANEL_LuV),
@@ -4589,105 +4042,98 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
TextureFactory.of(SOLARPANEL_UV),
new GT_Cover_SolarPanel(524288));
- ItemList.Tool_Sonictron.set(addItem(
- tLastID = 760,
- "Sonictron",
- "Bring your Music with you",
- Behaviour_Sonictron.INSTANCE,
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 4L)));
- ItemList.Tool_Cheat.set(addItem(
- tLastID = 761,
- "Debug Scanner",
- "Also an Infinite Energy Source",
- Behaviour_Scanner.INSTANCE,
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 64L)));
+ ItemList.Tool_Sonictron.set(
+ addItem(
+ tLastID = 760,
+ "Sonictron",
+ "Bring your Music with you",
+ Behaviour_Sonictron.INSTANCE,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 4L)));
+ ItemList.Tool_Cheat.set(
+ addItem(
+ tLastID = 761,
+ "Debug Scanner",
+ "Also an Infinite Energy Source",
+ Behaviour_Scanner.INSTANCE,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 64L)));
setElectricStats(32000 + tLastID, -2000000000L, 1000000000L, -1L, -3L, false);
- ItemList.Tool_Scanner.set(addItem(
- tLastID = 762,
- "Portable Scanner",
- "Tricorder",
- Behaviour_Scanner.INSTANCE,
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 6L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 6L)));
+ ItemList.Tool_Scanner.set(
+ addItem(
+ tLastID = 762,
+ "Portable Scanner",
+ "Tricorder",
+ Behaviour_Scanner.INSTANCE,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 6L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 6L)));
setElectricStats(32000 + tLastID, 400000L, GT_Values.V[2], 2L, -1L, false);
GT_ModHandler.addCraftingRecipe(
ItemList.Tool_Scanner.get(1L),
- GT_ModHandler.RecipeBits.DISMANTLEABLE
- | GT_ModHandler.RecipeBits.NOT_REMOVABLE
+ GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE
| GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "EPR",
- "CSC",
- "PBP",
- 'C',
- OrePrefixes.circuit.get(Materials.Advanced),
- 'P',
- OrePrefixes.plate.get(Materials.Aluminium),
- 'E',
- ItemList.Emitter_MV,
- 'R',
- ItemList.Sensor_MV,
- 'S',
- ItemList.Cover_Screen,
- 'B',
- ItemList.Battery_RE_MV_Lithium
- });
+ new Object[] { "EPR", "CSC", "PBP", 'C', OrePrefixes.circuit.get(Materials.Advanced), 'P',
+ OrePrefixes.plate.get(Materials.Aluminium), 'E', ItemList.Emitter_MV, 'R', ItemList.Sensor_MV,
+ 'S', ItemList.Cover_Screen, 'B', ItemList.Battery_RE_MV_Lithium });
ItemList.NC_SensorKit.set(addItem(tLastID = 763, "GregTech Sensor Kit", "", new Behaviour_SensorKit()));
- ItemList.Duct_Tape.set(addItem(
- tLastID = 764,
- "BrainTech Aerospace Advanced Reinforced Duct Tape FAL-84",
- "If you can't fix it with this, use more of it!",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
- OreDictNames.craftingDuctTape));
- ItemList.McGuffium_239.set(addItem(
- tLastID = 765,
- "Mc Guffium 239",
- "42% better than Phlebotnium",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ALIENIS, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERMUTATIO, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SPIRITUS, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITIUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.RADIO, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MAGNETO, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 8L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.STRONTIO, 8L)));
+ ItemList.Duct_Tape.set(
+ addItem(
+ tLastID = 764,
+ "BrainTech Aerospace Advanced Reinforced Duct Tape FAL-84",
+ "If you can't fix it with this, use more of it!",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.INSTRUMENTUM, 2L),
+ OreDictNames.craftingDuctTape));
+ ItemList.McGuffium_239.set(
+ addItem(
+ tLastID = 765,
+ "Mc Guffium 239",
+ "42% better than Phlebotnium",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ALIENIS, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERMUTATIO, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SPIRITUS, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITIUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.RADIO, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MAGNETO, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 8L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.STRONTIO, 8L)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Sensor_LV.get(1L), ItemList.Emitter_LV.get(1L), GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Sensor_LV.get(1L), ItemList.Emitter_LV.get(1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.NC_SensorKit.get(1L),
1600,
2);
- ItemList.Cover_RedstoneTransmitterExternal.set(addItem(
- tLastID = 741,
- "Redstone Transmitter (External)",
- "Transfers Redstone signals wireless",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
- ItemList.Cover_RedstoneTransmitterInternal.set(addItem(
- tLastID = 742,
- "Redstone Transmitter (Internal)",
- "Transfers Redstone signals wireless",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
- ItemList.Cover_RedstoneReceiverExternal.set(addItem(
- tLastID = 746,
- "Redstone Receiver (External)",
- "Transfers Redstone signals wireless",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
- ItemList.Cover_RedstoneReceiverInternal.set(addItem(
- tLastID = 747,
- "Redstone Receiver (Internal)",
- "Transfers Redstone signals wireless",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_RedstoneTransmitterExternal.set(
+ addItem(
+ tLastID = 741,
+ "Redstone Transmitter (External)",
+ "Transfers Redstone signals wireless",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_RedstoneTransmitterInternal.set(
+ addItem(
+ tLastID = 742,
+ "Redstone Transmitter (Internal)",
+ "Transfers Redstone signals wireless",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_RedstoneReceiverExternal.set(
+ addItem(
+ tLastID = 746,
+ "Redstone Receiver (External)",
+ "Transfers Redstone signals wireless",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ ItemList.Cover_RedstoneReceiverInternal.set(
+ addItem(
+ tLastID = 747,
+ "Redstone Receiver (Internal)",
+ "Transfers Redstone signals wireless",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
GregTech_API.registerCover(
ItemList.Cover_RedstoneTransmitterExternal.get(1L),
@@ -4707,109 +4153,84 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
new GT_Cover_RedstoneReceiverInternal(TextureFactory.of(OVERLAY_REDSTONE_RECEIVER)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Emitter_EV.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.StainlessSteel, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Emitter_EV.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.StainlessSteel, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_RedstoneTransmitterExternal.get(1L),
3200,
128);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Sensor_EV.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.StainlessSteel, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Sensor_EV.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.StainlessSteel, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_RedstoneReceiverExternal.get(1L),
3200,
128);
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_RedstoneTransmitterInternal.get(1L),
- new Object[] {ItemList.Cover_RedstoneTransmitterExternal.get(1L)});
+ new Object[] { ItemList.Cover_RedstoneTransmitterExternal.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_RedstoneReceiverInternal.get(1L),
- new Object[] {ItemList.Cover_RedstoneReceiverExternal.get(1L)});
+ new Object[] { ItemList.Cover_RedstoneReceiverExternal.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_RedstoneTransmitterExternal.get(1L),
- new Object[] {ItemList.Cover_RedstoneTransmitterInternal.get(1L)});
+ new Object[] { ItemList.Cover_RedstoneTransmitterInternal.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_RedstoneReceiverExternal.get(1L),
- new Object[] {ItemList.Cover_RedstoneReceiverInternal.get(1L)});
-
- ItemList.Cover_NeedsMaintainance.set(addItem(
- tLastID = 748,
- "Needs Maintenance Cover",
- "Attach to Multiblock Controller. Emits Redstone Signal if needs Maintenance",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
+ new Object[] { ItemList.Cover_RedstoneReceiverInternal.get(1L) });
+
+ ItemList.Cover_NeedsMaintainance.set(
+ addItem(
+ tLastID = 748,
+ "Needs Maintenance Cover",
+ "Attach to Multiblock Controller. Emits Redstone Signal if needs Maintenance",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 1L)));
GregTech_API.registerCover(
ItemList.Cover_NeedsMaintainance.get(1L),
TextureFactory.of(MACHINE_CASINGS[2][0], TextureFactory.of(OVERLAY_MAINTENANCE_DETECTOR)),
new GT_Cover_NeedMaintainance(TextureFactory.of(OVERLAY_MAINTENANCE_DETECTOR)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Emitter_MV.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Emitter_MV.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Aluminium, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_NeedsMaintainance.get(1L),
600,
24);
- GT_ModHandler.addCraftingRecipe(ItemList.ItemFilter_Export.get(1L), new Object[] {
- "SPS",
- "dIC",
- "SPS",
- 'P',
- OrePrefixes.plate.get(Materials.Tin),
- 'S',
- OrePrefixes.screw.get(Materials.Iron),
- 'I',
- ItemList.Component_Filter,
- 'C',
- ItemList.Conveyor_Module_LV
- });
- GT_ModHandler.addCraftingRecipe(ItemList.ItemFilter_Import.get(1L), new Object[] {
- "SPS",
- "CId",
- "SPS",
- 'P',
- OrePrefixes.plate.get(Materials.Tin),
- 'S',
- OrePrefixes.screw.get(Materials.Iron),
- 'I',
- ItemList.Component_Filter,
- 'C',
- ItemList.Conveyor_Module_LV
- });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.ItemFilter_Export.get(1L),
+ new Object[] { "SPS", "dIC", "SPS", 'P', OrePrefixes.plate.get(Materials.Tin), 'S',
+ OrePrefixes.screw.get(Materials.Iron), 'I', ItemList.Component_Filter, 'C',
+ ItemList.Conveyor_Module_LV });
+ GT_ModHandler.addCraftingRecipe(
+ ItemList.ItemFilter_Import.get(1L),
+ new Object[] { "SPS", "CId", "SPS", 'P', OrePrefixes.plate.get(Materials.Tin), 'S',
+ OrePrefixes.screw.get(Materials.Iron), 'I', ItemList.Component_Filter, 'C',
+ ItemList.Conveyor_Module_LV });
GT_ModHandler.addShapelessCraftingRecipe(
- ItemList.ItemFilter_Export.get(1L), new Object[] {ItemList.ItemFilter_Import.get(1L)});
+ ItemList.ItemFilter_Export.get(1L),
+ new Object[] { ItemList.ItemFilter_Import.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
- ItemList.ItemFilter_Import.get(1L), new Object[] {ItemList.ItemFilter_Export.get(1L)});
+ ItemList.ItemFilter_Import.get(1L),
+ new Object[] { ItemList.ItemFilter_Export.get(1L) });
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Tin, 2L),
- ItemList.Component_Filter.get(1L),
- ItemList.Conveyor_Module_LV.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Tin, 2L),
+ ItemList.Component_Filter.get(1L), ItemList.Conveyor_Module_LV.get(1L),
+ GT_Utility.getIntegratedCircuit(1) },
null,
ItemList.ItemFilter_Export.get(1L),
100,
30);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Tin, 2L),
- ItemList.Component_Filter.get(1L),
- ItemList.Conveyor_Module_LV.get(1L),
- GT_Utility.getIntegratedCircuit(2)
- },
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Tin, 2L),
+ ItemList.Component_Filter.get(1L), ItemList.Conveyor_Module_LV.get(1L),
+ GT_Utility.getIntegratedCircuit(2) },
null,
ItemList.ItemFilter_Import.get(1L),
100,
@@ -4818,19 +4239,9 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
GT_ModHandler.addCraftingRecipe(
ItemList.Tool_Cover_Copy_Paste.get(1L),
GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {
- "PSP",
- "PCP",
- "PBP",
- 'P',
- OrePrefixes.plate.get(Materials.Aluminium),
- 'S',
- ItemList.Tool_DataStick.get(1L),
- 'C',
- ItemList.Cover_Screen.get(1L),
- 'B',
- ItemList.Battery_RE_MV_Lithium.get(1L)
- });
+ new Object[] { "PSP", "PCP", "PBP", 'P', OrePrefixes.plate.get(Materials.Aluminium), 'S',
+ ItemList.Tool_DataStick.get(1L), 'C', ItemList.Cover_Screen.get(1L), 'B',
+ ItemList.Battery_RE_MV_Lithium.get(1L) });
}
private static final Map<Materials, Materials> cauldronRemap = new HashMap<>();
@@ -4856,8 +4267,9 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
aMaterial = cauldronRemap.getOrDefault(aMaterial, aMaterial);
- aItemEntity.setEntityItemStack(GT_OreDictUnificator.get(
- OrePrefixes.dust, aMaterial, aItemEntity.getEntityItem().stackSize));
+ aItemEntity.setEntityItemStack(
+ GT_OreDictUnificator
+ .get(OrePrefixes.dust, aMaterial, aItemEntity.getEntityItem().stackSize));
aItemEntity.worldObj.setBlockMetadataWithNotify(tX, tY, tZ, tMetaData - 1, 3);
return true;
}
@@ -4865,8 +4277,11 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
Block tBlock = aItemEntity.worldObj.getBlock(tX, tY, tZ);
byte tMetaData = (byte) aItemEntity.worldObj.getBlockMetadata(tX, tY, tZ);
if ((tBlock == Blocks.cauldron) && (tMetaData > 0)) {
- aItemEntity.setEntityItemStack(GT_OreDictUnificator.get(
- OrePrefixes.crushedPurified, aMaterial, aItemEntity.getEntityItem().stackSize));
+ aItemEntity.setEntityItemStack(
+ GT_OreDictUnificator.get(
+ OrePrefixes.crushedPurified,
+ aMaterial,
+ aItemEntity.getEntityItem().stackSize));
aItemEntity.worldObj.setBlockMetadataWithNotify(tX, tY, tZ, tMetaData - 1, 3);
return true;
}
@@ -4904,8 +4319,10 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
if (aPrefix == OrePrefixes.cellPlasma && aMaterial.getPlasma(1L) != null) { // Materials has a plasma fluid
for (GT_Recipe recipe : fusionRecipes) { // Loop through fusion recipes
if (recipe.getFluidOutput(0) != null) { // Make sure fluid output can't be null (not sure if possible)
- if (recipe.getFluidOutput(0).isFluidEqual(aMaterial.getPlasma(1L)))
- return true; // Fusion recipe output matches current plasma cell fluid
+ if (recipe.getFluidOutput(0).isFluidEqual(aMaterial.getPlasma(1L))) return true; // Fusion recipe
+ // output matches
+ // current plasma
+ // cell fluid
}
}
}
@@ -4914,17 +4331,16 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 {
@Override
public boolean doesShowInCreative(OrePrefixes aPrefix, Materials aMaterial, boolean aDoShowAllItems) {
- return (aDoShowAllItems)
- || (((aPrefix != OrePrefixes.gem) || (!aMaterial.mName.startsWith("Infused")))
- && (aPrefix != OrePrefixes.dustTiny)
- && (aPrefix != OrePrefixes.dustSmall)
- && (aPrefix != OrePrefixes.dustImpure)
- && (aPrefix != OrePrefixes.dustPure)
- && (aPrefix != OrePrefixes.crushed)
- && (aPrefix != OrePrefixes.crushedPurified)
- && (aPrefix != OrePrefixes.crushedCentrifuged)
- && (aPrefix != OrePrefixes.ingotHot)
- && !(aPrefix == OrePrefixes.cellPlasma && !isPlasmaCellUsed(aPrefix, aMaterial)));
+ return (aDoShowAllItems) || (((aPrefix != OrePrefixes.gem) || (!aMaterial.mName.startsWith("Infused")))
+ && (aPrefix != OrePrefixes.dustTiny)
+ && (aPrefix != OrePrefixes.dustSmall)
+ && (aPrefix != OrePrefixes.dustImpure)
+ && (aPrefix != OrePrefixes.dustPure)
+ && (aPrefix != OrePrefixes.crushed)
+ && (aPrefix != OrePrefixes.crushedPurified)
+ && (aPrefix != OrePrefixes.crushedCentrifuged)
+ && (aPrefix != OrePrefixes.ingotHot)
+ && !(aPrefix == OrePrefixes.cellPlasma && !isPlasmaCellUsed(aPrefix, aMaterial)));
}
@Override
diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_02.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_02.java
index 1b95f90e36..c52255ce3a 100644
--- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_02.java
+++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_02.java
@@ -2,6 +2,21 @@ package gregtech.common.items;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraft.dispenser.IBlockSource;
+import net.minecraft.enchantment.Enchantment;
+import net.minecraft.enchantment.EnumEnchantmentType;
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.projectile.EntityArrow;
+import net.minecraft.init.Blocks;
+import net.minecraft.init.Items;
+import net.minecraft.item.EnumAction;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.potion.Potion;
+import net.minecraft.world.World;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Dyes;
import gregtech.api.enums.GT_Values;
@@ -26,22 +41,9 @@ import gregtech.common.covers.redstone.GT_Cover_WirelessFluidDetector;
import gregtech.common.covers.redstone.GT_Cover_WirelessItemDetector;
import gregtech.common.covers.redstone.GT_Cover_WirelessMaintenanceDetector;
import gregtech.common.items.behaviors.Behaviour_Arrow;
-import net.minecraft.dispenser.IBlockSource;
-import net.minecraft.enchantment.Enchantment;
-import net.minecraft.enchantment.EnumEnchantmentType;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.projectile.EntityArrow;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.EnumAction;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.potion.Potion;
-import net.minecraft.world.World;
public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
+
public static GT_MetaGenerated_Item_02 INSTANCE;
private static final String aTextCover = "Usable as Cover";
private static final String aTextForestry = "Forestry";
@@ -85,1110 +87,1156 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
int tLastID = 0;
- ItemList.ThermosCan_Dark_Coffee.set(addItem(
- tLastID = 0,
- "Dark Coffee",
- "Coffee, dark, without anything else",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSpeed.id,
- 400,
- 1,
- 70,
- Potion.digSpeed.id,
- 400,
- 1,
- 70),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
- ItemList.ThermosCan_Dark_Cafe_au_lait.set(addItem(
- tLastID = 1,
- "Dark Coffee au lait",
- "Keeping you awake the whole night",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSpeed.id,
- 400,
- 2,
- 90,
- Potion.digSpeed.id,
- 400,
- 2,
- 90),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 3L)));
- ItemList.ThermosCan_Coffee.set(addItem(
- tLastID = 2,
- "Coffee",
- "Just the regular morning Coffee",
- new GT_FoodStat(
- 3,
- 0.4F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSpeed.id,
- 400,
- 0,
- 50,
- Potion.digSpeed.id,
- 400,
- 0,
- 50),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
- ItemList.ThermosCan_Cafe_au_lait.set(addItem(
- tLastID = 3,
- "Cafe au lait",
- "Sweet Coffee",
- new GT_FoodStat(
- 3,
- 0.4F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSpeed.id,
- 400,
- 1,
- 70,
- Potion.digSpeed.id,
- 400,
- 1,
- 70),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
- ItemList.ThermosCan_Lait_au_cafe.set(addItem(
- tLastID = 4,
- "Lait au cafe",
- "You want Coffee to your Sugar?",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 3,
- 0.4F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSpeed.id,
- 400,
- 2,
- 90,
- Potion.digSpeed.id,
- 400,
- 2,
- 90),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 3L)));
- ItemList.ThermosCan_Dark_Chocolate_Milk.set(addItem(
- tLastID = 5,
- "Dark Chocolate Milk",
- "A bit bitter, better add a bit Sugar",
- new GT_FoodStat(
- 3,
- 0.4F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.regeneration.id,
- 50,
- 1,
- 60),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.ThermosCan_Chocolate_Milk.set(addItem(
- tLastID = 6,
- "Chocolate Milk",
- "Sweet Goodness",
- new GT_FoodStat(
- 3,
- 0.4F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.regeneration.id,
- 50,
- 1,
- 90),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 2L)));
- ItemList.ThermosCan_Tea.set(addItem(
- tLastID = 7,
- "Tea",
- "Keep calm and carry on",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSlowdown.id,
- 300,
- 0,
- 50),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
- ItemList.ThermosCan_Sweet_Tea.set(addItem(
- tLastID = 8,
- "Sweet Tea",
- "How about a Tea Party? In Boston?",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
- ItemList.ThermosCan_Ice_Tea.set(addItem(
- tLastID = 9,
- "Ice Tea",
- "Better than this purple Junk Drink from failed Potions",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.ThermosCan_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSlowdown.id,
- 300,
- 0,
- 50),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+ ItemList.ThermosCan_Dark_Coffee.set(
+ addItem(
+ tLastID = 0,
+ "Dark Coffee",
+ "Coffee, dark, without anything else",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSpeed.id,
+ 400,
+ 1,
+ 70,
+ Potion.digSpeed.id,
+ 400,
+ 1,
+ 70),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
+ ItemList.ThermosCan_Dark_Cafe_au_lait.set(
+ addItem(
+ tLastID = 1,
+ "Dark Coffee au lait",
+ "Keeping you awake the whole night",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSpeed.id,
+ 400,
+ 2,
+ 90,
+ Potion.digSpeed.id,
+ 400,
+ 2,
+ 90),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 3L)));
+ ItemList.ThermosCan_Coffee.set(
+ addItem(
+ tLastID = 2,
+ "Coffee",
+ "Just the regular morning Coffee",
+ new GT_FoodStat(
+ 3,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSpeed.id,
+ 400,
+ 0,
+ 50,
+ Potion.digSpeed.id,
+ 400,
+ 0,
+ 50),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 1L)));
+ ItemList.ThermosCan_Cafe_au_lait.set(
+ addItem(
+ tLastID = 3,
+ "Cafe au lait",
+ "Sweet Coffee",
+ new GT_FoodStat(
+ 3,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSpeed.id,
+ 400,
+ 1,
+ 70,
+ Potion.digSpeed.id,
+ 400,
+ 1,
+ 70),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 2L)));
+ ItemList.ThermosCan_Lait_au_cafe.set(
+ addItem(
+ tLastID = 4,
+ "Lait au cafe",
+ "You want Coffee to your Sugar?",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 3,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSpeed.id,
+ 400,
+ 2,
+ 90,
+ Potion.digSpeed.id,
+ 400,
+ 2,
+ 90),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MOTUS, 3L)));
+ ItemList.ThermosCan_Dark_Chocolate_Milk.set(
+ addItem(
+ tLastID = 5,
+ "Dark Chocolate Milk",
+ "A bit bitter, better add a bit Sugar",
+ new GT_FoodStat(
+ 3,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.regeneration.id,
+ 50,
+ 1,
+ 60),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.ThermosCan_Chocolate_Milk.set(
+ addItem(
+ tLastID = 6,
+ "Chocolate Milk",
+ "Sweet Goodness",
+ new GT_FoodStat(
+ 3,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.regeneration.id,
+ 50,
+ 1,
+ 90),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 2L)));
+ ItemList.ThermosCan_Tea.set(
+ addItem(
+ tLastID = 7,
+ "Tea",
+ "Keep calm and carry on",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSlowdown.id,
+ 300,
+ 0,
+ 50),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+ ItemList.ThermosCan_Sweet_Tea.set(
+ addItem(
+ tLastID = 8,
+ "Sweet Tea",
+ "How about a Tea Party? In Boston?",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
+ ItemList.ThermosCan_Ice_Tea.set(
+ addItem(
+ tLastID = 9,
+ "Ice Tea",
+ "Better than this purple Junk Drink from failed Potions",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.ThermosCan_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSlowdown.id,
+ 300,
+ 0,
+ 50),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.GELUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L)));
ItemList.GelledToluene.set(addItem(tLastID = 10, "Gelled Toluene", "Raw Explosive"));
- ItemList.Bottle_Purple_Drink.set(addItem(
- tLastID = 100,
- "Purple Drink",
- "How about Lemonade. Or some Ice Tea? I got Purple Drink!",
- new GT_FoodStat(
- 8,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.moveSlowdown.id,
- 400,
- 1,
- 90),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VINCULUM, 1L)));
- ItemList.Bottle_Grape_Juice.set(addItem(
- tLastID = 101,
- "Grape Juice",
- "This has a cleaning effect on your internals.",
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.hunger.id,
- 400,
- 1,
- 60),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Bottle_Wine.set(addItem(
- tLastID = 102,
- "Wine",
- "Ordinary",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 1,
- 60,
- Potion.heal.id,
- 0,
- 0,
- 60,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Bottle_Vinegar.set(addItem(
- tLastID = 103,
- "Vinegar",
- "Exquisite",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 1,
- 90,
- Potion.heal.id,
- 0,
- 1,
- 90,
- Potion.poison.id,
- 200,
- 2,
- 10,
- Potion.harm.id,
- 0,
- 2,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Bottle_Potato_Juice.set(addItem(
- tLastID = 104,
- "Potato Juice",
- "Ever seen Potato Juice in stores? No? That has a reason.",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 3,
- 0.3F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L)));
- ItemList.Bottle_Vodka.set(addItem(
- tLastID = 105,
- "Vodka",
- "Not to confuse with Water",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 500,
- 0,
- 60,
- Potion.damageBoost.id,
- 500,
- 1,
- 60,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L)));
- ItemList.Bottle_Leninade.set(addItem(
- tLastID = 106,
- "Leninade",
- "Let the Communism flow through you!",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 500,
- 1,
- 90,
- Potion.damageBoost.id,
- 500,
- 2,
- 90,
- Potion.poison.id,
- 200,
- 2,
- 10,
- Potion.harm.id,
- 0,
- 2,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 2L)));
- ItemList.Bottle_Mineral_Water.set(addItem(
- tLastID = 107,
- "Mineral Water",
- "The best Stuff you can drink to stay healthy",
- new GT_FoodStat(
- 1,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.regeneration.id,
- 100,
- 1,
- 10),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Bottle_Salty_Water.set(addItem(
- tLastID = 108,
- "Salty Water",
- "Like Sea Water but less dirty",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 1,
- 0.0F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.hunger.id,
- 400,
- 2,
- 95),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TEMPESTAS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Bottle_Reed_Water.set(addItem(
- tLastID = 109,
- "Reed Water",
- "I guess this tastes better when fermented",
- new GT_FoodStat(
- 1,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
- ItemList.Bottle_Rum.set(addItem(
- tLastID = 110,
- "Rum",
- "A buddle o' rum",
- new GT_FoodStat(
- 4,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 300,
- 0,
- 60,
- Potion.damageBoost.id,
- 300,
- 1,
- 60,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
- ItemList.Bottle_Pirate_Brew.set(addItem(
- tLastID = 111,
- "Pirate Brew",
- "Set the Sails, we are going to Torrentuga!",
- new GT_FoodStat(
- 4,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 300,
- 1,
- 90,
- Potion.damageBoost.id,
- 300,
- 2,
- 90,
- Potion.poison.id,
- 200,
- 2,
- 10,
- Potion.harm.id,
- 0,
- 2,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 2L)));
- ItemList.Bottle_Hops_Juice.set(addItem(
- tLastID = 112,
- "Hops Juice",
- "Every Beer has a start",
- new GT_FoodStat(
- 1,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L)));
- ItemList.Bottle_Dark_Beer.set(addItem(
- tLastID = 113,
- "Dark Beer",
- "Dark Beer, for the real Men",
- new GT_FoodStat(
- 4,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 300,
- 1,
- 60,
- Potion.damageBoost.id,
- 300,
- 1,
- 60,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
- ItemList.Bottle_Dragon_Blood.set(addItem(
- tLastID = 114,
- "Dragon Blood",
- "FUS RO DAH!",
- new GT_FoodStat(
- 4,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 300,
- 2,
- 90,
- Potion.damageBoost.id,
- 300,
- 2,
- 90,
- Potion.poison.id,
- 200,
- 2,
- 10,
- Potion.harm.id,
- 0,
- 2,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
- ItemList.Bottle_Wheaty_Juice.set(addItem(
- tLastID = 115,
- "Wheaty Juice",
- "Is this liquefied Bread or what?",
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L)));
- ItemList.Bottle_Scotch.set(addItem(
- tLastID = 116,
- "Scotch",
- "Technically this is just a Whisky",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 0,
- 60,
- Potion.resistance.id,
- 400,
- 1,
- 60,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
- ItemList.Bottle_Glen_McKenner.set(addItem(
- tLastID = 117,
- "Glen McKenner",
- "Don't hand to easily surprised people, they will shatter it.",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 1,
- 90,
- Potion.resistance.id,
- 400,
- 2,
- 90,
- Potion.poison.id,
- 200,
- 2,
- 10,
- Potion.harm.id,
- 0,
- 2,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 2L)));
- ItemList.Bottle_Wheaty_Hops_Juice.set(addItem(
- tLastID = 118,
- "Wheaty Hops Juice",
- "Also known as 'Duff-Lite'",
- new GT_FoodStat(
- 1,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 2L)));
- ItemList.Bottle_Beer.set(addItem(
- tLastID = 119,
- "Beer",
- "Good old Beer",
- new GT_FoodStat(
- 6,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 0,
- 60,
- Potion.digSpeed.id,
- 400,
- 2,
- 60,
- Potion.poison.id,
- 100,
- 0,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
- ItemList.Bottle_Chilly_Sauce.set(addItem(
- tLastID = 120,
- "Chilly Sauce",
- "Spicy",
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 1000,
- 0,
- 10,
- Potion.fireResistance.id,
- 1000,
- 0,
- 60),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Bottle_Hot_Sauce.set(addItem(
- tLastID = 121,
- "Hot Sauce",
- "Very Spicy, I guess?",
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 2000,
- 0,
- 30,
- Potion.fireResistance.id,
- 2000,
- 0,
- 70),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L)));
- ItemList.Bottle_Diabolo_Sauce.set(addItem(
- tLastID = 122,
- "Diabolo Sauce",
- "As if the Devil made this Sauce",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 3000,
- 1,
- 50,
- Potion.fireResistance.id,
- 3000,
- 0,
- 80),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 3L)));
- ItemList.Bottle_Diablo_Sauce.set(addItem(
- tLastID = 123,
- "Diablo Sauce",
- "Diablo always comes back!",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 4000,
- 1,
- 70,
- Potion.fireResistance.id,
- 4000,
- 0,
- 90),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 4L)));
- ItemList.Bottle_Snitches_Glitch_Sauce.set(addItem(
- tLastID = 124,
- "Old Man Snitches glitched Diablo Sauce",
- "[Missing No]",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 2,
- 0.1F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 9999,
- 2,
- 999,
- Potion.fireResistance.id,
- 9999,
- 9,
- 999),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 3L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 5L)));
- ItemList.Bottle_Apple_Juice.set(addItem(
- tLastID = 125,
- "Apple Juice",
- "Made of the Apples from our best Oak Farms",
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.hunger.id,
- 400,
- 0,
- 20),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
- ItemList.Bottle_Cider.set(addItem(
- tLastID = 126,
- "Cider",
- "If you have nothing better to do with your Apples",
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 0,
- 60,
- Potion.resistance.id,
- 400,
- 1,
- 60,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
- ItemList.Bottle_Golden_Apple_Juice.set(addItem(
- tLastID = 127,
- "Golden Apple Juice",
- "A golden Apple in liquid form",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.hunger.id,
- 400,
- 0,
- 20,
- Potion.field_76444_x.id,
- 2400,
- 0,
- 100,
- Potion.regeneration.id,
- 100,
- 1,
- 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Bottle_Golden_Cider.set(addItem(
- tLastID = 128,
- "Golden Cider",
- "More Resistance, less Regeneration",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.confusion.id,
- 400,
- 0,
- 60,
- Potion.field_76444_x.id,
- 2400,
- 1,
- 95,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
- ItemList.Bottle_Iduns_Apple_Juice.set(addItem(
- tLastID = 129,
- "Idun's Apple Juice",
- "So you got the Idea of using Notch Apples for a drink?",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.regeneration.id,
- 600,
- 4,
- 100,
- Potion.field_76444_x.id,
- 2400,
- 0,
- 100,
- Potion.resistance.id,
- 6000,
- 0,
- 100,
- Potion.fireResistance.id,
- 6000,
- 0,
- 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 9L)));
- ItemList.Bottle_Notches_Brew.set(addItem(
- tLastID = 130,
- "Notches Brew",
- "This is just overpowered",
- SubTag.INVISIBLE,
- new GT_FoodStat(
- 4,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.regeneration.id,
- 700,
- 4,
- 95,
- Potion.field_76444_x.id,
- 3000,
- 1,
- 95,
- Potion.resistance.id,
- 7000,
- 1,
- 95,
- Potion.fireResistance.id,
- 7000,
- 0,
- 95,
- Potion.harm.id,
- 0,
- 2,
- 20),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 9L)));
- ItemList.Bottle_Lemon_Juice.set(addItem(
- tLastID = 131,
- "Lemon Juice",
- "Maybe adding Sugar will make it less sour",
- new GT_FoodStat(
- 2,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.digSpeed.id,
- 1200,
- 0,
- 60),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
- ItemList.Bottle_Limoncello.set(addItem(
- tLastID = 132,
- "Limoncello",
- "An alcoholic Drink which tastes like Lemons",
- new GT_FoodStat(
- 2,
- 0.4F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.digSpeed.id,
- 1200,
- 0,
- 90,
- Potion.poison.id,
- 200,
- 1,
- 5),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
- ItemList.Bottle_Lemonade.set(addItem(
- tLastID = 133,
- "Lemonade",
- "Cold and refreshing Lemonade",
- new GT_FoodStat(
- 4,
- 0.3F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.digSpeed.id,
- 900,
- 1,
- 90),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
- ItemList.Bottle_Alcopops.set(addItem(
- tLastID = 134,
- "Alcopops",
- "Don't let your Children drink this junk!",
- new GT_FoodStat(
- 2,
- 0.2F,
- EnumAction.drink,
- ItemList.Bottle_Empty.get(1L),
- GregTech_API.sDrinksAlwaysDrinkable,
- false,
- false,
- Potion.digSpeed.id,
- 900,
- 1,
- 90,
- Potion.poison.id,
- 300,
- 2,
- 20),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VINCULUM, 1L)));
- ItemList.Bottle_Cave_Johnsons_Grenade_Juice.set(addItem(
- tLastID = 135,
- "Cave Johnson's Grenade Juice",
- "When life gives you Lemons, make Life take them Lemons back!",
- SubTag.INVISIBLE,
- new GT_FoodStat(
+ ItemList.Bottle_Purple_Drink.set(
+ addItem(
+ tLastID = 100,
+ "Purple Drink",
+ "How about Lemonade. Or some Ice Tea? I got Purple Drink!",
+ new GT_FoodStat(
+ 8,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.moveSlowdown.id,
+ 400,
+ 1,
+ 90),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VINCULUM, 1L)));
+ ItemList.Bottle_Grape_Juice.set(
+ addItem(
+ tLastID = 101,
+ "Grape Juice",
+ "This has a cleaning effect on your internals.",
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.hunger.id,
+ 400,
+ 1,
+ 60),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Bottle_Wine.set(
+ addItem(
+ tLastID = 102,
+ "Wine",
+ "Ordinary",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 1,
+ 60,
+ Potion.heal.id,
+ 0,
+ 0,
+ 60,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Bottle_Vinegar.set(
+ addItem(
+ tLastID = 103,
+ "Vinegar",
+ "Exquisite",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 1,
+ 90,
+ Potion.heal.id,
+ 0,
+ 1,
+ 90,
+ Potion.poison.id,
+ 200,
+ 2,
+ 10,
+ Potion.harm.id,
+ 0,
+ 2,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Bottle_Potato_Juice.set(
+ addItem(
+ tLastID = 104,
+ "Potato Juice",
+ "Ever seen Potato Juice in stores? No? That has a reason.",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 3,
+ 0.3F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L)));
+ ItemList.Bottle_Vodka.set(
+ addItem(
+ tLastID = 105,
+ "Vodka",
+ "Not to confuse with Water",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 500,
+ 0,
+ 60,
+ Potion.damageBoost.id,
+ 500,
+ 1,
+ 60,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L)));
+ ItemList.Bottle_Leninade.set(
+ addItem(
+ tLastID = 106,
+ "Leninade",
+ "Let the Communism flow through you!",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 500,
+ 1,
+ 90,
+ Potion.damageBoost.id,
+ 500,
+ 2,
+ 90,
+ Potion.poison.id,
+ 200,
+ 2,
+ 10,
+ Potion.harm.id,
+ 0,
+ 2,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 2L)));
+ ItemList.Bottle_Mineral_Water.set(
+ addItem(
+ tLastID = 107,
+ "Mineral Water",
+ "The best Stuff you can drink to stay healthy",
+ new GT_FoodStat(
+ 1,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.regeneration.id,
+ 100,
+ 1,
+ 10),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Bottle_Salty_Water.set(
+ addItem(
+ tLastID = 108,
+ "Salty Water",
+ "Like Sea Water but less dirty",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 1,
+ 0.0F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.hunger.id,
+ 400,
+ 2,
+ 95),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TEMPESTAS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Bottle_Reed_Water.set(
+ addItem(
+ tLastID = 109,
+ "Reed Water",
+ "I guess this tastes better when fermented",
+ new GT_FoodStat(
+ 1,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Bottle_Rum.set(
+ addItem(
+ tLastID = 110,
+ "Rum",
+ "A buddle o' rum",
+ new GT_FoodStat(
+ 4,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 300,
+ 0,
+ 60,
+ Potion.damageBoost.id,
+ 300,
+ 1,
+ 60,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Bottle_Pirate_Brew.set(
+ addItem(
+ tLastID = 111,
+ "Pirate Brew",
+ "Set the Sails, we are going to Torrentuga!",
+ new GT_FoodStat(
+ 4,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 300,
+ 1,
+ 90,
+ Potion.damageBoost.id,
+ 300,
+ 2,
+ 90,
+ Potion.poison.id,
+ 200,
+ 2,
+ 10,
+ Potion.harm.id,
+ 0,
+ 2,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 2L)));
+ ItemList.Bottle_Hops_Juice.set(
+ addItem(
+ tLastID = 112,
+ "Hops Juice",
+ "Every Beer has a start",
+ new GT_FoodStat(
+ 1,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L)));
+ ItemList.Bottle_Dark_Beer.set(
+ addItem(
+ tLastID = 113,
+ "Dark Beer",
+ "Dark Beer, for the real Men",
+ new GT_FoodStat(
+ 4,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 300,
+ 1,
+ 60,
+ Potion.damageBoost.id,
+ 300,
+ 1,
+ 60,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Bottle_Dragon_Blood.set(
+ addItem(
+ tLastID = 114,
+ "Dragon Blood",
+ "FUS RO DAH!",
+ new GT_FoodStat(
+ 4,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 300,
+ 2,
+ 90,
+ Potion.damageBoost.id,
+ 300,
+ 2,
+ 90,
+ Potion.poison.id,
+ 200,
+ 2,
+ 10,
+ Potion.harm.id,
+ 0,
+ 2,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 2L)));
+ ItemList.Bottle_Wheaty_Juice.set(
+ addItem(
+ tLastID = 115,
+ "Wheaty Juice",
+ "Is this liquefied Bread or what?",
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L)));
+ ItemList.Bottle_Scotch.set(
+ addItem(
+ tLastID = 116,
+ "Scotch",
+ "Technically this is just a Whisky",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 0,
+ 60,
+ Potion.resistance.id,
+ 400,
+ 1,
+ 60,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
+ ItemList.Bottle_Glen_McKenner.set(
+ addItem(
+ tLastID = 117,
+ "Glen McKenner",
+ "Don't hand to easily surprised people, they will shatter it.",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 1,
+ 90,
+ Potion.resistance.id,
+ 400,
+ 2,
+ 90,
+ Potion.poison.id,
+ 200,
+ 2,
+ 10,
+ Potion.harm.id,
+ 0,
+ 2,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 2L)));
+ ItemList.Bottle_Wheaty_Hops_Juice.set(
+ addItem(
+ tLastID = 118,
+ "Wheaty Hops Juice",
+ "Also known as 'Duff-Lite'",
+ new GT_FoodStat(
+ 1,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 2L)));
+ ItemList.Bottle_Beer.set(
+ addItem(
+ tLastID = 119,
+ "Beer",
+ "Good old Beer",
+ new GT_FoodStat(
+ 6,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 0,
+ 60,
+ Potion.digSpeed.id,
+ 400,
+ 2,
+ 60,
+ Potion.poison.id,
+ 100,
+ 0,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
+ ItemList.Bottle_Chilly_Sauce.set(
+ addItem(
+ tLastID = 120,
+ "Chilly Sauce",
+ "Spicy",
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 1000,
+ 0,
+ 10,
+ Potion.fireResistance.id,
+ 1000,
+ 0,
+ 60),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Bottle_Hot_Sauce.set(
+ addItem(
+ tLastID = 121,
+ "Hot Sauce",
+ "Very Spicy, I guess?",
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 2000,
+ 0,
+ 30,
+ Potion.fireResistance.id,
+ 2000,
+ 0,
+ 70),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 2L)));
+ ItemList.Bottle_Diabolo_Sauce.set(
+ addItem(
+ tLastID = 122,
+ "Diabolo Sauce",
+ "As if the Devil made this Sauce",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 3000,
+ 1,
+ 50,
+ Potion.fireResistance.id,
+ 3000,
+ 0,
+ 80),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 3L)));
+ ItemList.Bottle_Diablo_Sauce.set(
+ addItem(
+ tLastID = 123,
+ "Diablo Sauce",
+ "Diablo always comes back!",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 4000,
+ 1,
+ 70,
+ Potion.fireResistance.id,
+ 4000,
+ 0,
+ 90),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 4L)));
+ ItemList.Bottle_Snitches_Glitch_Sauce.set(
+ addItem(
+ tLastID = 124,
+ "Old Man Snitches glitched Diablo Sauce",
+ "[Missing No]",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 2,
+ 0.1F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 9999,
+ 2,
+ 999,
+ Potion.fireResistance.id,
+ 9999,
+ 9,
+ 999),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 3L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 5L)));
+ ItemList.Bottle_Apple_Juice.set(
+ addItem(
+ tLastID = 125,
+ "Apple Juice",
+ "Made of the Apples from our best Oak Farms",
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.hunger.id,
+ 400,
+ 0,
+ 20),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Bottle_Cider.set(
+ addItem(
+ tLastID = 126,
+ "Cider",
+ "If you have nothing better to do with your Apples",
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 0,
+ 60,
+ Potion.resistance.id,
+ 400,
+ 1,
+ 60,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
+ ItemList.Bottle_Golden_Apple_Juice.set(
+ addItem(
+ tLastID = 127,
+ "Golden Apple Juice",
+ "A golden Apple in liquid form",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.hunger.id,
+ 400,
+ 0,
+ 20,
+ Potion.field_76444_x.id,
+ 2400,
+ 0,
+ 100,
+ Potion.regeneration.id,
+ 100,
+ 1,
+ 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Bottle_Golden_Cider.set(
+ addItem(
+ tLastID = 128,
+ "Golden Cider",
+ "More Resistance, less Regeneration",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.confusion.id,
+ 400,
+ 0,
+ 60,
+ Potion.field_76444_x.id,
+ 2400,
+ 1,
+ 95,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L)));
+ ItemList.Bottle_Iduns_Apple_Juice.set(
+ addItem(
+ tLastID = 129,
+ "Idun's Apple Juice",
+ "So you got the Idea of using Notch Apples for a drink?",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.regeneration.id,
+ 600,
+ 4,
+ 100,
+ Potion.field_76444_x.id,
+ 2400,
+ 0,
+ 100,
+ Potion.resistance.id,
+ 6000,
+ 0,
+ 100,
+ Potion.fireResistance.id,
+ 6000,
+ 0,
+ 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 9L)));
+ ItemList.Bottle_Notches_Brew.set(
+ addItem(
+ tLastID = 130,
+ "Notches Brew",
+ "This is just overpowered",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
+ 4,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.regeneration.id,
+ 700,
+ 4,
+ 95,
+ Potion.field_76444_x.id,
+ 3000,
+ 1,
+ 95,
+ Potion.resistance.id,
+ 7000,
+ 1,
+ 95,
+ Potion.fireResistance.id,
+ 7000,
+ 0,
+ 95,
+ Potion.harm.id,
+ 0,
+ 2,
+ 20),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.NEBRISUM, 9L)));
+ ItemList.Bottle_Lemon_Juice.set(
+ addItem(
+ tLastID = 131,
+ "Lemon Juice",
+ "Maybe adding Sugar will make it less sour",
+ new GT_FoodStat(
+ 2,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.digSpeed.id,
+ 1200,
+ 0,
+ 60),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
+ ItemList.Bottle_Limoncello.set(
+ addItem(
+ tLastID = 132,
+ "Limoncello",
+ "An alcoholic Drink which tastes like Lemons",
+ new GT_FoodStat(
+ 2,
+ 0.4F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.digSpeed.id,
+ 1200,
+ 0,
+ 90,
+ Potion.poison.id,
+ 200,
+ 1,
+ 5),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
+ ItemList.Bottle_Lemonade.set(
+ addItem(
+ tLastID = 133,
+ "Lemonade",
+ "Cold and refreshing Lemonade",
+ new GT_FoodStat(
+ 4,
+ 0.3F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.digSpeed.id,
+ 900,
+ 1,
+ 90),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERFODIO, 1L)));
+ ItemList.Bottle_Alcopops.set(
+ addItem(
+ tLastID = 134,
+ "Alcopops",
+ "Don't let your Children drink this junk!",
+ new GT_FoodStat(
+ 2,
+ 0.2F,
+ EnumAction.drink,
+ ItemList.Bottle_Empty.get(1L),
+ GregTech_API.sDrinksAlwaysDrinkable,
+ false,
+ false,
+ Potion.digSpeed.id,
+ 900,
+ 1,
+ 90,
+ Potion.poison.id,
+ 300,
+ 2,
+ 20),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VINCULUM, 1L)));
+ ItemList.Bottle_Cave_Johnsons_Grenade_Juice.set(
+ addItem(
+ tLastID = 135,
+ "Cave Johnson's Grenade Juice",
+ "When life gives you Lemons, make Life take them Lemons back!",
+ SubTag.INVISIBLE,
+ new GT_FoodStat(
0,
0.0F,
EnumAction.drink,
ItemList.Bottle_Empty.get(1L),
GregTech_API.sDrinksAlwaysDrinkable,
false,
- false)
- .setExplosive(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MORTUUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 1L)));
- ItemList.Bottle_Milk.set(addItem(
- tLastID = 136,
- "Milk",
- "Got Milk?",
- OrePrefixes.bottle.get(Materials.Milk),
- new GT_FoodStat(
+ false).setExplosive(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MORTUUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERDITIO, 1L)));
+ ItemList.Bottle_Milk.set(
+ addItem(
+ tLastID = 136,
+ "Milk",
+ "Got Milk?",
+ OrePrefixes.bottle.get(Materials.Milk),
+ new GT_FoodStat(
0,
0.0F,
EnumAction.drink,
ItemList.Bottle_Empty.get(1L),
GregTech_API.sDrinksAlwaysDrinkable,
false,
- false)
- .setMilk(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Bottle_Holy_Water.set(addItem(
- tLastID = 137,
- "Holy Water",
- "May the holy Planks be with you",
- OrePrefixes.bottle.get(Materials.HolyWater),
- new GT_FoodStat(
+ false).setMilk(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Bottle_Holy_Water.set(
+ addItem(
+ tLastID = 137,
+ "Holy Water",
+ "May the holy Planks be with you",
+ OrePrefixes.bottle.get(Materials.HolyWater),
+ new GT_FoodStat(
0,
0.0F,
EnumAction.drink,
@@ -1199,421 +1247,474 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
Potion.poison.id,
100,
1,
- 100)
- .setMilk(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
+ 100).setMilk(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L)));
- ItemList.Food_Potato_On_Stick.set(addItem(
- tLastID = 200,
- "Potato on a Stick",
- "Totally looks like a Crab Claw",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, new ItemStack(Items.stick, 1), false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
- ItemList.Food_Potato_On_Stick_Roasted.set(addItem(
- tLastID = 201,
- "Roasted Potato on a Stick",
- "Still looks like a Crab Claw",
- new GT_FoodStat(6, 0.6F, EnumAction.eat, new ItemStack(Items.stick, 1), false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Raw_Fries.set(addItem(
- tLastID = 202,
- "Potato Strips",
- "It's Potato in Stripe Form",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Food_Potato_On_Stick.set(
+ addItem(
+ tLastID = 200,
+ "Potato on a Stick",
+ "Totally looks like a Crab Claw",
+ new GT_FoodStat(1, 0.3F, EnumAction.eat, new ItemStack(Items.stick, 1), false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Food_Potato_On_Stick_Roasted.set(
+ addItem(
+ tLastID = 201,
+ "Roasted Potato on a Stick",
+ "Still looks like a Crab Claw",
+ new GT_FoodStat(6, 0.6F, EnumAction.eat, new ItemStack(Items.stick, 1), false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Raw_Fries.set(
+ addItem(
+ tLastID = 202,
+ "Potato Strips",
+ "It's Potato in Stripe Form",
+ new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Fries.set(addItem(
- tLastID = 203,
- "Fries",
- "Not to confuse with Fry the Delivery Boy",
- new GT_FoodStat(7, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Fries.set(
+ addItem(
+ tLastID = 203,
+ "Fries",
+ "Not to confuse with Fry the Delivery Boy",
+ new GT_FoodStat(7, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Packaged_Fries.set(addItem(
- tLastID = 204,
- "Fries",
- "Ketchup not included",
- new GT_FoodStat(
- 7,
- 0.5F,
- EnumAction.eat,
- GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Paper, 1L),
- false,
- true,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Raw_PotatoChips.set(addItem(
- tLastID = 205,
- "Potato Chips (Raw)",
- "Just like a Potato",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Food_Packaged_Fries.set(
+ addItem(
+ tLastID = 204,
+ "Fries",
+ "Ketchup not included",
+ new GT_FoodStat(
+ 7,
+ 0.5F,
+ EnumAction.eat,
+ GT_OreDictUnificator.get(OrePrefixes.plate, Materials.Paper, 1L),
+ false,
+ true,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Raw_PotatoChips.set(
+ addItem(
+ tLastID = 205,
+ "Potato Chips (Raw)",
+ "Just like a Potato",
+ new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_PotatoChips.set(addItem(
- tLastID = 206,
- "Potato Chips",
- "Crunchy",
- new GT_FoodStat(7, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_PotatoChips.set(
+ addItem(
+ tLastID = 206,
+ "Potato Chips",
+ "Crunchy",
+ new GT_FoodStat(7, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_ChiliChips.set(addItem(
- tLastID = 207,
- "Chili Chips",
- "Spicy",
- new GT_FoodStat(7, 0.6F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_ChiliChips.set(
+ addItem(
+ tLastID = 207,
+ "Chili Chips",
+ "Spicy",
+ new GT_FoodStat(7, 0.6F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Packaged_PotatoChips.set(addItem(
- tLastID = 208,
- "Bag of Potato Chips",
- "Full of delicious Air",
- new GT_FoodStat(
- 7,
- 0.5F,
- EnumAction.eat,
- GT_OreDictUnificator.get(OrePrefixes.foil, Materials.Aluminium, 1L),
- false,
- true,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Packaged_ChiliChips.set(addItem(
- tLastID = 209,
- "Bag of Chili Chips",
- "Stop making noises Baj!",
- new GT_FoodStat(
- 7,
- 0.6F,
- EnumAction.eat,
- GT_OreDictUnificator.get(OrePrefixes.foil, Materials.Aluminium, 1L),
- false,
- true,
- false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Chum.set(addItem(
- tLastID = 210,
- "Chum",
- "Chum is Fum!",
- new GT_FoodStat(
- 5,
- 0.2F,
- EnumAction.eat,
- null,
- true,
- false,
- true,
- Potion.hunger.id,
- 1000,
- 4,
- 100,
- Potion.confusion.id,
- 300,
- 1,
- 80),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Chum_On_Stick.set(addItem(
- tLastID = 211,
- "Chum on a Stick",
- "Don't forget to try our Chum-balaya",
- new GT_FoodStat(
- 5,
- 0.2F,
- EnumAction.eat,
- new ItemStack(Items.stick, 1),
- true,
- false,
- true,
- Potion.hunger.id,
- 1000,
- 4,
- 100,
- Potion.confusion.id,
- 300,
- 1,
- 80),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Dough_Sugar.set(addItem(
- tLastID = 212,
- "Sugary Dough",
- "Don't eat the Dough before it is baken",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Dough_Chocolate.set(addItem(
- tLastID = 213,
- "Chocolate Dough",
- "I said don't eat the Dough!",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Raw_Cookie.set(addItem(
- tLastID = 214,
- "Cookie shaped Dough",
- "For baking Cookies",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Packaged_PotatoChips.set(
+ addItem(
+ tLastID = 208,
+ "Bag of Potato Chips",
+ "Full of delicious Air",
+ new GT_FoodStat(
+ 7,
+ 0.5F,
+ EnumAction.eat,
+ GT_OreDictUnificator.get(OrePrefixes.foil, Materials.Aluminium, 1L),
+ false,
+ true,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Packaged_ChiliChips.set(
+ addItem(
+ tLastID = 209,
+ "Bag of Chili Chips",
+ "Stop making noises Baj!",
+ new GT_FoodStat(
+ 7,
+ 0.6F,
+ EnumAction.eat,
+ GT_OreDictUnificator.get(OrePrefixes.foil, Materials.Aluminium, 1L),
+ false,
+ true,
+ false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Chum.set(
+ addItem(
+ tLastID = 210,
+ "Chum",
+ "Chum is Fum!",
+ new GT_FoodStat(
+ 5,
+ 0.2F,
+ EnumAction.eat,
+ null,
+ true,
+ false,
+ true,
+ Potion.hunger.id,
+ 1000,
+ 4,
+ 100,
+ Potion.confusion.id,
+ 300,
+ 1,
+ 80),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Chum_On_Stick.set(
+ addItem(
+ tLastID = 211,
+ "Chum on a Stick",
+ "Don't forget to try our Chum-balaya",
+ new GT_FoodStat(
+ 5,
+ 0.2F,
+ EnumAction.eat,
+ new ItemStack(Items.stick, 1),
+ true,
+ false,
+ true,
+ Potion.hunger.id,
+ 1000,
+ 4,
+ 100,
+ Potion.confusion.id,
+ 300,
+ 1,
+ 80),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Dough_Sugar.set(
+ addItem(
+ tLastID = 212,
+ "Sugary Dough",
+ "Don't eat the Dough before it is baken",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Dough_Chocolate.set(
+ addItem(
+ tLastID = 213,
+ "Chocolate Dough",
+ "I said don't eat the Dough!",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Raw_Cookie.set(
+ addItem(
+ tLastID = 214,
+ "Cookie shaped Dough",
+ "For baking Cookies",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Sliced_Buns.set(addItem(
- tLastID = 220,
- "Buns",
- "Pre Sliced",
- new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Burger_Veggie.set(addItem(
- tLastID = 221,
- "Veggieburger",
- "No matter how you call this, this is NOT a Burger!",
- new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Burger_Cheese.set(addItem(
- tLastID = 222,
- "Cheeseburger",
- "Cheesy!",
- new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new ItemData(Materials.Cheese, 907200L)));
- ItemList.Food_Burger_Meat.set(addItem(
- tLastID = 223,
- "Hamburger",
- "The Mc Burger Queen Burger",
- new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Burger_Chum.set(addItem(
- tLastID = 224,
- "Chumburger",
- "Fum is Chum!",
- new GT_FoodStat(
- 5,
- 0.2F,
- EnumAction.eat,
- null,
- true,
- false,
- true,
- Potion.hunger.id,
- 1000,
- 4,
- 100,
- Potion.confusion.id,
- 300,
- 1,
- 80),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sliced_Buns.set(
+ addItem(
+ tLastID = 220,
+ "Buns",
+ "Pre Sliced",
+ new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Burger_Veggie.set(
+ addItem(
+ tLastID = 221,
+ "Veggieburger",
+ "No matter how you call this, this is NOT a Burger!",
+ new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Burger_Cheese.set(
+ addItem(
+ tLastID = 222,
+ "Cheeseburger",
+ "Cheesy!",
+ new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new ItemData(Materials.Cheese, 907200L)));
+ ItemList.Food_Burger_Meat.set(
+ addItem(
+ tLastID = 223,
+ "Hamburger",
+ "The Mc Burger Queen Burger",
+ new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Burger_Chum.set(
+ addItem(
+ tLastID = 224,
+ "Chumburger",
+ "Fum is Chum!",
+ new GT_FoodStat(
+ 5,
+ 0.2F,
+ EnumAction.eat,
+ null,
+ true,
+ false,
+ true,
+ Potion.hunger.id,
+ 1000,
+ 4,
+ 100,
+ Potion.confusion.id,
+ 300,
+ 1,
+ 80),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Sliced_Breads.set(addItem(
- tLastID = 230,
- "Breads",
- "Pre Sliced",
- new GT_FoodStat(5, 0.6F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Sandwich_Veggie.set(addItem(
- tLastID = 231,
- "Veggie Sandwich",
- "Meatless",
- new GT_FoodStat(7, 0.6F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sliced_Breads.set(
+ addItem(
+ tLastID = 230,
+ "Breads",
+ "Pre Sliced",
+ new GT_FoodStat(5, 0.6F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sandwich_Veggie.set(
+ addItem(
+ tLastID = 231,
+ "Veggie Sandwich",
+ "Meatless",
+ new GT_FoodStat(7, 0.6F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 32L);
- ItemList.Food_Sandwich_Cheese.set(addItem(
- tLastID = 232,
- "Cheese Sandwich",
- "Say Cheese!",
- new GT_FoodStat(7, 0.6F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sandwich_Cheese.set(
+ addItem(
+ tLastID = 232,
+ "Cheese Sandwich",
+ "Say Cheese!",
+ new GT_FoodStat(7, 0.6F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 32L);
- ItemList.Food_Sandwich_Bacon.set(addItem(
- tLastID = 233,
- "Bacon Sandwich",
- "The best Sandwich ever!",
- new GT_FoodStat(10, 0.8F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sandwich_Bacon.set(
+ addItem(
+ tLastID = 233,
+ "Bacon Sandwich",
+ "The best Sandwich ever!",
+ new GT_FoodStat(10, 0.8F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 32L);
- ItemList.Food_Sandwich_Steak.set(addItem(
- tLastID = 234,
- "Steak Sandwich",
- "Not a 'Steam Sandwich'",
- new GT_FoodStat(10, 0.8F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sandwich_Steak.set(
+ addItem(
+ tLastID = 234,
+ "Steak Sandwich",
+ "Not a 'Steam Sandwich'",
+ new GT_FoodStat(10, 0.8F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 32L);
- ItemList.Food_Sliced_Baguettes.set(addItem(
- tLastID = 240,
- "Baguettes",
- "Pre Sliced",
- new GT_FoodStat(8, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Large_Sandwich_Veggie.set(addItem(
- tLastID = 241,
- "Large Veggie Sandwich",
- "Just not worth it",
- new GT_FoodStat(15, 0.8F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 3L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sliced_Baguettes.set(
+ addItem(
+ tLastID = 240,
+ "Baguettes",
+ "Pre Sliced",
+ new GT_FoodStat(8, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Large_Sandwich_Veggie.set(
+ addItem(
+ tLastID = 241,
+ "Large Veggie Sandwich",
+ "Just not worth it",
+ new GT_FoodStat(15, 0.8F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 3L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Large_Sandwich_Cheese.set(addItem(
- tLastID = 242,
- "Large Cheese Sandwich",
- "I need another cheesy tooltip for this",
- new GT_FoodStat(15, 0.8F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 3L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Large_Sandwich_Cheese.set(
+ addItem(
+ tLastID = 242,
+ "Large Cheese Sandwich",
+ "I need another cheesy tooltip for this",
+ new GT_FoodStat(15, 0.8F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 3L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Large_Sandwich_Bacon.set(addItem(
- tLastID = 243,
- "Large Bacon Sandwich",
- "For Men! (and manly Women)",
- new GT_FoodStat(20, 1.0F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Large_Sandwich_Bacon.set(
+ addItem(
+ tLastID = 243,
+ "Large Bacon Sandwich",
+ "For Men! (and manly Women)",
+ new GT_FoodStat(20, 1.0F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Large_Sandwich_Steak.set(addItem(
- tLastID = 244,
- "Large Steak Sandwich",
- "Yes, I once accidentially called it 'Steam Sandwich'",
- new GT_FoodStat(20, 1.0F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Large_Sandwich_Steak.set(
+ addItem(
+ tLastID = 244,
+ "Large Steak Sandwich",
+ "Yes, I once accidentially called it 'Steam Sandwich'",
+ new GT_FoodStat(20, 1.0F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
setFluidContainerStats(32000 + tLastID, 0L, 16L);
- ItemList.Food_Raw_Pizza_Veggie.set(addItem(
- tLastID = 250,
- "Raw Veggie Pizza",
- "Into the Oven with it!",
- new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Raw_Pizza_Cheese.set(addItem(
- tLastID = 251,
- "Raw Cheese Pizza",
- "Into the Oven with it!",
- new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Raw_Pizza_Meat.set(addItem(
- tLastID = 252,
- "Raw Mince Meat Pizza",
- "Into the Oven with it!",
- new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Raw_Pizza_Veggie.set(
+ addItem(
+ tLastID = 250,
+ "Raw Veggie Pizza",
+ "Into the Oven with it!",
+ new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Raw_Pizza_Cheese.set(
+ addItem(
+ tLastID = 251,
+ "Raw Cheese Pizza",
+ "Into the Oven with it!",
+ new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Raw_Pizza_Meat.set(
+ addItem(
+ tLastID = 252,
+ "Raw Mince Meat Pizza",
+ "Into the Oven with it!",
+ new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Baked_Pizza_Veggie.set(addItem(
- tLastID = 260,
- "Veggie Pizza",
- "The next they want is Gluten Free Pizzas...",
- new GT_FoodStat(3, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Baked_Pizza_Cheese.set(addItem(
- tLastID = 261,
- "Cheese Pizza",
- "Pizza Magarita",
- new GT_FoodStat(4, 0.4F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Baked_Pizza_Meat.set(addItem(
- tLastID = 262,
- "Mince Meat Pizza",
- "Emo Pizza, it cuts itself!",
- new GT_FoodStat(5, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Baked_Pizza_Veggie.set(
+ addItem(
+ tLastID = 260,
+ "Veggie Pizza",
+ "The next they want is Gluten Free Pizzas...",
+ new GT_FoodStat(3, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Baked_Pizza_Cheese.set(
+ addItem(
+ tLastID = 261,
+ "Cheese Pizza",
+ "Pizza Magarita",
+ new GT_FoodStat(4, 0.4F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Baked_Pizza_Meat.set(
+ addItem(
+ tLastID = 262,
+ "Mince Meat Pizza",
+ "Emo Pizza, it cuts itself!",
+ new GT_FoodStat(5, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.CORPUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Dye_Indigo.set(addItem(
- tLastID = 410,
- "Indigo Dye",
- "Blue Dye",
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L),
- Dyes.dyeBlue));
+ ItemList.Dye_Indigo.set(
+ addItem(
+ tLastID = 410,
+ "Indigo Dye",
+ "Blue Dye",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L),
+ Dyes.dyeBlue));
for (byte i = 0; i < 16; i = (byte) (i + 1)) {
- ItemList.DYE_ONLY_ITEMS[i].set(addItem(
- tLastID = 414 + i,
- Dyes.get(i).mName + " Dye",
- "",
- Dyes.get(i).name(),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L)));
+ ItemList.DYE_ONLY_ITEMS[i].set(
+ addItem(
+ tLastID = 414 + i,
+ Dyes.get(i).mName + " Dye",
+ "",
+ Dyes.get(i).name(),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L)));
}
ItemList.Plank_Oak.set(
addItem(tLastID = 470, "Oak Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Spruce.set(addItem(
- tLastID = 471, "Spruce Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Spruce.set(
+ addItem(
+ tLastID = 471,
+ "Spruce Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Birch.set(
addItem(tLastID = 472, "Birch Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Jungle.set(addItem(
- tLastID = 473, "Jungle Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Jungle.set(
+ addItem(
+ tLastID = 473,
+ "Jungle Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Acacia.set(addItem(
- tLastID = 474, "Acacia Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Acacia.set(
+ addItem(
+ tLastID = 474,
+ "Acacia Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_DarkOak.set(addItem(
- tLastID = 475, "Dark Oak Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_DarkOak.set(
+ addItem(
+ tLastID = 475,
+ "Dark Oak Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Larch.set(
addItem(tLastID = 476, "Larch Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
@@ -1621,23 +1722,39 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
ItemList.Plank_Teak.set(
addItem(tLastID = 477, "Teak Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Acacia_Green.set(addItem(
- tLastID = 478, "Green Acacia Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Acacia_Green.set(
+ addItem(
+ tLastID = 478,
+ "Green Acacia Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Lime.set(
addItem(tLastID = 479, "Lime Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Chestnut.set(addItem(
- tLastID = 480, "Chestnut Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Chestnut.set(
+ addItem(
+ tLastID = 480,
+ "Chestnut Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Wenge.set(
addItem(tLastID = 481, "Wenge Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Baobab.set(addItem(
- tLastID = 482, "Baobab Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Baobab.set(
+ addItem(
+ tLastID = 482,
+ "Baobab Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Sequoia.set(addItem(
- tLastID = 483, "Sequoia Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Sequoia.set(
+ addItem(
+ tLastID = 483,
+ "Sequoia Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Kapok.set(
addItem(tLastID = 484, "Kapok Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
@@ -1645,35 +1762,63 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
ItemList.Plank_Ebony.set(
addItem(tLastID = 485, "Ebony Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Mahagony.set(addItem(
- tLastID = 486, "Mahagony Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Mahagony.set(
+ addItem(
+ tLastID = 486,
+ "Mahagony Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Balsa.set(
addItem(tLastID = 487, "Balsa Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Willow.set(addItem(
- tLastID = 488, "Willow Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Willow.set(
+ addItem(
+ tLastID = 488,
+ "Willow Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Walnut.set(addItem(
- tLastID = 489, "Walnut Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Walnut.set(
+ addItem(
+ tLastID = 489,
+ "Walnut Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Greenheart.set(addItem(
- tLastID = 490, "Greenheart Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Greenheart.set(
+ addItem(
+ tLastID = 490,
+ "Greenheart Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Cherry.set(addItem(
- tLastID = 491, "Cherry Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Cherry.set(
+ addItem(
+ tLastID = 491,
+ "Cherry Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Mahoe.set(
addItem(tLastID = 492, "Mahoe Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Poplar.set(addItem(
- tLastID = 493, "Poplar Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Poplar.set(
+ addItem(
+ tLastID = 493,
+ "Poplar Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Palm.set(
addItem(tLastID = 494, "Palm Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Papaya.set(addItem(
- tLastID = 495, "Papaya Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Papaya.set(
+ addItem(
+ tLastID = 495,
+ "Papaya Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.Plank_Pine.set(
addItem(tLastID = 496, "Pine Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
@@ -1684,8 +1829,12 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
ItemList.Plank_Maple.set(
addItem(tLastID = 498, "Maple Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
- ItemList.Plank_Citrus.set(addItem(
- tLastID = 499, "Citrus Plank", aTextCover, new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Plank_Citrus.set(
+ addItem(
+ tLastID = 499,
+ "Citrus Plank",
+ aTextCover,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 75);
ItemList.SFMixture.set(addItem(tLastID = 270, "Super Fuel Binder", "Raw Material"));
@@ -1694,123 +1843,123 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Oak.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 0)});
+ new Object[] { "s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 0) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Spruce.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 1)});
+ new Object[] { "s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 1) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Birch.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 2)});
+ new Object[] { "s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 2) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Jungle.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 3)});
+ new Object[] { "s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 3) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Acacia.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 4)});
+ new Object[] { "s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 4) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_DarkOak.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 5)});
+ new Object[] { "s ", " P", 'P', new ItemStack(Blocks.wooden_slab, 1, 5) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Larch.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 0)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 0) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Teak.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 1)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 1) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Acacia_Green.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 2)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 2) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Lime.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 3)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 3) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Chestnut.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 4)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 4) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Wenge.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 5)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 5) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Baobab.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 6)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 6) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Sequoia.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 7)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs1", 1L, 7) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Kapok.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 0)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 0) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Ebony.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 1)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 1) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Mahagony.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 2)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 2) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Balsa.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 3)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 3) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Willow.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 4)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 4) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Walnut.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 5)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 5) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Greenheart.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 6)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 6) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Cherry.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 7)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs2", 1L, 7) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Mahoe.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 0)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 0) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Poplar.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 1)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 1) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Palm.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 2)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 2) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Papaya.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 3)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 3) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Pine.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 4)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 4) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Plum.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 5)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 5) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Maple.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 6)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 6) });
GT_ModHandler.addCraftingRecipe(
ItemList.Plank_Citrus.get(2L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE,
- new Object[] {"s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 7)});
+ new Object[] { "s ", " P", 'P', GT_ModHandler.getModItem(aTextForestry, "slabs3", 1L, 7) });
GregTech_API.registerCover(ItemList.Plank_Oak.get(1L), TextureFactory.of(Blocks.planks, 0), null);
GregTech_API.registerCover(ItemList.Plank_Spruce.get(1L), TextureFactory.of(Blocks.planks, 1), null);
@@ -1821,274 +1970,408 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
GregTech_API.registerCover(
ItemList.Plank_Larch.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 0, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 0,
+ new ItemStack(Blocks.planks, 1, 0))),
0),
null);
GregTech_API.registerCover(
ItemList.Plank_Teak.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 1, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 1,
+ new ItemStack(Blocks.planks, 1, 0))),
1),
null);
GregTech_API.registerCover(
ItemList.Plank_Acacia_Green.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 2, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 2,
+ new ItemStack(Blocks.planks, 1, 0))),
2),
null);
GregTech_API.registerCover(
ItemList.Plank_Lime.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 3, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 3,
+ new ItemStack(Blocks.planks, 1, 0))),
3),
null);
GregTech_API.registerCover(
ItemList.Plank_Chestnut.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 4, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 4,
+ new ItemStack(Blocks.planks, 1, 0))),
4),
null);
GregTech_API.registerCover(
ItemList.Plank_Wenge.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 5, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 5,
+ new ItemStack(Blocks.planks, 1, 0))),
5),
null);
GregTech_API.registerCover(
ItemList.Plank_Baobab.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 6, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 6,
+ new ItemStack(Blocks.planks, 1, 0))),
6),
null);
GregTech_API.registerCover(
ItemList.Plank_Sequoia.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 7, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 7,
+ new ItemStack(Blocks.planks, 1, 0))),
7),
null);
GregTech_API.registerCover(
ItemList.Plank_Kapok.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 8, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 8,
+ new ItemStack(Blocks.planks, 1, 0))),
8),
null);
GregTech_API.registerCover(
ItemList.Plank_Ebony.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 9, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 9,
+ new ItemStack(Blocks.planks, 1, 0))),
9),
null);
GregTech_API.registerCover(
ItemList.Plank_Mahagony.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 10, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 10,
+ new ItemStack(Blocks.planks, 1, 0))),
10),
null);
GregTech_API.registerCover(
ItemList.Plank_Balsa.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 11, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 11,
+ new ItemStack(Blocks.planks, 1, 0))),
11),
null);
GregTech_API.registerCover(
ItemList.Plank_Willow.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 12, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 12,
+ new ItemStack(Blocks.planks, 1, 0))),
12),
null);
GregTech_API.registerCover(
ItemList.Plank_Walnut.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 13, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 13,
+ new ItemStack(Blocks.planks, 1, 0))),
13),
null);
GregTech_API.registerCover(
ItemList.Plank_Greenheart.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 14, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 14,
+ new ItemStack(Blocks.planks, 1, 0))),
14),
null);
GregTech_API.registerCover(
ItemList.Plank_Cherry.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 15, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 15,
+ new ItemStack(Blocks.planks, 1, 0))),
15),
null);
GregTech_API.registerCover(
ItemList.Plank_Mahoe.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 16, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 16,
+ new ItemStack(Blocks.planks, 1, 0))),
0),
null);
GregTech_API.registerCover(
ItemList.Plank_Poplar.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 17, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 17,
+ new ItemStack(Blocks.planks, 1, 0))),
1),
null);
GregTech_API.registerCover(
ItemList.Plank_Palm.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 18, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 18,
+ new ItemStack(Blocks.planks, 1, 0))),
2),
null);
GregTech_API.registerCover(
ItemList.Plank_Papaya.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 19, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 19,
+ new ItemStack(Blocks.planks, 1, 0))),
3),
null);
GregTech_API.registerCover(
ItemList.Plank_Pine.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 20, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 20,
+ new ItemStack(Blocks.planks, 1, 0))),
4),
null);
GregTech_API.registerCover(
ItemList.Plank_Plum.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 21, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 21,
+ new ItemStack(Blocks.planks, 1, 0))),
5),
null);
GregTech_API.registerCover(
ItemList.Plank_Maple.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 22, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 22,
+ new ItemStack(Blocks.planks, 1, 0))),
6),
null);
GregTech_API.registerCover(
ItemList.Plank_Citrus.get(1L),
TextureFactory.of(
- GT_Utility.getBlockFromStack(GT_ModHandler.getModItem(
- aTextForestry, "planks", 1L, 23, new ItemStack(Blocks.planks, 1, 0))),
+ GT_Utility.getBlockFromStack(
+ GT_ModHandler.getModItem(
+ aTextForestry,
+ "planks",
+ 1L,
+ 23,
+ new ItemStack(Blocks.planks, 1, 0))),
7),
null);
- ItemList.Crop_Drop_Plumbilia.set(addItem(
- tLastID = 500,
- "Plumbilia Leaf",
- "Source of Lead",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 1L)));
- ItemList.Crop_Drop_Argentia.set(addItem(
- tLastID = 501,
- "Argentia Leaf",
- "Source of Silver",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
- ItemList.Crop_Drop_Indigo.set(addItem(
- tLastID = 502,
- "Indigo Blossom",
- "Used for making Blue Dye",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L)));
- ItemList.Crop_Drop_Ferru.set(addItem(
- tLastID = 503,
- "Ferru Leaf",
- "Source of Iron",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L)));
- ItemList.Crop_Drop_Aurelia.set(addItem(
- tLastID = 504,
- "Aurelia Leaf",
- "Source of Gold",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
- ItemList.Crop_Drop_TeaLeaf.set(addItem(
- tLastID = 505,
- "Tea Leaf",
- "Source of Tea",
- "cropTea",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Crop_Drop_Plumbilia.set(
+ addItem(
+ tLastID = 500,
+ "Plumbilia Leaf",
+ "Source of Lead",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 1L)));
+ ItemList.Crop_Drop_Argentia.set(
+ addItem(
+ tLastID = 501,
+ "Argentia Leaf",
+ "Source of Silver",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Crop_Drop_Indigo.set(
+ addItem(
+ tLastID = 502,
+ "Indigo Blossom",
+ "Used for making Blue Dye",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 1L)));
+ ItemList.Crop_Drop_Ferru.set(
+ addItem(
+ tLastID = 503,
+ "Ferru Leaf",
+ "Source of Iron",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 2L)));
+ ItemList.Crop_Drop_Aurelia.set(
+ addItem(
+ tLastID = 504,
+ "Aurelia Leaf",
+ "Source of Gold",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Crop_Drop_TeaLeaf.set(
+ addItem(
+ tLastID = 505,
+ "Tea Leaf",
+ "Source of Tea",
+ "cropTea",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Crop_Drop_OilBerry.set(addItem(
- tLastID = 510,
- "Oil Berry",
- "Oil in Berry form",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
- ItemList.Crop_Drop_BobsYerUncleRanks.set(addItem(
- tLastID = 511,
- "Bobs-Yer-Uncle-Berry",
- "Source of Emeralds",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
- ItemList.Crop_Drop_UUMBerry.set(addItem(
- tLastID = 512,
- "UUM Berry",
- "UUM in Berry form",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
- ItemList.Crop_Drop_UUABerry.set(addItem(
- tLastID = 513,
- "UUA Berry",
- "UUA in Berry form",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Crop_Drop_OilBerry.set(
+ addItem(
+ tLastID = 510,
+ "Oil Berry",
+ "Oil in Berry form",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Crop_Drop_BobsYerUncleRanks.set(
+ addItem(
+ tLastID = 511,
+ "Bobs-Yer-Uncle-Berry",
+ "Source of Emeralds",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.VITREUS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Crop_Drop_UUMBerry.set(
+ addItem(
+ tLastID = 512,
+ "UUM Berry",
+ "UUM in Berry form",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Crop_Drop_UUABerry.set(
+ addItem(
+ tLastID = 513,
+ "UUA Berry",
+ "UUA in Berry form",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
- ItemList.Crop_Drop_MilkWart.set(addItem(
- tLastID = 520,
- "Milk Wart",
- "Source of Milk",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
+ ItemList.Crop_Drop_MilkWart.set(
+ addItem(
+ tLastID = 520,
+ "Milk Wart",
+ "Source of Milk",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 1L)));
- ItemList.Crop_Drop_Coppon.set(addItem(
- tLastID = 530,
- "Coppon Fiber",
- "ORANGE WOOOOOOOL!!!",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.PERMUTATIO, 1L)));
+ ItemList.Crop_Drop_Coppon.set(
+ addItem(
+ tLastID = 530,
+ "Coppon Fiber",
+ "ORANGE WOOOOOOOL!!!",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.PERMUTATIO, 1L)));
- ItemList.Crop_Drop_Tine.set(addItem(
- tLastID = 540,
- "Tine Twig",
- "Source of Tin",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Crop_Drop_Tine.set(
+ addItem(
+ tLastID = 540,
+ "Tine Twig",
+ "Source of Tin",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.METALLUM, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 100);
- ItemList.Crop_Drop_Mica.set(addItem(
- tLastID = 538,
- "Micadia Twig",
- "Source of Mica",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
+ ItemList.Crop_Drop_Mica.set(
+ addItem(
+ tLastID = 538,
+ "Micadia Twig",
+ "Source of Mica",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TUTAMEN, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ARBOR, 1L)));
setBurnValue(32000 + tLastID, 240);
ItemList.Crop_Drop_Bauxite.set(addItem(tLastID = 521, "Bauxia Leaf", "Source of Aluminium"));
@@ -2105,255 +2388,309 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
ItemList.Crop_Drop_Osmium.set(addItem(tLastID = 534, "Quantaria Leaf", "Source of Osmium"));
ItemList.Crop_Drop_Naquadah.set(addItem(tLastID = 535, "Stargatium Leaf", "Source of Naquadah"));
- ItemList.Crop_Drop_Chilly.set(addItem(
- tLastID = 550,
- "Chilly Pepper",
- "It is red and hot",
- "cropChilipepper",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false, Potion.confusion.id, 200, 1, 40),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_Lemon.set(addItem(
- tLastID = 551,
- "Lemon",
- "Don't make Lemonade",
- "cropLemon",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_Tomato.set(addItem(
- tLastID = 552,
- "Tomato",
- "Solid Ketchup",
- "cropTomato",
- new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_MTomato.set(addItem(
- tLastID = 553,
- "Max Tomato",
- "Full Health in one Tomato",
- "cropTomato",
- new GT_FoodStat(
- 9, 1.0F, EnumAction.eat, null, false, true, false, Potion.regeneration.id, 100, 100, 100),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 3L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_Grapes.set(addItem(
- tLastID = 554,
- "Grapes",
- "Source of Wine",
- "cropGrape",
- new GT_FoodStat(2, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_Onion.set(addItem(
- tLastID = 555,
- "Onion",
- "Taking over the whole Taste",
- "cropOnion",
- new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_Cucumber.set(addItem(
- tLastID = 556,
- "Cucumber",
- "Not a Sea Cucumber!",
- "cropCucumber",
- new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Crop_Drop_Rape.set(addItem(
- tLastID = 557,
- "Rape",
- "Time to oil up!",
- new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
+ ItemList.Crop_Drop_Chilly.set(
+ addItem(
+ tLastID = 550,
+ "Chilly Pepper",
+ "It is red and hot",
+ "cropChilipepper",
+ new GT_FoodStat(
+ 1,
+ 0.3F,
+ EnumAction.eat,
+ null,
+ false,
+ true,
+ false,
+ Potion.confusion.id,
+ 200,
+ 1,
+ 40),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_Lemon.set(
+ addItem(
+ tLastID = 551,
+ "Lemon",
+ "Don't make Lemonade",
+ "cropLemon",
+ new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_Tomato.set(
+ addItem(
+ tLastID = 552,
+ "Tomato",
+ "Solid Ketchup",
+ "cropTomato",
+ new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_MTomato.set(
+ addItem(
+ tLastID = 553,
+ "Max Tomato",
+ "Full Health in one Tomato",
+ "cropTomato",
+ new GT_FoodStat(
+ 9,
+ 1.0F,
+ EnumAction.eat,
+ null,
+ false,
+ true,
+ false,
+ Potion.regeneration.id,
+ 100,
+ 100,
+ 100),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SANO, 3L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_Grapes.set(
+ addItem(
+ tLastID = 554,
+ "Grapes",
+ "Source of Wine",
+ "cropGrape",
+ new GT_FoodStat(2, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_Onion.set(
+ addItem(
+ tLastID = 555,
+ "Onion",
+ "Taking over the whole Taste",
+ "cropOnion",
+ new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_Cucumber.set(
+ addItem(
+ tLastID = 556,
+ "Cucumber",
+ "Not a Sea Cucumber!",
+ "cropCucumber",
+ new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Crop_Drop_Rape.set(
+ addItem(
+ tLastID = 557,
+ "Rape",
+ "Time to oil up!",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MESSIS, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 1L)));
- ItemList.Food_Cheese.set(addItem(
- tLastID = 558,
- "Cheese",
- "Click the Cheese",
- "foodCheese",
- new GT_FoodStat(3, 0.6F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L)));
- ItemList.Food_Dough.set(addItem(
- tLastID = 559,
- "Dough",
- "For making Breads",
- "foodDough",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Flat_Dough.set(addItem(
- tLastID = 560,
- "Flattened Dough",
- "For making Pizza",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Raw_Bread.set(addItem(
- tLastID = 561,
- "Dough",
- "In Bread Shape",
- new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Raw_Bun.set(addItem(
- tLastID = 562,
- "Dough",
- "In Bun Shape",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Raw_Baguette.set(addItem(
- tLastID = 563,
- "Dough",
- "In Baguette Shape",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Baked_Bun.set(addItem(
- tLastID = 564,
- "Bun",
- "Do not teleport Bread!",
- new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Baked_Baguette.set(addItem(
- tLastID = 565,
- "Baguette",
- "I teleported nothing BUT Bread!!!",
- new GT_FoodStat(8, 0.5F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Sliced_Bread.set(addItem(
- tLastID = 566,
- "Sliced Bread",
- "Just half a Bread",
- new GT_FoodStat(2, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Sliced_Bun.set(addItem(
- tLastID = 567,
- "Sliced Bun",
- "Just half a Bun",
- new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Sliced_Baguette.set(addItem(
- tLastID = 568,
- "Sliced Baguette",
- "Just half a Baguette",
- new GT_FoodStat(4, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
- ItemList.Food_Raw_Cake.set(addItem(
- tLastID = 569,
- "Cake Bottom",
- "For making Cake",
- new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Baked_Cake.set(addItem(
- tLastID = 570,
- "Baked Cake Bottom",
- "I know I promised you an actual Cake, but well...",
- new GT_FoodStat(3, 0.3F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Food_Sliced_Lemon.set(addItem(
- tLastID = 571,
- "Lemon Slice",
- "Ideal to put on your Drink",
- new GT_FoodStat(1, 0.075F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
- ItemList.Food_Sliced_Tomato.set(addItem(
- tLastID = 572,
- "Tomato Slice",
- "Solid Ketchup",
- new GT_FoodStat(1, 0.05F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
- ItemList.Food_Sliced_Onion.set(addItem(
- tLastID = 573,
- "Onion Slice",
- "ONIONS, UNITE!",
- new GT_FoodStat(1, 0.05F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
- ItemList.Food_Sliced_Cucumber.set(addItem(
- tLastID = 574,
- "Cucumber Slice",
- "QUEWWW-CUMMM-BERRR!!!",
- new GT_FoodStat(1, 0.05F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Food_Cheese.set(
+ addItem(
+ tLastID = 558,
+ "Cheese",
+ "Click the Cheese",
+ "foodCheese",
+ new GT_FoodStat(3, 0.6F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 2L)));
+ ItemList.Food_Dough.set(
+ addItem(
+ tLastID = 559,
+ "Dough",
+ "For making Breads",
+ "foodDough",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Flat_Dough.set(
+ addItem(
+ tLastID = 560,
+ "Flattened Dough",
+ "For making Pizza",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Raw_Bread.set(
+ addItem(
+ tLastID = 561,
+ "Dough",
+ "In Bread Shape",
+ new GT_FoodStat(1, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Raw_Bun.set(
+ addItem(
+ tLastID = 562,
+ "Dough",
+ "In Bun Shape",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Raw_Baguette.set(
+ addItem(
+ tLastID = 563,
+ "Dough",
+ "In Baguette Shape",
+ new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Baked_Bun.set(
+ addItem(
+ tLastID = 564,
+ "Bun",
+ "Do not teleport Bread!",
+ new GT_FoodStat(3, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Baked_Baguette.set(
+ addItem(
+ tLastID = 565,
+ "Baguette",
+ "I teleported nothing BUT Bread!!!",
+ new GT_FoodStat(8, 0.5F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sliced_Bread.set(
+ addItem(
+ tLastID = 566,
+ "Sliced Bread",
+ "Just half a Bread",
+ new GT_FoodStat(2, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sliced_Bun.set(
+ addItem(
+ tLastID = 567,
+ "Sliced Bun",
+ "Just half a Bun",
+ new GT_FoodStat(1, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Sliced_Baguette.set(
+ addItem(
+ tLastID = 568,
+ "Sliced Baguette",
+ "Just half a Baguette",
+ new GT_FoodStat(4, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.IGNIS, 1L)));
+ ItemList.Food_Raw_Cake.set(
+ addItem(
+ tLastID = 569,
+ "Cake Bottom",
+ "For making Cake",
+ new GT_FoodStat(2, 0.2F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Baked_Cake.set(
+ addItem(
+ tLastID = 570,
+ "Baked Cake Bottom",
+ "I know I promised you an actual Cake, but well...",
+ new GT_FoodStat(3, 0.3F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Sliced_Lemon.set(
+ addItem(
+ tLastID = 571,
+ "Lemon Slice",
+ "Ideal to put on your Drink",
+ new GT_FoodStat(1, 0.075F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Food_Sliced_Tomato.set(
+ addItem(
+ tLastID = 572,
+ "Tomato Slice",
+ "Solid Ketchup",
+ new GT_FoodStat(1, 0.05F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Food_Sliced_Onion.set(
+ addItem(
+ tLastID = 573,
+ "Onion Slice",
+ "ONIONS, UNITE!",
+ new GT_FoodStat(1, 0.05F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
+ ItemList.Food_Sliced_Cucumber.set(
+ addItem(
+ tLastID = 574,
+ "Cucumber Slice",
+ "QUEWWW-CUMMM-BERRR!!!",
+ new GT_FoodStat(1, 0.05F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.HERBA, 1L)));
- ItemList.Food_Sliced_Cheese.set(addItem(
- tLastID = 576,
- "Cheese Slice",
- "ALIEN ATTACK!!!, throw the CHEEEEESE!!!",
- new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
- new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
+ ItemList.Food_Sliced_Cheese.set(
+ addItem(
+ tLastID = 576,
+ "Cheese Slice",
+ "ALIEN ATTACK!!!, throw the CHEEEEESE!!!",
+ new GT_FoodStat(1, 0.1F, EnumAction.eat, null, false, true, false),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.FAMES, 1L)));
- ItemList.Cover_AdvancedRedstoneTransmitterExternal.set(addItem(
- tLastID = 577,
- "Advanced Redstone Transmitter (External)",
- "Transfers Redstone signals wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
- ItemList.Cover_AdvancedRedstoneTransmitterInternal.set(addItem(
- tLastID = 578,
- "Advanced Redstone Transmitter (Internal)",
- "Transfers Redstone signals wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
- ItemList.Cover_AdvancedRedstoneReceiverExternal.set(addItem(
- tLastID = 579,
- "Advanced Redstone Receiver (External)",
- "Transfers Redstone signals wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
- ItemList.Cover_AdvancedRedstoneReceiverInternal.set(addItem(
- tLastID = 580,
- "Advanced Redstone Receiver (Internal)",
- "Transfers Redstone signals wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
+ ItemList.Cover_AdvancedRedstoneTransmitterExternal.set(
+ addItem(
+ tLastID = 577,
+ "Advanced Redstone Transmitter (External)",
+ "Transfers Redstone signals wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
+ ItemList.Cover_AdvancedRedstoneTransmitterInternal.set(
+ addItem(
+ tLastID = 578,
+ "Advanced Redstone Transmitter (Internal)",
+ "Transfers Redstone signals wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
+ ItemList.Cover_AdvancedRedstoneReceiverExternal.set(
+ addItem(
+ tLastID = 579,
+ "Advanced Redstone Receiver (External)",
+ "Transfers Redstone signals wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
+ ItemList.Cover_AdvancedRedstoneReceiverInternal.set(
+ addItem(
+ tLastID = 580,
+ "Advanced Redstone Receiver (Internal)",
+ "Transfers Redstone signals wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L)));
- ItemList.Cover_WirelessFluidDetector.set(addItem(
- tLastID = 581,
- "Wireless Fluid Detector Cover",
- "Transfers Fluid Amount as Redstone wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
- ItemList.Cover_WirelessItemDetector.set(addItem(
- tLastID = 582,
- "Wireless Item Detector Cover",
- "Transfers Item Amount as Redstone wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TERRA, 1L)));
+ ItemList.Cover_WirelessFluidDetector.set(
+ addItem(
+ tLastID = 581,
+ "Wireless Fluid Detector Cover",
+ "Transfers Fluid Amount as Redstone wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.AQUA, 1L)));
+ ItemList.Cover_WirelessItemDetector.set(
+ addItem(
+ tLastID = 582,
+ "Wireless Item Detector Cover",
+ "Transfers Item Amount as Redstone wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.SENSUS, 2L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TERRA, 1L)));
- ItemList.Cover_WirelessNeedsMaintainance.set(addItem(
- tLastID = 583,
- "Wireless Needs Maintenance Cover",
- "Transfers Maintenance Issues as Redstone wirelessly",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 4L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 3L)));
+ ItemList.Cover_WirelessNeedsMaintainance.set(
+ addItem(
+ tLastID = 583,
+ "Wireless Needs Maintenance Cover",
+ "Transfers Maintenance Issues as Redstone wirelessly",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ORDO, 4L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.MACHINA, 3L)));
GregTech_API.registerCover(
ItemList.Cover_AdvancedRedstoneTransmitterExternal.get(1L),
@@ -2393,53 +2730,42 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
new GT_Cover_WirelessMaintenanceDetector(TextureFactory.of(OVERLAY_WIRELESS_MAINTENANCE_DETECTOR)));
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_RedstoneTransmitterExternal.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Data, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_RedstoneTransmitterExternal.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Data, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_AdvancedRedstoneTransmitterExternal.get(1L),
3200,
128);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_RedstoneReceiverExternal.get(1L),
- GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Data, 1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_RedstoneReceiverExternal.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.circuit, Materials.Data, 1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_AdvancedRedstoneReceiverExternal.get(1L),
3200,
128);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_FluidDetector.get(1L),
- ItemList.Emitter_EV.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_FluidDetector.get(1L), ItemList.Emitter_EV.get(1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_WirelessFluidDetector.get(1L),
3200,
128);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_ItemDetector.get(1L), ItemList.Emitter_EV.get(1L), GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_ItemDetector.get(1L), ItemList.Emitter_EV.get(1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_WirelessItemDetector.get(1L),
3200,
128);
GT_Values.RA.addAssemblerRecipe(
- new ItemStack[] {
- ItemList.Cover_NeedsMaintainance.get(1L),
- ItemList.Emitter_EV.get(1L),
- GT_Utility.getIntegratedCircuit(1)
- },
+ new ItemStack[] { ItemList.Cover_NeedsMaintainance.get(1L), ItemList.Emitter_EV.get(1L),
+ GT_Utility.getIntegratedCircuit(1) },
GT_Values.NF,
ItemList.Cover_WirelessNeedsMaintainance.get(1L),
3200,
@@ -2447,16 +2773,16 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_AdvancedRedstoneReceiverExternal.get(1L),
- new Object[] {ItemList.Cover_AdvancedRedstoneReceiverInternal.get(1L)});
+ new Object[] { ItemList.Cover_AdvancedRedstoneReceiverInternal.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_AdvancedRedstoneReceiverInternal.get(1L),
- new Object[] {ItemList.Cover_AdvancedRedstoneReceiverExternal.get(1L)});
+ new Object[] { ItemList.Cover_AdvancedRedstoneReceiverExternal.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_AdvancedRedstoneTransmitterExternal.get(1L),
- new Object[] {ItemList.Cover_AdvancedRedstoneTransmitterInternal.get(1L)});
+ new Object[] { ItemList.Cover_AdvancedRedstoneTransmitterInternal.get(1L) });
GT_ModHandler.addShapelessCraftingRecipe(
ItemList.Cover_AdvancedRedstoneTransmitterInternal.get(1L),
- new Object[] {ItemList.Cover_AdvancedRedstoneTransmitterExternal.get(1L)});
+ new Object[] { ItemList.Cover_AdvancedRedstoneTransmitterExternal.get(1L) });
GT_ModHandler.addExtractionRecipe(new ItemStack(Blocks.red_flower, 1, 0), new ItemStack(Items.dye, 2, 1));
GT_ModHandler.addExtractionRecipe(new ItemStack(Blocks.red_flower, 1, 1), new ItemStack(Items.dye, 2, 12));
@@ -2480,40 +2806,47 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Silver, 1L));
GT_ModHandler.addExtractionRecipe(ItemList.Crop_Drop_Indigo.get(1L), ItemList.Dye_Indigo.get(1L));
GT_ModHandler.addExtractionRecipe(
- ItemList.Crop_Drop_MilkWart.get(1L), GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Milk, 1L));
+ ItemList.Crop_Drop_MilkWart.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Milk, 1L));
GT_ModHandler.addExtractionRecipe(
ItemList.Crop_Drop_Coppon.get(1L),
GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Copper, 1L));
GT_ModHandler.addExtractionRecipe(
- ItemList.Crop_Drop_Tine.get(1L), GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Tin, 1L));
+ ItemList.Crop_Drop_Tine.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Tin, 1L));
GT_ModHandler.addCompressionRecipe(ItemList.Crop_Drop_Coppon.get(4L), new ItemStack(Blocks.wool, 1, 1));
- GT_ModHandler.addCompressionRecipe(
- ItemList.Crop_Drop_Plumbilia.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
- GT_ModHandler.addCompressionRecipe(
- ItemList.Crop_Drop_Argentia.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
+ GT_ModHandler
+ .addCompressionRecipe(ItemList.Crop_Drop_Plumbilia.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
+ GT_ModHandler
+ .addCompressionRecipe(ItemList.Crop_Drop_Argentia.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(ItemList.Crop_Drop_Indigo.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(ItemList.Crop_Drop_Ferru.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
+ GT_ModHandler
+ .addCompressionRecipe(ItemList.Crop_Drop_Aurelia.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
+ GT_ModHandler
+ .addCompressionRecipe(ItemList.Crop_Drop_OilBerry.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(
- ItemList.Crop_Drop_Aurelia.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
- GT_ModHandler.addCompressionRecipe(
- ItemList.Crop_Drop_OilBerry.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
- GT_ModHandler.addCompressionRecipe(
- ItemList.Crop_Drop_BobsYerUncleRanks.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
+ ItemList.Crop_Drop_BobsYerUncleRanks.get(4L),
+ ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(ItemList.Crop_Drop_Tine.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(ItemList.Crop_Drop_Rape.get(4L), ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(
- new ItemStack(Blocks.red_flower, 8, 32767), ItemList.IC2_PlantballCompressed.get(1L));
+ new ItemStack(Blocks.red_flower, 8, 32767),
+ ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addCompressionRecipe(
- new ItemStack(Blocks.yellow_flower, 8, 32767), ItemList.IC2_PlantballCompressed.get(1L));
+ new ItemStack(Blocks.yellow_flower, 8, 32767),
+ ItemList.IC2_PlantballCompressed.get(1L));
GT_ModHandler.addPulverisationRecipe(
ItemList.Food_Sliced_Cheese.get(1L),
GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.Cheese, 1L));
GT_ModHandler.addPulverisationRecipe(
- ItemList.Dye_Cocoa.get(1L), GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Cocoa, 1L));
+ ItemList.Dye_Cocoa.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Cocoa, 1L));
GT_ModHandler.addPulverisationRecipe(
- ItemList.Crop_Drop_Tine.get(1L), GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.Wood, 2L));
+ ItemList.Crop_Drop_Tine.get(1L),
+ GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.Wood, 2L));
GT_ModHandler.addPulverisationRecipe(
new ItemStack(Blocks.melon_block, 1, 0),
new ItemStack(Items.melon, 8, 0),
@@ -2521,9 +2854,17 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
80,
false);
GT_ModHandler.addPulverisationRecipe(
- new ItemStack(Blocks.pumpkin, 1, 0), new ItemStack(Items.pumpkin_seeds, 4, 0), null, 0, false);
+ new ItemStack(Blocks.pumpkin, 1, 0),
+ new ItemStack(Items.pumpkin_seeds, 4, 0),
+ null,
+ 0,
+ false);
GT_ModHandler.addPulverisationRecipe(
- new ItemStack(Items.melon, 1, 0), new ItemStack(Items.melon_seeds, 1, 0), null, 0, false);
+ new ItemStack(Items.melon, 1, 0),
+ new ItemStack(Items.melon_seeds, 1, 0),
+ null,
+ 0,
+ false);
GT_ModHandler.addPulverisationRecipe(
new ItemStack(Items.wheat, 1, 0),
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wheat, 1L),
@@ -2550,8 +2891,8 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
false);
GT_ModHandler.addPulverisationRecipe(
ItemList.Tesseract.get(1),
- new ItemStack[] {GT_OreDictUnificator.get(OrePrefixes.dust, Materials.TranscendentMetal, 8L)},
- new int[] {10000},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.dust, Materials.TranscendentMetal, 8L) },
+ new int[] { 10000 },
32_000_000,
100);
try {
@@ -2565,12 +2906,13 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
e.printStackTrace(GT_Log.err);
}
}
- ItemList.Display_ITS_FREE.set(addItem(
- tLastID = 766,
- "ITS FREE",
- "(or at least almost free)",
- SubTag.INVISIBLE,
- new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
+ ItemList.Display_ITS_FREE.set(
+ addItem(
+ tLastID = 766,
+ "ITS FREE",
+ "(or at least almost free)",
+ SubTag.INVISIBLE,
+ new TC_Aspects.TC_AspectStack(TC_Aspects.LUCRUM, 1L)));
}
@Override
@@ -2593,8 +2935,8 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
}
@Override
- public EntityArrow getProjectile(
- SubTag aProjectileType, ItemStack aStack, World aWorld, double aX, double aY, double aZ) {
+ public EntityArrow getProjectile(SubTag aProjectileType, ItemStack aStack, World aWorld, double aX, double aY,
+ double aZ) {
int aDamage = aStack.getItemDamage();
if ((aDamage >= 25000) && (aDamage < 27000)) {
if (aDamage >= 26000) {
@@ -2606,13 +2948,13 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
}
@Override
- public EntityArrow getProjectile(
- SubTag aProjectileType, ItemStack aStack, World aWorld, EntityLivingBase aEntity, float aSpeed) {
+ public EntityArrow getProjectile(SubTag aProjectileType, ItemStack aStack, World aWorld, EntityLivingBase aEntity,
+ float aSpeed) {
int aDamage = aStack.getItemDamage();
if ((aDamage >= 25000) && (aDamage < 27000)) {
if (aDamage >= 26000) {
- return Behaviour_Arrow.DEFAULT_PLASTIC.getProjectile(
- this, aProjectileType, aStack, aWorld, aEntity, aSpeed);
+ return Behaviour_Arrow.DEFAULT_PLASTIC
+ .getProjectile(this, aProjectileType, aStack, aWorld, aEntity, aSpeed);
}
return Behaviour_Arrow.DEFAULT_WOODEN.getProjectile(this, aProjectileType, aStack, aWorld, aEntity, aSpeed);
}
@@ -2624,8 +2966,7 @@ public class GT_MetaGenerated_Item_02 extends GT_MetaGenerated_Item_X32 {
int aDamage = aStack.getItemDamage();
Materials aMaterial = GregTech_API.sGeneratedMaterials[(aDamage % 1000)];
if ((aDamage >= 25000) && (aDamage < 27000) && (aMaterial != null) && (aMaterial.mEnchantmentTools != null)) {
- Enchantment tEnchant = aMaterial.mEnchantmentTools == Enchantment.fortune
- ? Enchantment.looting
+ Enchantment tEnchant = aMaterial.mEnchantmentTools == Enchantment.fortune ? Enchantment.looting
: aMaterial.mEnchantmentTools;
if (tEnchant.type == EnumEnchantmentType.weapon) {
NBTTagCompound tNBT = GT_Utility.ItemNBT.getNBT(aStack);
diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_03.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_03.java
index aa18e8f02c..353e660727 100644
--- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_03.java
+++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_03.java
@@ -4,15 +4,17 @@ import static gregtech.api.enums.Textures.BlockIcons.SOLARPANEL_UEV;
import static gregtech.api.enums.Textures.BlockIcons.SOLARPANEL_UHV;
import static gregtech.api.enums.Textures.BlockIcons.SOLARPANEL_UIV;
+import net.minecraftforge.oredict.OreDictionary;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.*;
import gregtech.api.items.GT_MetaGenerated_Item_X32;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.common.covers.GT_Cover_SolarPanel;
-import net.minecraftforge.oredict.OreDictionary;
public class GT_MetaGenerated_Item_03 extends GT_MetaGenerated_Item_X32 {
+
public static GT_MetaGenerated_Item_03 INSTANCE;
public GT_MetaGenerated_Item_03() {
@@ -28,138 +30,143 @@ public class GT_MetaGenerated_Item_03 extends GT_MetaGenerated_Item_X32 {
Object[] o = new Object[0];
/**
- * circuit boards tier 1-7:
- * coated circuit board / wood plate + resin
- * Plastic Circuit Board / Plastic + Copper Foil + Sulfuric Acid
- * phenolic circuit board /carton+glue+chemical bath
- * epoxy circuit board /epoxy plate + copper foil + sulfuric acid
- * fiberglass circuit board (simple + multilayer) / glass + plastic + electrum foil + sulfurci acid
- * wetware lifesupport board / fiberglass CB + teflon +
+ * circuit boards tier 1-7: coated circuit board / wood plate + resin Plastic Circuit Board / Plastic + Copper
+ * Foil + Sulfuric Acid phenolic circuit board /carton+glue+chemical bath epoxy circuit board /epoxy plate +
+ * copper foil + sulfuric acid fiberglass circuit board (simple + multilayer) / glass + plastic + electrum foil
+ * + sulfurci acid wetware lifesupport board / fiberglass CB + teflon +
*/
- ItemList.Circuit_Board_Wetware.set(
- addItem(tLastID = 6, "Wetware Lifesupport Circuit Board", "The Board that keeps life", o));
+ ItemList.Circuit_Board_Wetware
+ .set(addItem(tLastID = 6, "Wetware Lifesupport Circuit Board", "The Board that keeps life", o));
ItemList.Circuit_Board_Plastic.set(addItem(tLastID = 7, "Plastic Circuit Board", "A Good Board", o));
ItemList.Circuit_Board_Bio.set(addItem(tLastID = 8, "Bio Circuit Board", "Bio genetic mutated Board", o));
/**
- * electronic components:
- * vacuum tube (glass tube + red alloy cables)
- * basic electronic circuits normal+smd
- * coils
- * diodes normal+smd
- * transistors normal+smd
- * capacitors normal+smd
- * Glass Fibers
+ * electronic components: vacuum tube (glass tube + red alloy cables) basic electronic circuits normal+smd coils
+ * diodes normal+smd transistors normal+smd capacitors normal+smd Glass Fibers
*/
- ItemList.Circuit_Parts_ResistorSMD.set(addItem(
- tLastID = 11,
- "SMD Resistor",
- "Electronic Component",
- OrePrefixes.componentCircuit.get(Materials.Resistor),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Parts_ResistorSMD.set(
+ addItem(
+ tLastID = 11,
+ "SMD Resistor",
+ "Electronic Component",
+ OrePrefixes.componentCircuit.get(Materials.Resistor),
+ SubTag.NO_UNIFICATION));
ItemList.Circuit_Parts_Glass_Tube.set(addItem(tLastID = 12, "Glass Tube", "", o));
ItemList.Circuit_Parts_Coil.set(addItem(tLastID = 14, "Small Coil", "Basic Electronic Component", o));
- ItemList.Circuit_Parts_DiodeSMD.set(addItem(
- tLastID = 16,
- "SMD Diode",
- "Electronic Component",
- OrePrefixes.componentCircuit.get(Materials.Diode),
- SubTag.NO_UNIFICATION));
- ItemList.Circuit_Parts_TransistorSMD.set(addItem(
- tLastID = 18,
- "SMD Transistor",
- "Electronic Component",
- OrePrefixes.componentCircuit.get(Materials.Transistor),
- SubTag.NO_UNIFICATION));
- ItemList.Circuit_Parts_CapacitorSMD.set(addItem(
- tLastID = 20,
- "SMD Capacitor",
- "Electronic Component",
- OrePrefixes.componentCircuit.get(Materials.Capacitor),
- SubTag.NO_UNIFICATION));
- ItemList.Circuit_Parts_GlassFiber.set(
- addItem(tLastID = 21, "Glass Fiber", Materials.BorosilicateGlass.mChemicalFormula, o));
+ ItemList.Circuit_Parts_DiodeSMD.set(
+ addItem(
+ tLastID = 16,
+ "SMD Diode",
+ "Electronic Component",
+ OrePrefixes.componentCircuit.get(Materials.Diode),
+ SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Parts_TransistorSMD.set(
+ addItem(
+ tLastID = 18,
+ "SMD Transistor",
+ "Electronic Component",
+ OrePrefixes.componentCircuit.get(Materials.Transistor),
+ SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Parts_CapacitorSMD.set(
+ addItem(
+ tLastID = 20,
+ "SMD Capacitor",
+ "Electronic Component",
+ OrePrefixes.componentCircuit.get(Materials.Capacitor),
+ SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Parts_GlassFiber
+ .set(addItem(tLastID = 21, "Glass Fiber", Materials.BorosilicateGlass.mChemicalFormula, o));
ItemList.Circuit_Parts_PetriDish.set(addItem(tLastID = 22, "Petri Dish", "For cultivating cells", o));
ItemList.Circuit_Parts_Reinforced_Glass_Tube.set(addItem(tLastID = 23, "Reinforced Glass Tube", "", o));
- ItemList.Circuit_Parts_ResistorASMD.set(
- addItem(tLastID = 24, "Advanced SMD Resistor", "Advanced Electronic Component", o));
- ItemList.Circuit_Parts_DiodeASMD.set(
- addItem(tLastID = 25, "Advanced SMD Diode", "Advanced Electronic Component", o));
- ItemList.Circuit_Parts_TransistorASMD.set(
- addItem(tLastID = 26, "Advanced SMD Transistor", "Advanced Electronic Component", o));
- ItemList.Circuit_Parts_CapacitorASMD.set(
- addItem(tLastID = 27, "Advanced SMD Capacitor", "Advanced Electronic Component", o));
-
- ItemList.Circuit_Parts_ResistorXSMD.set(
- addItem(tLastID = 178, "Optical SMD Resistor", "Highly Advanced Electronic Component", o));
- ItemList.Circuit_Parts_DiodeXSMD.set(
- addItem(tLastID = 179, "Optical SMD Diode", "Highly Advanced Electronic Component", o));
- ItemList.Circuit_Parts_TransistorXSMD.set(
- addItem(tLastID = 180, "Optical SMD Transistor", "Highly Advanced Electronic Component", o));
- ItemList.Circuit_Parts_CapacitorXSMD.set(
- addItem(tLastID = 181, "Optical SMD Capacitor", "Highly Advanced Electronic Component", o));
-
- ItemList.Circuit_Parts_InductorSMD.set(addItem(
- tLastID = 182,
- "SMD Inductor",
- "Electronic Component",
- OrePrefixes.componentCircuit.get(Materials.Inductor),
- SubTag.NO_UNIFICATION));
- ItemList.Circuit_Parts_InductorASMD.set(
- addItem(tLastID = 183, "Advanced SMD Inductor", "Advanced Electronic Component", o));
- ItemList.Circuit_Parts_InductorXSMD.set(
- addItem(tLastID = 184, "Optical SMD Inductor", "Highly Advanced Electronic Component", o));
-
- GT_OreDictUnificator.set(
- OrePrefixes.componentCircuit, Materials.Resistor, ItemList.Circuit_Parts_Resistor.get(1L));
+ ItemList.Circuit_Parts_ResistorASMD
+ .set(addItem(tLastID = 24, "Advanced SMD Resistor", "Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_DiodeASMD
+ .set(addItem(tLastID = 25, "Advanced SMD Diode", "Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_TransistorASMD
+ .set(addItem(tLastID = 26, "Advanced SMD Transistor", "Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_CapacitorASMD
+ .set(addItem(tLastID = 27, "Advanced SMD Capacitor", "Advanced Electronic Component", o));
+
+ ItemList.Circuit_Parts_ResistorXSMD
+ .set(addItem(tLastID = 178, "Optical SMD Resistor", "Highly Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_DiodeXSMD
+ .set(addItem(tLastID = 179, "Optical SMD Diode", "Highly Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_TransistorXSMD
+ .set(addItem(tLastID = 180, "Optical SMD Transistor", "Highly Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_CapacitorXSMD
+ .set(addItem(tLastID = 181, "Optical SMD Capacitor", "Highly Advanced Electronic Component", o));
+
+ ItemList.Circuit_Parts_InductorSMD.set(
+ addItem(
+ tLastID = 182,
+ "SMD Inductor",
+ "Electronic Component",
+ OrePrefixes.componentCircuit.get(Materials.Inductor),
+ SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Parts_InductorASMD
+ .set(addItem(tLastID = 183, "Advanced SMD Inductor", "Advanced Electronic Component", o));
+ ItemList.Circuit_Parts_InductorXSMD
+ .set(addItem(tLastID = 184, "Optical SMD Inductor", "Highly Advanced Electronic Component", o));
+
+ GT_OreDictUnificator
+ .set(OrePrefixes.componentCircuit, Materials.Resistor, ItemList.Circuit_Parts_Resistor.get(1L));
GT_OreDictUnificator.set(OrePrefixes.componentCircuit, Materials.Diode, ItemList.Circuit_Parts_Diode.get(1L));
- GT_OreDictUnificator.set(
- OrePrefixes.componentCircuit, Materials.Transistor, ItemList.Circuit_Parts_Transistor.get(1L));
+ GT_OreDictUnificator
+ .set(OrePrefixes.componentCircuit, Materials.Transistor, ItemList.Circuit_Parts_Transistor.get(1L));
GT_OreDictUnificator.set(OrePrefixes.componentCircuit, Materials.Inductor, ItemList.Circuit_Parts_Coil.get(1L));
- GT_OreDictUnificator.set(
- OrePrefixes.componentCircuit, Materials.Capacitor, ItemList.Circuit_Parts_Capacitor.get(1L));
+ GT_OreDictUnificator
+ .set(OrePrefixes.componentCircuit, Materials.Capacitor, ItemList.Circuit_Parts_Capacitor.get(1L));
GT_OreDictUnificator.addAssociation(
- OrePrefixes.componentCircuit, Materials.Resistor, ItemList.Circuit_Parts_ResistorSMD.get(1L), true);
+ OrePrefixes.componentCircuit,
+ Materials.Resistor,
+ ItemList.Circuit_Parts_ResistorSMD.get(1L),
+ true);
GT_OreDictUnificator.addAssociation(
- OrePrefixes.componentCircuit, Materials.Diode, ItemList.Circuit_Parts_DiodeSMD.get(1L), true);
+ OrePrefixes.componentCircuit,
+ Materials.Diode,
+ ItemList.Circuit_Parts_DiodeSMD.get(1L),
+ true);
GT_OreDictUnificator.addAssociation(
- OrePrefixes.componentCircuit, Materials.Transistor, ItemList.Circuit_Parts_TransistorSMD.get(1L), true);
+ OrePrefixes.componentCircuit,
+ Materials.Transistor,
+ ItemList.Circuit_Parts_TransistorSMD.get(1L),
+ true);
GT_OreDictUnificator.addAssociation(
- OrePrefixes.componentCircuit, Materials.Capacitor, ItemList.Circuit_Parts_CapacitorSMD.get(1L), true);
+ OrePrefixes.componentCircuit,
+ Materials.Capacitor,
+ ItemList.Circuit_Parts_CapacitorSMD.get(1L),
+ true);
GT_OreDictUnificator.addAssociation(
- OrePrefixes.componentCircuit, Materials.Inductor, ItemList.Circuit_Parts_InductorSMD.get(1L), true);
+ OrePrefixes.componentCircuit,
+ Materials.Inductor,
+ ItemList.Circuit_Parts_InductorSMD.get(1L),
+ true);
/**
- * ICs
- * Lenses made from perfect crystals first instead of plates
- * Monocrystalline silicon ingot (normal+glowstone+naquadah) EBF, normal silicon no EBF need anymore
- * wafer(normal+glowstone+naquadah) cut mono silicon ingot in cutting machine
+ * ICs Lenses made from perfect crystals first instead of plates Monocrystalline silicon ingot
+ * (normal+glowstone+naquadah) EBF, normal silicon no EBF need anymore wafer(normal+glowstone+naquadah) cut mono
+ * silicon ingot in cutting machine
*
- * Integrated Logic Circuit(8bit DIP)
- * RAM
- * NAND Memory
- * NOR Memory
- * CPU (4 sizes)
- * SoCs(2 sizes, high tier cheap low tech component)
- * Power IC/High Power IC/Ultra High power
+ * Integrated Logic Circuit(8bit DIP) RAM NAND Memory NOR Memory CPU (4 sizes) SoCs(2 sizes, high tier cheap low
+ * tech component) Power IC/High Power IC/Ultra High power
*
* nanotube interconnected circuit (H-IC + nanotubes)
*
* quantum chips
*/
ItemList.Circuit_Silicon_Ingot.set(addItem(tLastID = 30, "Monocrystalline Silicon Boule", "Raw Circuit", o));
- ItemList.Circuit_Silicon_Ingot2.set(
- addItem(tLastID = 31, "Phosphorus doped Monocrystalline Silicon Boule", "Raw Circuit", o));
- ItemList.Circuit_Silicon_Ingot3.set(
- addItem(tLastID = 32, "Naquadah doped Monocrystalline Silicon Boule", "Raw Circuit", o));
- ItemList.Circuit_Silicon_Ingot4.set(
- addItem(tLastID = 150, "Europium doped Monocrystalline Silicon Boule", "Raw Circuit", o));
- ItemList.Circuit_Silicon_Ingot5.set(
- addItem(tLastID = 152, "Americium doped Monocrystalline Silicon Boule", "Raw Circuit", o));
- ItemList.Circuit_Silicon_Ingot6.set(
- addItem(tLastID = 721, "Optically Enriched Crystalline Boule", "Raw Circuit", o));
+ ItemList.Circuit_Silicon_Ingot2
+ .set(addItem(tLastID = 31, "Phosphorus doped Monocrystalline Silicon Boule", "Raw Circuit", o));
+ ItemList.Circuit_Silicon_Ingot3
+ .set(addItem(tLastID = 32, "Naquadah doped Monocrystalline Silicon Boule", "Raw Circuit", o));
+ ItemList.Circuit_Silicon_Ingot4
+ .set(addItem(tLastID = 150, "Europium doped Monocrystalline Silicon Boule", "Raw Circuit", o));
+ ItemList.Circuit_Silicon_Ingot5
+ .set(addItem(tLastID = 152, "Americium doped Monocrystalline Silicon Boule", "Raw Circuit", o));
+ ItemList.Circuit_Silicon_Ingot6
+ .set(addItem(tLastID = 721, "Optically Enriched Crystalline Boule", "Raw Circuit", o));
ItemList.Circuit_Silicon_Wafer.set(addItem(tLastID = 33, "Wafer", "Raw Circuit", o));
ItemList.Circuit_Silicon_Wafer2.set(addItem(tLastID = 34, "Phosphorus doped Wafer", "Raw Circuit", o));
@@ -197,8 +204,8 @@ public class GT_MetaGenerated_Item_03 extends GT_MetaGenerated_Item_X32 {
ItemList.Circuit_Chip_HPIC.set(addItem(tLastID = 53, "High Power IC", "High Power Circuit", o));
ItemList.Circuit_Wafer_NanoCPU.set(addItem(tLastID = 54, "NanoCPU Wafer", "Raw Circuit", o));
- ItemList.Circuit_Chip_NanoCPU.set(
- addItem(tLastID = 55, "Nanocomponent Central Processing Unit", "Power Circuit", o));
+ ItemList.Circuit_Chip_NanoCPU
+ .set(addItem(tLastID = 55, "Nanocomponent Central Processing Unit", "Power Circuit", o));
ItemList.Circuit_Wafer_QuantumCPU.set(addItem(tLastID = 56, "QBit Wafer", "Raw Circuit", o));
ItemList.Circuit_Chip_QuantumCPU.set(addItem(tLastID = 57, "QBit Processing Unit", "Quantum CPU", o));
@@ -224,375 +231,415 @@ public class GT_MetaGenerated_Item_03 extends GT_MetaGenerated_Item_X32 {
ItemList.Circuit_Wafer_QPIC.set(addItem(tLastID = 164, "QPIC Wafer", "Raw Circuit", o));
ItemList.Circuit_Chip_QPIC.set(addItem(tLastID = 165, "Quantum Power IC", "Quantum Power Circuit", o));
/**
- * Engraved Crystal Chip
- * Engraved Lapotron Chip
- * Crystal CPU
- * SoCrystal
- * stem cells (disassemble eggs)
+ * Engraved Crystal Chip Engraved Lapotron Chip Crystal CPU SoCrystal stem cells (disassemble eggs)
*/
- ItemList.Circuit_Chip_CrystalSoC2.set(
- addItem(tLastID = 68, "Raw Advanced Crystal Chip", "Raw Advanced Crystal Processor", o));
- ItemList.Circuit_Parts_RawCrystalChip.set(
- addItem(tLastID = 69, "Raw Crystal Chip", "Raw Crystal Processor", o));
- ItemList.Circuit_Chip_CrystalCPU.set(
- addItem(tLastID = 70, "Crystal Processing Unit", "Crystal CPU", o)); // Crystal chip elite part
+ ItemList.Circuit_Chip_CrystalSoC2
+ .set(addItem(tLastID = 68, "Raw Advanced Crystal Chip", "Raw Advanced Crystal Processor", o));
+ ItemList.Circuit_Parts_RawCrystalChip
+ .set(addItem(tLastID = 69, "Raw Crystal Chip", "Raw Crystal Processor", o));
+ ItemList.Circuit_Chip_CrystalCPU.set(addItem(tLastID = 70, "Crystal Processing Unit", "Crystal CPU", o)); // Crystal
+ // chip
+ // elite
+ // part
ItemList.Circuit_Chip_CrystalSoC.set(addItem(tLastID = 71, "Crystal SoC", "Crystal System on a Chip", o));
ItemList.Circuit_Chip_NeuroCPU.set(addItem(tLastID = 72, "Neuro Processing Unit", "Neuro CPU", o));
ItemList.Circuit_Chip_Stemcell.set(addItem(tLastID = 73, "Stemcells", "Raw inteligence", o));
- ItemList.Circuit_Parts_RawCrystalParts.set(
- addItem(tLastID = 74, "Raw Crystal Chip Parts", "Raw Crystal Processor Parts", o));
+ ItemList.Circuit_Parts_RawCrystalParts
+ .set(addItem(tLastID = 74, "Raw Crystal Chip Parts", "Raw Crystal Processor Parts", o));
ItemList.Circuit_Chip_Biocell.set(addItem(tLastID = 76, "Biocells", "Mutated Raw inteligence", o));
ItemList.Circuit_Chip_BioCPU.set(addItem(tLastID = 77, "Bio Processing Unit", "Bio CPU", o));
ItemList.Circuit_Chip_Optical.set(addItem(tLastID = 724, "Raw Exposed Optical Chip", "Raw Optical Chip", o));
// Nand Chip
- ItemList.NandChip.set(addItem(
- tLastID = 75,
- "NAND Chip",
- "A very simple Circuit",
- OrePrefixes.circuit.get(Materials.Primitive),
- SubTag.NO_UNIFICATION));
+ ItemList.NandChip.set(
+ addItem(
+ tLastID = 75,
+ "NAND Chip",
+ "A very simple Circuit",
+ OrePrefixes.circuit.get(Materials.Primitive),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("ULV", ItemList.NandChip.get(1));
- // Vacuum Tube Item01
- // Basic Circuit IC2
- // Good Circuit Item01
-
- // Integrated Logic Circuit Item01
- ItemList.Circuit_Integrated_Good.set(addItem(
- tLastID = 79,
- "Good Integrated Circuit",
- "Good Circuit",
- OrePrefixes.circuit.get(Materials.Good),
- SubTag.NO_UNIFICATION));
+ // Vacuum Tube Item01
+ // Basic Circuit IC2
+ // Good Circuit Item01
+
+ // Integrated Logic Circuit Item01
+ ItemList.Circuit_Integrated_Good.set(
+ addItem(
+ tLastID = 79,
+ "Good Integrated Circuit",
+ "Good Circuit",
+ OrePrefixes.circuit.get(Materials.Good),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("MV", ItemList.Circuit_Integrated_Good.get(1));
- // Good Integrated Circuit Item01
- // Advanced Circuit IC2
-
- ItemList.Circuit_Microprocessor.set(addItem(
- tLastID = 78,
- "Microprocessor",
- "A Basic Circuit",
- OrePrefixes.circuit.get(Materials.Basic),
- SubTag.NO_UNIFICATION));
+ // Good Integrated Circuit Item01
+ // Advanced Circuit IC2
+
+ ItemList.Circuit_Microprocessor.set(
+ addItem(
+ tLastID = 78,
+ "Microprocessor",
+ "A Basic Circuit",
+ OrePrefixes.circuit.get(Materials.Basic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("LV", ItemList.Circuit_Microprocessor.get(1));
- ItemList.Circuit_Processor.set(addItem(
- tLastID = 80,
- "Integrated Processor",
- "A Good Circuit",
- OrePrefixes.circuit.get(Materials.Good),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Processor.set(
+ addItem(
+ tLastID = 80,
+ "Integrated Processor",
+ "A Good Circuit",
+ OrePrefixes.circuit.get(Materials.Good),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("MV", ItemList.Circuit_Processor.get(1));
- // ItemList.Circuit_Computer.set(addItem(tLastID = 81, "Processor Assembly", "Advanced Circuit", new
+ // ItemList.Circuit_Computer.set(addItem(tLastID = 81, "Processor Assembly", "Advanced Circuit", new
// Object[]{OrePrefixes.circuit.get(Materials.Advanced), SubTag.NO_UNIFICATION}));
- // Workstation/ Item01 Datacircuit
- // Mainframe Item01 DataProcessor
-
- ItemList.Circuit_Nanoprocessor.set(addItem(
- tLastID = 82,
- "Nanoprocessor",
- "An Advanced Circuit",
- OrePrefixes.circuit.get(Materials.Advanced),
- SubTag.NO_UNIFICATION));
+ // Workstation/ Item01 Datacircuit
+ // Mainframe Item01 DataProcessor
+
+ ItemList.Circuit_Nanoprocessor.set(
+ addItem(
+ tLastID = 82,
+ "Nanoprocessor",
+ "An Advanced Circuit",
+ OrePrefixes.circuit.get(Materials.Advanced),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("HV", ItemList.Circuit_Nanoprocessor.get(1));
- ItemList.Circuit_Nanocomputer.set(addItem(
- tLastID = 83,
- "Nanoprocessor Assembly",
- "An Extreme Circuit",
- OrePrefixes.circuit.get(Materials.Data),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Nanocomputer.set(
+ addItem(
+ tLastID = 83,
+ "Nanoprocessor Assembly",
+ "An Extreme Circuit",
+ OrePrefixes.circuit.get(Materials.Data),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("EV", ItemList.Circuit_Nanocomputer.get(1));
- ItemList.Circuit_Elitenanocomputer.set(addItem(
- tLastID = 84,
- "Elite Nanocomputer",
- "An Elite Circuit",
- OrePrefixes.circuit.get(Materials.Elite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Elitenanocomputer.set(
+ addItem(
+ tLastID = 84,
+ "Elite Nanocomputer",
+ "An Elite Circuit",
+ OrePrefixes.circuit.get(Materials.Elite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("IV", ItemList.Circuit_Elitenanocomputer.get(1));
- // Nanoprocessor Mainframe Item01 Energy Flow Circuit
+ // Nanoprocessor Mainframe Item01 Energy Flow Circuit
// Quantum circuits
- ItemList.Circuit_Quantumprocessor.set(addItem(
- tLastID = 85,
- "Quantumprocessor",
- "An Extreme Circuit",
- OrePrefixes.circuit.get(Materials.Data),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Quantumprocessor.set(
+ addItem(
+ tLastID = 85,
+ "Quantumprocessor",
+ "An Extreme Circuit",
+ OrePrefixes.circuit.get(Materials.Data),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("EV", ItemList.Circuit_Quantumprocessor.get(1));
- ItemList.Circuit_Quantumcomputer.set(addItem(
- tLastID = 86,
- "Quantumprocessor Assembly",
- "An Elite Circuit",
- OrePrefixes.circuit.get(Materials.Elite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Quantumcomputer.set(
+ addItem(
+ tLastID = 86,
+ "Quantumprocessor Assembly",
+ "An Elite Circuit",
+ OrePrefixes.circuit.get(Materials.Elite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("IV", ItemList.Circuit_Quantumcomputer.get(1));
- ItemList.Circuit_Masterquantumcomputer.set(addItem(
- tLastID = 87,
- "Master Quantumcomputer",
- "A Master Circuit",
- OrePrefixes.circuit.get(Materials.Master),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Masterquantumcomputer.set(
+ addItem(
+ tLastID = 87,
+ "Master Quantumcomputer",
+ "A Master Circuit",
+ OrePrefixes.circuit.get(Materials.Master),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("LuV", ItemList.Circuit_Masterquantumcomputer.get(1));
- ItemList.Circuit_Quantummainframe.set(addItem(
- tLastID = 88,
- "Quantumprocessor Mainframe",
- "An Ultimate Circuit",
- OrePrefixes.circuit.get(Materials.Ultimate),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Quantummainframe.set(
+ addItem(
+ tLastID = 88,
+ "Quantumprocessor Mainframe",
+ "An Ultimate Circuit",
+ OrePrefixes.circuit.get(Materials.Ultimate),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("ZPM", ItemList.Circuit_Quantummainframe.get(1));
// Crystal circuits
- ItemList.Circuit_Crystalprocessor.set(addItem(
- tLastID = 89,
- "Crystalprocessor",
- "An Elite Circuit",
- OrePrefixes.circuit.get(Materials.Elite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Crystalprocessor.set(
+ addItem(
+ tLastID = 89,
+ "Crystalprocessor",
+ "An Elite Circuit",
+ OrePrefixes.circuit.get(Materials.Elite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("IV", ItemList.Circuit_Crystalprocessor.get(1));
- ItemList.Circuit_Crystalcomputer.set(addItem(
- tLastID = 96,
- "Crystalprocessor Assembly",
- "A Master Circuit",
- OrePrefixes.circuit.get(Materials.Master),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Crystalcomputer.set(
+ addItem(
+ tLastID = 96,
+ "Crystalprocessor Assembly",
+ "A Master Circuit",
+ OrePrefixes.circuit.get(Materials.Master),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("LuV", ItemList.Circuit_Crystalcomputer.get(1));
- ItemList.Circuit_Ultimatecrystalcomputer.set(addItem(
- tLastID = 90,
- "Ultimate Crystalcomputer",
- "An Ultimate Circuit",
- OrePrefixes.circuit.get(Materials.Ultimate),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Ultimatecrystalcomputer.set(
+ addItem(
+ tLastID = 90,
+ "Ultimate Crystalcomputer",
+ "An Ultimate Circuit",
+ OrePrefixes.circuit.get(Materials.Ultimate),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("ZPM", ItemList.Circuit_Ultimatecrystalcomputer.get(1));
- ItemList.Circuit_Crystalmainframe.set(addItem(
- tLastID = 91,
- "Crystalprocessor Mainframe",
- "A Super Circuit",
- OrePrefixes.circuit.get(Materials.Superconductor),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Crystalmainframe.set(
+ addItem(
+ tLastID = 91,
+ "Crystalprocessor Mainframe",
+ "A Super Circuit",
+ OrePrefixes.circuit.get(Materials.Superconductor),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UV", ItemList.Circuit_Crystalmainframe.get(1));
// ???? Scared to remove.
ItemList.Circuit_Ultimate.set(ItemList.Circuit_Ultimatecrystalcomputer.get(1L)); // maybe should be removed
// Wetware circuits
- ItemList.Circuit_Neuroprocessor.set(addItem(
- tLastID = 92,
- "Wetwareprocessor",
- "A Master Circuit",
- OrePrefixes.circuit.get(Materials.Master),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Neuroprocessor.set(
+ addItem(
+ tLastID = 92,
+ "Wetwareprocessor",
+ "A Master Circuit",
+ OrePrefixes.circuit.get(Materials.Master),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("LuV", ItemList.Circuit_Neuroprocessor.get(1));
- ItemList.Circuit_Wetwarecomputer.set(addItem(
- tLastID = 93,
- "Wetwareprocessor Assembly",
- "An Ultimate Circuit",
- OrePrefixes.circuit.get(Materials.Ultimate),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Wetwarecomputer.set(
+ addItem(
+ tLastID = 93,
+ "Wetwareprocessor Assembly",
+ "An Ultimate Circuit",
+ OrePrefixes.circuit.get(Materials.Ultimate),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("ZPM", ItemList.Circuit_Wetwarecomputer.get(1));
- ItemList.Circuit_Wetwaresupercomputer.set(addItem(
- tLastID = 94,
- "Wetware Supercomputer",
- "A Super Circuit",
- OrePrefixes.circuit.get(Materials.Superconductor),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Wetwaresupercomputer.set(
+ addItem(
+ tLastID = 94,
+ "Wetware Supercomputer",
+ "A Super Circuit",
+ OrePrefixes.circuit.get(Materials.Superconductor),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UV", ItemList.Circuit_Wetwaresupercomputer.get(1));
- ItemList.Circuit_Wetwaremainframe.set(addItem(
- tLastID = 95,
- "Wetware Mainframe",
- "An Infinite Circuit",
- OrePrefixes.circuit.get(Materials.Infinite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Wetwaremainframe.set(
+ addItem(
+ tLastID = 95,
+ "Wetware Mainframe",
+ "An Infinite Circuit",
+ OrePrefixes.circuit.get(Materials.Infinite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UHV", ItemList.Circuit_Wetwaremainframe.get(1));
// Bioware circuits.
- ItemList.Circuit_Bioprocessor.set(addItem(
- tLastID = 97,
- "Bioprocessor",
- "An Ultimate Circuit",
- OrePrefixes.circuit.get(Materials.Ultimate),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Bioprocessor.set(
+ addItem(
+ tLastID = 97,
+ "Bioprocessor",
+ "An Ultimate Circuit",
+ OrePrefixes.circuit.get(Materials.Ultimate),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("ZPM", ItemList.Circuit_Bioprocessor.get(1));
- ItemList.Circuit_Biowarecomputer.set(addItem(
- tLastID = 98,
- "Biowareprocessor Assembly",
- "A Super Circuit",
- OrePrefixes.circuit.get(Materials.Superconductor),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Biowarecomputer.set(
+ addItem(
+ tLastID = 98,
+ "Biowareprocessor Assembly",
+ "A Super Circuit",
+ OrePrefixes.circuit.get(Materials.Superconductor),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UV", ItemList.Circuit_Biowarecomputer.get(1));
- ItemList.Circuit_Biowaresupercomputer.set(addItem(
- tLastID = 99,
- "Bioware Supercomputer",
- "An Infinite Circuit",
- OrePrefixes.circuit.get(Materials.Infinite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Biowaresupercomputer.set(
+ addItem(
+ tLastID = 99,
+ "Bioware Supercomputer",
+ "An Infinite Circuit",
+ OrePrefixes.circuit.get(Materials.Infinite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UHV", ItemList.Circuit_Biowaresupercomputer.get(1));
- ItemList.Circuit_Biomainframe.set(addItem(
- tLastID = 120,
- "Bio Mainframe",
- "A Bio Circuit",
- OrePrefixes.circuit.get(Materials.Bio),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_Biomainframe.set(
+ addItem(
+ tLastID = 120,
+ "Bio Mainframe",
+ "A Bio Circuit",
+ OrePrefixes.circuit.get(Materials.Bio),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UEV", ItemList.Circuit_Biomainframe.get(1));
ItemList.Circuit_Board_Coated_Basic.set(addItem(tLastID = 100, "Circuit Board", "A basic Circuit Board", o));
- ItemList.Circuit_Board_Phenolic_Good.set(
- addItem(tLastID = 101, "Good Circuit Board", "A good Circuit Board", o));
- ItemList.Circuit_Board_Epoxy_Advanced.set(
- addItem(tLastID = 102, "Advanced Circuit Board", "A advanced Circuit Board", o));
- ItemList.Circuit_Board_Fiberglass_Advanced.set(
- addItem(tLastID = 103, "More Advanced Circuit Board", "A more advanced Circuit Board", o));
- ItemList.Circuit_Board_Multifiberglass_Elite.set(
- addItem(tLastID = 104, "Elite Circuit Board", "A elite Circuit Board", o));
+ ItemList.Circuit_Board_Phenolic_Good
+ .set(addItem(tLastID = 101, "Good Circuit Board", "A good Circuit Board", o));
+ ItemList.Circuit_Board_Epoxy_Advanced
+ .set(addItem(tLastID = 102, "Advanced Circuit Board", "A advanced Circuit Board", o));
+ ItemList.Circuit_Board_Fiberglass_Advanced
+ .set(addItem(tLastID = 103, "More Advanced Circuit Board", "A more advanced Circuit Board", o));
+ ItemList.Circuit_Board_Multifiberglass_Elite
+ .set(addItem(tLastID = 104, "Elite Circuit Board", "A elite Circuit Board", o));
ItemList.Circuit_Board_Wetware_Extreme.set(
addItem(tLastID = 105, "Extreme Wetware Lifesupport Circuit Board", "The Board that keeps life", o));
ItemList.Circuit_Board_Plastic_Advanced.set(addItem(tLastID = 106, "Plastic Circuit Board", "A good Board", o));
- ItemList.Circuit_Board_Bio_Ultra.set(
- addItem(tLastID = 107, "Ultra Bio Mutated Circuit Board", "Bio genetic mutated Board", o));
- ItemList.Circuit_Board_Optical.set(
- addItem(tLastID = 728, "Optical Circuit Board", "Optically Infused Board", o));
+ ItemList.Circuit_Board_Bio_Ultra
+ .set(addItem(tLastID = 107, "Ultra Bio Mutated Circuit Board", "Bio genetic mutated Board", o));
+ ItemList.Circuit_Board_Optical
+ .set(addItem(tLastID = 728, "Optical Circuit Board", "Optically Infused Board", o));
// Optical circuits
- ItemList.Circuit_OpticalProcessor.set(addItem(
- tLastID = 154,
- "Optical Processor",
- "An Optical Circuit",
- OrePrefixes.circuit.get(Materials.Superconductor),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_OpticalProcessor.set(
+ addItem(
+ tLastID = 154,
+ "Optical Processor",
+ "An Optical Circuit",
+ OrePrefixes.circuit.get(Materials.Superconductor),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UV", ItemList.Circuit_OpticalProcessor.get(1));
- ItemList.Circuit_OpticalAssembly.set(addItem(
- tLastID = 155,
- "Optical Assembly",
- "An Optical Circuit",
- OrePrefixes.circuit.get(Materials.Infinite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_OpticalAssembly.set(
+ addItem(
+ tLastID = 155,
+ "Optical Assembly",
+ "An Optical Circuit",
+ OrePrefixes.circuit.get(Materials.Infinite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UHV", ItemList.Circuit_OpticalAssembly.get(1));
- ItemList.Circuit_OpticalComputer.set(addItem(
- tLastID = 156,
- "Optical Computer",
- "An Optical Circuit",
- OrePrefixes.circuit.get(Materials.Bio),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_OpticalComputer.set(
+ addItem(
+ tLastID = 156,
+ "Optical Computer",
+ "An Optical Circuit",
+ OrePrefixes.circuit.get(Materials.Bio),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UEV", ItemList.Circuit_OpticalComputer.get(1));
- ItemList.Circuit_OpticalMainframe.set(addItem(
- tLastID = 157,
- "Optical Mainframe",
- "An Optical Circuit",
- OrePrefixes.circuit.get(Materials.Optical),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_OpticalMainframe.set(
+ addItem(
+ tLastID = 157,
+ "Optical Mainframe",
+ "An Optical Circuit",
+ OrePrefixes.circuit.get(Materials.Optical),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UIV", ItemList.Circuit_OpticalMainframe.get(1));
// Exotic circuits
- ItemList.Circuit_ExoticProcessor.set(addItem(
- tLastID = 166,
- "Exotic Processor",
- "An Exotic Circuit",
- OrePrefixes.circuit.get(Materials.Infinite),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_ExoticProcessor.set(
+ addItem(
+ tLastID = 166,
+ "Exotic Processor",
+ "An Exotic Circuit",
+ OrePrefixes.circuit.get(Materials.Infinite),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UHV", ItemList.Circuit_ExoticProcessor.get(1));
- ItemList.Circuit_ExoticAssembly.set(addItem(
- tLastID = 167,
- "Exotic Assembly",
- "An Exotic Circuit",
- OrePrefixes.circuit.get(Materials.Bio),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_ExoticAssembly.set(
+ addItem(
+ tLastID = 167,
+ "Exotic Assembly",
+ "An Exotic Circuit",
+ OrePrefixes.circuit.get(Materials.Bio),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UEV", ItemList.Circuit_ExoticAssembly.get(1));
- ItemList.Circuit_ExoticComputer.set(addItem(
- tLastID = 168,
- "Exotic Computer",
- "An Exotic Circuit",
- OrePrefixes.circuit.get(Materials.Optical),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_ExoticComputer.set(
+ addItem(
+ tLastID = 168,
+ "Exotic Computer",
+ "An Exotic Circuit",
+ OrePrefixes.circuit.get(Materials.Optical),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UIV", ItemList.Circuit_ExoticComputer.get(1));
- ItemList.Circuit_ExoticMainframe.set(addItem(
- tLastID = 169,
- "Exotic Mainframe",
- "An Exotic Circuit",
- OrePrefixes.circuit.get(Materials.Exotic),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_ExoticMainframe.set(
+ addItem(
+ tLastID = 169,
+ "Exotic Mainframe",
+ "An Exotic Circuit",
+ OrePrefixes.circuit.get(Materials.Exotic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UMV", ItemList.Circuit_ExoticMainframe.get(1));
// Cosmic circuits
- ItemList.Circuit_CosmicProcessor.set(addItem(
- tLastID = 170,
- "Cosmic Processor",
- "A Cosmic Circuit",
- OrePrefixes.circuit.get(Materials.Bio),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_CosmicProcessor.set(
+ addItem(
+ tLastID = 170,
+ "Cosmic Processor",
+ "A Cosmic Circuit",
+ OrePrefixes.circuit.get(Materials.Bio),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UEV", ItemList.Circuit_CosmicProcessor.get(1));
- ItemList.Circuit_CosmicAssembly.set(addItem(
- tLastID = 171,
- "Cosmic Assembly",
- "A Cosmic Circuit",
- OrePrefixes.circuit.get(Materials.Optical),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_CosmicAssembly.set(
+ addItem(
+ tLastID = 171,
+ "Cosmic Assembly",
+ "A Cosmic Circuit",
+ OrePrefixes.circuit.get(Materials.Optical),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UIV", ItemList.Circuit_CosmicAssembly.get(1));
- ItemList.Circuit_CosmicComputer.set(addItem(
- tLastID = 172,
- "Cosmic Computer",
- "A Cosmic Circuit",
- OrePrefixes.circuit.get(Materials.Exotic),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_CosmicComputer.set(
+ addItem(
+ tLastID = 172,
+ "Cosmic Computer",
+ "A Cosmic Circuit",
+ OrePrefixes.circuit.get(Materials.Exotic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UMV", ItemList.Circuit_CosmicComputer.get(1));
- ItemList.Circuit_CosmicMainframe.set(addItem(
- tLastID = 173,
- "Cosmic Mainframe",
- "A Cosmic Circuit",
- OrePrefixes.circuit.get(Materials.Cosmic),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_CosmicMainframe.set(
+ addItem(
+ tLastID = 173,
+ "Cosmic Mainframe",
+ "A Cosmic Circuit",
+ OrePrefixes.circuit.get(Materials.Cosmic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UXV", ItemList.Circuit_CosmicMainframe.get(1));
// Transcendent circuits
- ItemList.Circuit_TranscendentProcessor.set(addItem(
- tLastID = 174,
- "Temporally Transcendent Processor",
- "A circuit operating outside of known spacetime",
- OrePrefixes.circuit.get(Materials.Optical),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_TranscendentProcessor.set(
+ addItem(
+ tLastID = 174,
+ "Temporally Transcendent Processor",
+ "A circuit operating outside of known spacetime",
+ OrePrefixes.circuit.get(Materials.Optical),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UIV", ItemList.Circuit_TranscendentProcessor.get(1));
- ItemList.Circuit_TranscendentAssembly.set(addItem(
- tLastID = 175,
- "Temporally Transcendent Assembly",
- "A circuit operating outside of known spacetime",
- OrePrefixes.circuit.get(Materials.Exotic),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_TranscendentAssembly.set(
+ addItem(
+ tLastID = 175,
+ "Temporally Transcendent Assembly",
+ "A circuit operating outside of known spacetime",
+ OrePrefixes.circuit.get(Materials.Exotic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UMV", ItemList.Circuit_TranscendentAssembly.get(1));
- ItemList.Circuit_TranscendentComputer.set(addItem(
- tLastID = 176,
- "Temporally Transcendent Computer",
- "A circuit operating outside of known spacetime",
- OrePrefixes.circuit.get(Materials.Cosmic),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_TranscendentComputer.set(
+ addItem(
+ tLastID = 176,
+ "Temporally Transcendent Computer",
+ "A circuit operating outside of known spacetime",
+ OrePrefixes.circuit.get(Materials.Cosmic),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("UXV", ItemList.Circuit_TranscendentComputer.get(1));
- ItemList.Circuit_TranscendentMainframe.set(addItem(
- tLastID = 177,
- "Temporally Transcendent Mainframe",
- "A circuit operating outside of known spacetime",
- OrePrefixes.circuit.get(Materials.Transcendent),
- SubTag.NO_UNIFICATION));
+ ItemList.Circuit_TranscendentMainframe.set(
+ addItem(
+ tLastID = 177,
+ "Temporally Transcendent Mainframe",
+ "A circuit operating outside of known spacetime",
+ OrePrefixes.circuit.get(Materials.Transcendent),
+ SubTag.NO_UNIFICATION));
OreDictionary.registerOre("MAX", ItemList.Circuit_TranscendentMainframe.get(1));
ItemList.Tube_Wires.set(addItem(tLastID = 110, "Tube Wires", "For the Vacuum Tubes", o));
- ItemList.Cover_SolarPanel_UHV.set(addItem(
- tLastID = 130,
- "Solar Panel (UHV)",
- "Ultimate High Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 128L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 128L)));
- ItemList.Cover_SolarPanel_UEV.set(addItem(
- tLastID = 131,
- "Solar Panel (UEV)",
- "Ultimate Extreme Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 256L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 256L)));
- ItemList.Cover_SolarPanel_UIV.set(addItem(
- tLastID = 132,
- "Solar Panel (UIV)",
- "Ultimate Insane Voltage Solar Panel (Needs cleaning with right click)",
- new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 512L),
- new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 512L)));
+ ItemList.Cover_SolarPanel_UHV.set(
+ addItem(
+ tLastID = 130,
+ "Solar Panel (UHV)",
+ "Ultimate High Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 128L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 128L)));
+ ItemList.Cover_SolarPanel_UEV.set(
+ addItem(
+ tLastID = 131,
+ "Solar Panel (UEV)",
+ "Ultimate Extreme Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 256L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 256L)));
+ ItemList.Cover_SolarPanel_UIV.set(
+ addItem(
+ tLastID = 132,
+ "Solar Panel (UIV)",
+ "Ultimate Insane Voltage Solar Panel (Needs cleaning with right click)",
+ new TC_Aspects.TC_AspectStack(TC_Aspects.ELECTRUM, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.POTENTIA, 512L),
+ new TC_Aspects.TC_AspectStack(TC_Aspects.TENEBRAE, 512L)));
GregTech_API.registerCover(
ItemList.Cover_SolarPanel_UHV.get(1L),
@@ -619,164 +666,194 @@ public class GT_MetaGenerated_Item_03 extends GT_MetaGenerated_Item_X32 {
ItemList.UHV_Coil.set(addItem(tLastID = 149, "Highly Ultimate Voltage Coil", "Infinite Coil", o));
ItemList.GalliumArsenideCrystal.set(addItem(tLastID = 190, "Gallium Arsenide Crystal", "For making boules", o));
- ItemList.GalliumArsenideCrystalSmallPart.set(
- addItem(tLastID = 191, "Small Gallium Arsenide Crystal", "For making boules", o));
+ ItemList.GalliumArsenideCrystalSmallPart
+ .set(addItem(tLastID = 191, "Small Gallium Arsenide Crystal", "For making boules", o));
ItemList.KevlarFiber.set(addItem(tLastID = 192, "Kevlar Fiber", "For make Kevlar Plates", o));
ItemList.WovenKevlar.set(addItem(tLastID = 193, "Woven Kevlar", "For make Kevlar Plates", o));
ItemList.Spinneret.set(addItem(tLastID = 194, "Spinneret", "For make Kevlar Fiber", o));
ItemList.IndustrialApiary_Upgrade_Frame.set(addItem(tLastID = 199, "Upgrade Frame", "Crafting component", o));
- ItemList.IndustrialApiary_Upgrade_Acceleration_1.set(addItem(
- tLastID = 200,
- "Acceleration Upgrade x2",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 2x acceleration level/n * Energy Consumption +1 AMP LV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_2.set(addItem(
- tLastID = 201,
- "Acceleration Upgrade x4",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 4x acceleration level/n * Energy Consumption +1 AMP MV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_3.set(addItem(
- tLastID = 202,
- "Acceleration Upgrade x8",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 8x acceleration level/n * Energy Consumption +1 AMP HV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_4.set(addItem(
- tLastID = 203,
- "Acceleration Upgrade x16",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 16x acceleration level/n * Energy Consumption +1 AMP EV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_5.set(addItem(
- tLastID = 204,
- "Acceleration Upgrade x32",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 32x acceleration level/n * Energy Consumption +1 AMP IV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_6.set(addItem(
- tLastID = 205,
- "Acceleration Upgrade x64",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 64x acceleration level/n * Energy Consumption +1 AMP LuV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_7.set(addItem(
- tLastID = 206,
- "Acceleration Upgrade x128",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 128x acceleration level/n * Energy Consumption +1 AMP ZPM",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_8.set(addItem(
- tLastID = 207,
- "Acceleration Upgrade x256",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 256x acceleration level/n * Energy Consumption +1 AMP UV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_Acceleration_8_Upgraded.set(addItem(
- tLastID = 208,
- "Upgraded Acceleration Upgrade x256",
- "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 256x acceleration level/n * Will also grant 8x production upgrade/n * Energy Consumption +1 AMP UV",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_PRODUCTION.set(addItem(
- tLastID = 209,
- "Production Upgrade",
- "Production upgrade for Industrial Apiary/n Maximum Installed: 8/n Increases production modifier by 0.25/n Energy Consumption +40%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_PLAINS.set(addItem(
- tLastID = 210,
- "Plains Emulation Upgrade",
- "Plains emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Plains/n * Energy Consumption +40%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_LIGHT.set(addItem(
- tLastID = 211,
- "Light Upgrade",
- "Light upgrade for Industrial Apiary/n Maximum Installed: 1/n * Internal Lighting/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_FLOWERING.set(addItem(
- tLastID = 212,
- "Flowering Upgrade",
- "Flowering upgrade for Industrial Apiary/n Maximum Installed: 8/n * Flowering and Pollination +20%/n * Energy Consumption +10%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_WINTER.set(addItem(
- tLastID = 213,
- "Winter Emulation Upgrade",
- "Winter emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Taiga/n * Energy Consumption +50%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_DRYER.set(addItem(
- tLastID = 214,
- "Dryer Upgrade",
- "Dryer upgrade for Industrial Apiary/n Maximum Installed: 8/n * Humidity -25%/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_AUTOMATION.set(addItem(
- tLastID = 215,
- "Automation Upgrade",
- "Automation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Automation/n * Energy Consumption +10%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_HUMIDIFIER.set(addItem(
- tLastID = 216,
- "Humidifier Upgrade",
- "Humidifier upgrade for Industrial Apiary/n Maximum Installed: 8/n * Humidity +25%/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_HELL.set(addItem(
- tLastID = 217,
- "HELL Emulation Upgrade",
- "HELL emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: HELL/n * Energy Consumption +50%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_POLLEN.set(addItem(
- tLastID = 218,
- "Pollen Scrubber Upgrade",
- "Pollen scrubber upgrade for Industrial Apiary/n Maximum Installed: 1/n * Flowering and Pollination -100%/n * Energy Consumption +30%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_DESERT.set(addItem(
- tLastID = 219,
- "Desert Emulation Upgrade",
- "Desert emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Desert/n * Energy Consumption +20%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_COOLER.set(addItem(
- tLastID = 220,
- "Cooler Upgrade",
- "Cooler upgrade for Industrial Apiary/n Maximum Installed: 8/n * Temperature -25%/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_LIFESPAN.set(addItem(
- tLastID = 221,
- "Lifespan Upgrade",
- "Lifespan upgrade for Industrial Apiary/n Maximum Installed: 4/n * Lifespan -33%/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_SEAL.set(addItem(
- tLastID = 222,
- "Seal Upgrade",
- "Seal upgrade for Industrial Apiary/n Maximum Installed: 1/n * Rain Protection/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_STABILIZER.set(addItem(
- tLastID = 223,
- "Genetic Stabilizer Upgrade",
- "Genetic stabilizer upgrade for Industrial Apiary/n Maximum Installed: 1/n * Genetic Decay -100%/n * Energy Consumption +150%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_JUNGLE.set(addItem(
- tLastID = 224,
- "Jungle Emulation Upgrade",
- "Jungle emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Jungle/n * Energy Consumption +20%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_TERRITORY.set(addItem(
- tLastID = 225,
- "Territory Upgrade",
- "Territory upgrade for Industrial Apiary/n Maximum Installed: 4/n * Territory +50%/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_OCEAN.set(addItem(
- tLastID = 226,
- "Ocean Emulation Upgrade",
- "Ocean emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Ocean/n * Energy Consumption +20%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_SKY.set(addItem(
- tLastID = 227,
- "Open Sky Upgrade",
- "Open sky upgrade for Industrial Apiary/n Maximum Installed: 1/n * Open Sky Simulation/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_HEATER.set(addItem(
- tLastID = 228,
- "Heater Upgrade",
- "Heater upgrade for Industrial Apiary/n Maximum Installed: 8/n * Temperature +25%/n * Energy Consumption +5%",
- OrePrefixes.apiaryUpgrade.name()));
- ItemList.IndustrialApiary_Upgrade_SIEVE.set(addItem(
- tLastID = 229,
- "Sieve Upgrade",
- "Sieve upgrade for Industrial Apiary/n Maximum Installed: 1/n * Pollen Collection/n * Energy Consumption +25%",
- OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_1.set(
+ addItem(
+ tLastID = 200,
+ "Acceleration Upgrade x2",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 2x acceleration level/n * Energy Consumption +1 AMP LV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_2.set(
+ addItem(
+ tLastID = 201,
+ "Acceleration Upgrade x4",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 4x acceleration level/n * Energy Consumption +1 AMP MV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_3.set(
+ addItem(
+ tLastID = 202,
+ "Acceleration Upgrade x8",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 8x acceleration level/n * Energy Consumption +1 AMP HV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_4.set(
+ addItem(
+ tLastID = 203,
+ "Acceleration Upgrade x16",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 16x acceleration level/n * Energy Consumption +1 AMP EV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_5.set(
+ addItem(
+ tLastID = 204,
+ "Acceleration Upgrade x32",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 32x acceleration level/n * Energy Consumption +1 AMP IV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_6.set(
+ addItem(
+ tLastID = 205,
+ "Acceleration Upgrade x64",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 64x acceleration level/n * Energy Consumption +1 AMP LuV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_7.set(
+ addItem(
+ tLastID = 206,
+ "Acceleration Upgrade x128",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 128x acceleration level/n * Energy Consumption +1 AMP ZPM",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_8.set(
+ addItem(
+ tLastID = 207,
+ "Acceleration Upgrade x256",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 256x acceleration level/n * Energy Consumption +1 AMP UV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_Acceleration_8_Upgraded.set(
+ addItem(
+ tLastID = 208,
+ "Upgraded Acceleration Upgrade x256",
+ "Acceleration upgrade for Industrial Apiary/n Maximum Installed: 1/n * Unlocks 256x acceleration level/n * Will also grant 8x production upgrade/n * Energy Consumption +1 AMP UV",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_PRODUCTION.set(
+ addItem(
+ tLastID = 209,
+ "Production Upgrade",
+ "Production upgrade for Industrial Apiary/n Maximum Installed: 8/n Increases production modifier by 0.25/n Energy Consumption +40%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_PLAINS.set(
+ addItem(
+ tLastID = 210,
+ "Plains Emulation Upgrade",
+ "Plains emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Plains/n * Energy Consumption +40%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_LIGHT.set(
+ addItem(
+ tLastID = 211,
+ "Light Upgrade",
+ "Light upgrade for Industrial Apiary/n Maximum Installed: 1/n * Internal Lighting/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_FLOWERING.set(
+ addItem(
+ tLastID = 212,
+ "Flowering Upgrade",
+ "Flowering upgrade for Industrial Apiary/n Maximum Installed: 8/n * Flowering and Pollination +20%/n * Energy Consumption +10%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_WINTER.set(
+ addItem(
+ tLastID = 213,
+ "Winter Emulation Upgrade",
+ "Winter emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Taiga/n * Energy Consumption +50%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_DRYER.set(
+ addItem(
+ tLastID = 214,
+ "Dryer Upgrade",
+ "Dryer upgrade for Industrial Apiary/n Maximum Installed: 8/n * Humidity -25%/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_AUTOMATION.set(
+ addItem(
+ tLastID = 215,
+ "Automation Upgrade",
+ "Automation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Automation/n * Energy Consumption +10%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_HUMIDIFIER.set(
+ addItem(
+ tLastID = 216,
+ "Humidifier Upgrade",
+ "Humidifier upgrade for Industrial Apiary/n Maximum Installed: 8/n * Humidity +25%/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_HELL.set(
+ addItem(
+ tLastID = 217,
+ "HELL Emulation Upgrade",
+ "HELL emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: HELL/n * Energy Consumption +50%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_POLLEN.set(
+ addItem(
+ tLastID = 218,
+ "Pollen Scrubber Upgrade",
+ "Pollen scrubber upgrade for Industrial Apiary/n Maximum Installed: 1/n * Flowering and Pollination -100%/n * Energy Consumption +30%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_DESERT.set(
+ addItem(
+ tLastID = 219,
+ "Desert Emulation Upgrade",
+ "Desert emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Desert/n * Energy Consumption +20%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_COOLER.set(
+ addItem(
+ tLastID = 220,
+ "Cooler Upgrade",
+ "Cooler upgrade for Industrial Apiary/n Maximum Installed: 8/n * Temperature -25%/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_LIFESPAN.set(
+ addItem(
+ tLastID = 221,
+ "Lifespan Upgrade",
+ "Lifespan upgrade for Industrial Apiary/n Maximum Installed: 4/n * Lifespan -33%/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_SEAL.set(
+ addItem(
+ tLastID = 222,
+ "Seal Upgrade",
+ "Seal upgrade for Industrial Apiary/n Maximum Installed: 1/n * Rain Protection/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_STABILIZER.set(
+ addItem(
+ tLastID = 223,
+ "Genetic Stabilizer Upgrade",
+ "Genetic stabilizer upgrade for Industrial Apiary/n Maximum Installed: 1/n * Genetic Decay -100%/n * Energy Consumption +150%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_JUNGLE.set(
+ addItem(
+ tLastID = 224,
+ "Jungle Emulation Upgrade",
+ "Jungle emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Jungle/n * Energy Consumption +20%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_TERRITORY.set(
+ addItem(
+ tLastID = 225,
+ "Territory Upgrade",
+ "Territory upgrade for Industrial Apiary/n Maximum Installed: 4/n * Territory +50%/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_OCEAN.set(
+ addItem(
+ tLastID = 226,
+ "Ocean Emulation Upgrade",
+ "Ocean emulation upgrade for Industrial Apiary/n Maximum Installed: 1/n * Biome Override: Ocean/n * Energy Consumption +20%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_SKY.set(
+ addItem(
+ tLastID = 227,
+ "Open Sky Upgrade",
+ "Open sky upgrade for Industrial Apiary/n Maximum Installed: 1/n * Open Sky Simulation/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_HEATER.set(
+ addItem(
+ tLastID = 228,
+ "Heater Upgrade",
+ "Heater upgrade for Industrial Apiary/n Maximum Installed: 8/n * Temperature +25%/n * Energy Consumption +5%",
+ OrePrefixes.apiaryUpgrade.name()));
+ ItemList.IndustrialApiary_Upgrade_SIEVE.set(
+ addItem(
+ tLastID = 229,
+ "Sieve Upgrade",
+ "Sieve upgrade for Industrial Apiary/n Maximum Installed: 1/n * Pollen Collection/n * Energy Consumption +25%",
+ OrePrefixes.apiaryUpgrade.name()));
OrePrefixes.apiaryUpgrade.add(ItemList.IndustrialApiary_Upgrade_Acceleration_1.get(1L));
OrePrefixes.apiaryUpgrade.add(ItemList.IndustrialApiary_Upgrade_Acceleration_2.get(1L));
@@ -809,113 +886,160 @@ public class GT_MetaGenerated_Item_03 extends GT_MetaGenerated_Item_X32 {
OrePrefixes.apiaryUpgrade.add(ItemList.IndustrialApiary_Upgrade_HEATER.get(1L));
OrePrefixes.apiaryUpgrade.add(ItemList.IndustrialApiary_Upgrade_SIEVE.get(1L));
- ItemList.NuclearStar.set(addItem(
- 230,
- "Nuclear Star",
- "BY THE POWERS OF NAUGHTINESS, I COMMAND THIS PARTICULAR STAR, TO BE REALLY, REALLY HOT",
- SubTag.NO_UNIFICATION));
+ ItemList.NuclearStar.set(
+ addItem(
+ 230,
+ "Nuclear Star",
+ "BY THE POWERS OF NAUGHTINESS, I COMMAND THIS PARTICULAR STAR, TO BE REALLY, REALLY HOT",
+ SubTag.NO_UNIFICATION));
- ItemList.Optical_Cpu_Containment_Housing.set(
- addItem(tLastID = 727, "Optical CPU Containment Housing", "CPU Housing", o));
+ ItemList.Optical_Cpu_Containment_Housing
+ .set(addItem(tLastID = 727, "Optical CPU Containment Housing", "CPU Housing", o));
ItemList.Optically_Perfected_CPU.set(addItem(tLastID = 726, "Optically Perfected CPU", "Perfected CPU!", o));
- ItemList.Optically_Compatible_Memory.set(
- addItem(tLastID = 725, "Optically Compatible Memory", "Its in the name!", o));
+ ItemList.Optically_Compatible_Memory
+ .set(addItem(tLastID = 725, "Optically Compatible Memory", "Its in the name!", o));
int whiteDwarfIDs = 729;
- ItemList.White_Dwarf_Shape_Extruder_Plate.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Plate)", "Ultra Strong Stellar Shape for making Plates"));
- ItemList.White_Dwarf_Shape_Extruder_Rod.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Rod)", "Ultra Strong Stellar Shape for making Rods"));
- ItemList.White_Dwarf_Shape_Extruder_Bolt.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Bolt)", "Ultra Strong Stellar Shape for making Bolts"));
- ItemList.White_Dwarf_Shape_Extruder_Ring.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Ring)", "Ultra Strong Stellar Shape for making Rings"));
- ItemList.White_Dwarf_Shape_Extruder_Cell.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Cell)", "Ultra Strong Stellar Shape for making Cells"));
- ItemList.White_Dwarf_Shape_Extruder_Ingot.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Ingot)",
- "Ultra Strong Stellar Shape for, wait, can't we just use a Furnace?"));
- ItemList.White_Dwarf_Shape_Extruder_Wire.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Wire)", "Ultra Strong Stellar Shape for making Wires"));
- ItemList.White_Dwarf_Shape_Extruder_Casing.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Casing)",
- "Ultra Strong Stellar Shape for making Item Casings"));
- ItemList.White_Dwarf_Shape_Extruder_Pipe_Tiny.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Tiny Pipe)",
- "Ultra Strong Stellar Shape for making tiny Pipes"));
- ItemList.White_Dwarf_Shape_Extruder_Pipe_Small.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Small Pipe)",
- "Ultra Strong Stellar Shape for making small Pipes"));
- ItemList.White_Dwarf_Shape_Extruder_Pipe_Medium.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Normal Pipe)",
- "Ultra Strong Stellar Shape for making Pipes"));
- ItemList.White_Dwarf_Shape_Extruder_Pipe_Large.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Large Pipe)",
- "Ultra Strong Stellar Shape for making large Pipes"));
- ItemList.White_Dwarf_Shape_Extruder_Pipe_Huge.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Huge Pipe)",
- "Ultra Strong Stellar Shape for making full Block Pipes"));
- ItemList.White_Dwarf_Shape_Extruder_Block.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Block)", "Ultra Strong Stellar Shape for making Blocks"));
- ItemList.White_Dwarf_Shape_Extruder_Sword.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Sword Blade)",
- "Ultra Strong Stellar Shape for making Swords"));
- ItemList.White_Dwarf_Shape_Extruder_Pickaxe.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Pickaxe Head)",
- "Ultra Strong Stellar Shape for making Pickaxes"));
- ItemList.White_Dwarf_Shape_Extruder_Shovel.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Shovel Head)",
- "Ultra Strong Stellar Shape for making Shovels"));
- ItemList.White_Dwarf_Shape_Extruder_Axe.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Axe Head)",
- "Ultra Strong Stellar Shape for making Axes"));
- ItemList.White_Dwarf_Shape_Extruder_Hoe.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Hoe Head)",
- "Ultra Strong Stellar Shape for making Hoes"));
- ItemList.White_Dwarf_Shape_Extruder_Hammer.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Hammer Head)",
- "Ultra Strong Stellar Shape for making Hammers"));
- ItemList.White_Dwarf_Shape_Extruder_File.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (File Head)",
- "Ultra Strong Stellar Shape for making Files"));
- ItemList.White_Dwarf_Shape_Extruder_Saw.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Saw Blade)",
- "Ultra Strong Stellar Shape for making Saws"));
- ItemList.White_Dwarf_Shape_Extruder_Gear.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Gear)", "Ultra Strong Stellar Shape for making Gears"));
- ItemList.White_Dwarf_Shape_Extruder_Bottle.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Bottle)",
- "Ultra Strong Stellar Shape for making Bottles"));
- ItemList.White_Dwarf_Shape_Extruder_Rotor.set(addItem(
- whiteDwarfIDs++, "White Dwarf Extruder Shape (Rotor)", "Ultra Strong Stellar Shape for a Rotor"));
- ItemList.White_Dwarf_Shape_Extruder_Small_Gear.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Small Gear)",
- "Ultra Strong Stellar Shape for a Small Gear"));
- ItemList.White_Dwarf_Shape_Extruder_Turbine_Blade.set(addItem(
- whiteDwarfIDs++,
- "White Dwarf Extruder Shape (Turbine Blade)",
- "Ultra Strong Stellar Extruder Shape for a Turbine Blade"));
- ItemList.White_Dwarf_Shape_Extruder_ToolHeadDrill.set(addItem(
- whiteDwarfIDs,
- "White Dwarf Extruder Shape (Drill Head)",
- "White Dwarf Extruder Shape for a Drill Head"));
+ ItemList.White_Dwarf_Shape_Extruder_Plate.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Plate)",
+ "Ultra Strong Stellar Shape for making Plates"));
+ ItemList.White_Dwarf_Shape_Extruder_Rod.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Rod)",
+ "Ultra Strong Stellar Shape for making Rods"));
+ ItemList.White_Dwarf_Shape_Extruder_Bolt.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Bolt)",
+ "Ultra Strong Stellar Shape for making Bolts"));
+ ItemList.White_Dwarf_Shape_Extruder_Ring.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Ring)",
+ "Ultra Strong Stellar Shape for making Rings"));
+ ItemList.White_Dwarf_Shape_Extruder_Cell.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Cell)",
+ "Ultra Strong Stellar Shape for making Cells"));
+ ItemList.White_Dwarf_Shape_Extruder_Ingot.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Ingot)",
+ "Ultra Strong Stellar Shape for, wait, can't we just use a Furnace?"));
+ ItemList.White_Dwarf_Shape_Extruder_Wire.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Wire)",
+ "Ultra Strong Stellar Shape for making Wires"));
+ ItemList.White_Dwarf_Shape_Extruder_Casing.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Casing)",
+ "Ultra Strong Stellar Shape for making Item Casings"));
+ ItemList.White_Dwarf_Shape_Extruder_Pipe_Tiny.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Tiny Pipe)",
+ "Ultra Strong Stellar Shape for making tiny Pipes"));
+ ItemList.White_Dwarf_Shape_Extruder_Pipe_Small.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Small Pipe)",
+ "Ultra Strong Stellar Shape for making small Pipes"));
+ ItemList.White_Dwarf_Shape_Extruder_Pipe_Medium.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Normal Pipe)",
+ "Ultra Strong Stellar Shape for making Pipes"));
+ ItemList.White_Dwarf_Shape_Extruder_Pipe_Large.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Large Pipe)",
+ "Ultra Strong Stellar Shape for making large Pipes"));
+ ItemList.White_Dwarf_Shape_Extruder_Pipe_Huge.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Huge Pipe)",
+ "Ultra Strong Stellar Shape for making full Block Pipes"));
+ ItemList.White_Dwarf_Shape_Extruder_Block.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Block)",
+ "Ultra Strong Stellar Shape for making Blocks"));
+ ItemList.White_Dwarf_Shape_Extruder_Sword.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Sword Blade)",
+ "Ultra Strong Stellar Shape for making Swords"));
+ ItemList.White_Dwarf_Shape_Extruder_Pickaxe.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Pickaxe Head)",
+ "Ultra Strong Stellar Shape for making Pickaxes"));
+ ItemList.White_Dwarf_Shape_Extruder_Shovel.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Shovel Head)",
+ "Ultra Strong Stellar Shape for making Shovels"));
+ ItemList.White_Dwarf_Shape_Extruder_Axe.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Axe Head)",
+ "Ultra Strong Stellar Shape for making Axes"));
+ ItemList.White_Dwarf_Shape_Extruder_Hoe.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Hoe Head)",
+ "Ultra Strong Stellar Shape for making Hoes"));
+ ItemList.White_Dwarf_Shape_Extruder_Hammer.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Hammer Head)",
+ "Ultra Strong Stellar Shape for making Hammers"));
+ ItemList.White_Dwarf_Shape_Extruder_File.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (File Head)",
+ "Ultra Strong Stellar Shape for making Files"));
+ ItemList.White_Dwarf_Shape_Extruder_Saw.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Saw Blade)",
+ "Ultra Strong Stellar Shape for making Saws"));
+ ItemList.White_Dwarf_Shape_Extruder_Gear.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Gear)",
+ "Ultra Strong Stellar Shape for making Gears"));
+ ItemList.White_Dwarf_Shape_Extruder_Bottle.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Bottle)",
+ "Ultra Strong Stellar Shape for making Bottles"));
+ ItemList.White_Dwarf_Shape_Extruder_Rotor.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Rotor)",
+ "Ultra Strong Stellar Shape for a Rotor"));
+ ItemList.White_Dwarf_Shape_Extruder_Small_Gear.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Small Gear)",
+ "Ultra Strong Stellar Shape for a Small Gear"));
+ ItemList.White_Dwarf_Shape_Extruder_Turbine_Blade.set(
+ addItem(
+ whiteDwarfIDs++,
+ "White Dwarf Extruder Shape (Turbine Blade)",
+ "Ultra Strong Stellar Extruder Shape for a Turbine Blade"));
+ ItemList.White_Dwarf_Shape_Extruder_ToolHeadDrill.set(
+ addItem(
+ whiteDwarfIDs,
+ "White Dwarf Extruder Shape (Drill Head)",
+ "White Dwarf Extruder Shape for a Drill Head"));
}
@Override
diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_98.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_98.java
index b7ec97c80f..7e50bd4556 100644
--- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_98.java
+++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_98.java
@@ -1,24 +1,14 @@
package gregtech.common.items;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_OreDictUnificator;
-import gregtech.api.util.GT_Util;
-import gregtech.api.util.GT_Utility;
import java.util.Arrays;
import java.util.EnumMap;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Objects;
+
import javax.annotation.Nullable;
+
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
@@ -28,20 +18,34 @@ import net.minecraftforge.fluids.FluidContainerRegistry;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.api.util.GT_Util;
+import gregtech.api.util.GT_Utility;
+
/** This class holds cells for non-GT fluids. */
public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
+
public static GT_MetaGenerated_Item_98 INSTANCE;
/**
* Registered fluids.
*
- * <p>When adding a fluid, don't forget to make sure that GregTech loads after the mod that adds
- * that fluid!
+ * <p>
+ * When adding a fluid, don't forget to make sure that GregTech loads after the mod that adds that fluid!
*
- * <p>In order to avoid breaking existing worlds, fluids must not have their IDs changed! The
- * only safe modification that can be made to this enum is adding new fluids, or removing
- * existing fluids. When removing fluids, maybe leave a comment mentioning the old ID, so that
- * we don't re-use it for a new fluid.
+ * <p>
+ * In order to avoid breaking existing worlds, fluids must not have their IDs changed! The only safe modification
+ * that can be made to this enum is adding new fluids, or removing existing fluids. When removing fluids, maybe
+ * leave a comment mentioning the old ID, so that we don't re-use it for a new fluid.
*/
public enum FluidCell {
// Next unused ID: 22
@@ -84,8 +88,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
LIQUID_ENDER(3, "ender", CellType.REGULAR),
// Hardcore Ender Expansion
- ENDER_GOO(4, "endergoo", CellType.REGULAR),
- ;
+ ENDER_GOO(4, "endergoo", CellType.REGULAR),;
private final int mId;
/** This is the Forge internal fluid name. */
@@ -117,8 +120,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
/**
* Get a copy of this stack with stack size 1.
*
- * Always returns non-null stack even if the fluid referenced doesn't exist,
- * so don't assume it's always valid.
+ * Always returns non-null stack even if the fluid referenced doesn't exist, so don't assume it's always valid.
*/
public ItemStack get() {
trySetStack();
@@ -128,8 +130,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
/**
* Get a copy of this cell WITHOUT copy.
*
- * Always returns non-null stack even if the fluid referenced doesn't exist,
- * so don't assume it's always valid.
+ * Always returns non-null stack even if the fluid referenced doesn't exist, so don't assume it's always valid.
*
* Use with caution.
*/
@@ -141,8 +142,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
/**
* Get a copy of this cell with specified stack size.
*
- * Always returns non-null stack even if the fluid referenced doesn't exist,
- * so don't assume it's always valid.
+ * Always returns non-null stack even if the fluid referenced doesn't exist, so don't assume it's always valid.
*/
public ItemStack get(int aStackSize) {
trySetStack();
@@ -158,6 +158,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
/** Cell type specifies the cell capacity, appearance, and item name format. */
private enum CellType {
+
REGULAR(1_000, OrePrefixes.cell),
SMALL(144, OrePrefixes.cell),
MOLTEN(144, OrePrefixes.cellMolten),
@@ -174,6 +175,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
/** Struct class holding data that we need to properly handle a registered fluid cell item. */
private static class RegisteredFluidData {
+
private final Fluid fluid;
private final short[] rgba;
private final IIconContainer iconContainer;
@@ -188,7 +190,8 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
/**
* Map of ID to registered fluid data.
*
- * <p>Only contains IDs that were successfully registered.
+ * <p>
+ * Only contains IDs that were successfully registered.
*/
private final Map<Integer, RegisteredFluidData> registeredFluidDataMap;
@@ -205,8 +208,8 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
}
/**
- * Loading needs to happen after the fluids we need have been registered, which means during post-load.
- * However, cell icons seem to be deleted some time between load and post-load, so we must pre-cache them.
+ * Loading needs to happen after the fluids we need have been registered, which means during post-load. However,
+ * cell icons seem to be deleted some time between load and post-load, so we must pre-cache them.
*/
public static synchronized void preInit() {
if (INSTANCE == null) INSTANCE = new GT_MetaGenerated_Item_98();
@@ -253,8 +256,9 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
// The fluid is not guaranteed to exist.
// These fluids are non-GT fluids, so the mod may not be present.
if (isStackAlreadySet) {
- throw new RuntimeException("Cell item for fluid " + fluidName
- + " has already been created, but the fluid doesn't exist during postload");
+ throw new RuntimeException(
+ "Cell item for fluid " + fluidName
+ + " has already been created, but the fluid doesn't exist during postload");
} else {
// fluid doesn't exist and this item has not been referenced
return;
@@ -269,8 +273,7 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
GT_LanguageManager.addStringLocalization(
getUnlocalizedName(aCell.mStack) + ".name",
- cellType.prefix.mLocalizedMaterialPre
- + fluid.getLocalizedName(fluidStack)
+ cellType.prefix.mLocalizedMaterialPre + fluid.getLocalizedName(fluidStack)
+ cellType.prefix.mLocalizedMaterialPost);
int color = fluid.getColor();
@@ -310,11 +313,8 @@ public class GT_MetaGenerated_Item_98 extends GT_MetaGenerated_Item {
@Override
@SideOnly(Side.CLIENT)
public void getSubItems(Item aItem, CreativeTabs aCreativeTab, List aList) {
- Arrays.stream(FluidCell.values())
- .filter(fluid -> FluidRegistry.getFluid(fluid.getFluidName()) != null)
- .map(FluidCell::get)
- .filter(Objects::nonNull)
- .forEach(aList::add);
+ Arrays.stream(FluidCell.values()).filter(fluid -> FluidRegistry.getFluid(fluid.getFluidName()) != null)
+ .map(FluidCell::get).filter(Objects::nonNull).forEach(aList::add);
}
@Override
diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_99.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_99.java
index fb435a5b55..51d8405107 100644
--- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_99.java
+++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_99.java
@@ -3,7 +3,16 @@ package gregtech.common.items;
import static gregtech.api.enums.GT_Values.M;
import static gregtech.api.enums.OrePrefixes.cellMolten;
+import java.util.BitSet;
+import java.util.List;
+
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+
import com.google.common.collect.ImmutableList;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.GregTech_API;
@@ -14,20 +23,16 @@ import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Item;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_OreDictUnificator;
-import java.util.BitSet;
-import java.util.List;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
public class GT_MetaGenerated_Item_99 extends GT_MetaGenerated_Item {
+
public static GT_MetaGenerated_Item_99 INSTANCE;
/**
* Ore prefixes appear in this list in the order in which they will be assigned ID blocks.
*
- * <p>In order to avoid breaking existing worlds, the entries in this list must not be re-ordered! The only safe
+ * <p>
+ * In order to avoid breaking existing worlds, the entries in this list must not be re-ordered! The only safe
* modification that can be made to this list is adding new entries to the end.
*/
private static final ImmutableList<OrePrefixes> CRACKED_CELL_TYPES = ImmutableList.of(
@@ -41,9 +46,8 @@ public class GT_MetaGenerated_Item_99 extends GT_MetaGenerated_Item {
private static final int NUM_CRACKED_CELL_TYPES = CRACKED_CELL_TYPES.size();
/**
- * Assignment of metadata IDs:
- * 0 - 999: Molten cells
- * 10_000 - 15_999: Cracked fluid cells (# IDs used is NUM_CRACKED_CELL_TYPES * 1_000; update this if you add any)
+ * Assignment of metadata IDs: 0 - 999: Molten cells 10_000 - 15_999: Cracked fluid cells (# IDs used is
+ * NUM_CRACKED_CELL_TYPES * 1_000; update this if you add any)
*/
private BitSet enabled = new BitSet();
@@ -57,12 +61,10 @@ public class GT_MetaGenerated_Item_99 extends GT_MetaGenerated_Item {
continue;
}
- if ((tMaterial.contains(SubTag.SMELTING_TO_FLUID))
- && (!tMaterial.contains(SubTag.NO_SMELTING))
+ if ((tMaterial.contains(SubTag.SMELTING_TO_FLUID)) && (!tMaterial.contains(SubTag.NO_SMELTING))
&& !tMaterial.contains(SubTag.SMELTING_TO_GEM)) {
registerMolten(tMaterial, tMaterial.mMetaItemSubID);
- if (tMaterial.mSmeltInto != tMaterial
- && tMaterial.mSmeltInto.mMetaItemSubID >= 0
+ if (tMaterial.mSmeltInto != tMaterial && tMaterial.mSmeltInto.mMetaItemSubID >= 0
&& tMaterial.mSmeltInto.mMetaItemSubID < 1_000) {
registerMolten(tMaterial.mSmeltInto, tMaterial.mSmeltInto.mMetaItemSubID);
}
@@ -83,9 +85,11 @@ public class GT_MetaGenerated_Item_99 extends GT_MetaGenerated_Item {
enabled.set(i);
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName(tStack) + ".name", cellMolten.getDefaultLocalNameFormatForItem(tMaterial));
+ getUnlocalizedName(tStack) + ".name",
+ cellMolten.getDefaultLocalNameFormatForItem(tMaterial));
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName(tStack) + ".tooltip", tMaterial.getToolTip(cellMolten.mMaterialAmount / M));
+ getUnlocalizedName(tStack) + ".tooltip",
+ tMaterial.getToolTip(cellMolten.mMaterialAmount / M));
if (cellMolten.mIsUnificatable) {
GT_OreDictUnificator.set(cellMolten, tMaterial, tStack);
@@ -101,9 +105,11 @@ public class GT_MetaGenerated_Item_99 extends GT_MetaGenerated_Item {
enabled.set(offset + i);
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName(tStack) + ".name", prefix.getDefaultLocalNameFormatForItem(tMaterial));
+ getUnlocalizedName(tStack) + ".name",
+ prefix.getDefaultLocalNameFormatForItem(tMaterial));
GT_LanguageManager.addStringLocalization(
- getUnlocalizedName(tStack) + ".tooltip", tMaterial.getToolTip(prefix.mMaterialAmount / M));
+ getUnlocalizedName(tStack) + ".tooltip",
+ tMaterial.getToolTip(prefix.mMaterialAmount / M));
if (prefix.mIsUnificatable) {
GT_OreDictUnificator.set(prefix, tMaterial, tStack);
diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Tool_01.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Tool_01.java
index b2fb154339..0ee136d7fb 100644
--- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Tool_01.java
+++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Tool_01.java
@@ -1,5 +1,9 @@
package gregtech.common.items;
+import net.minecraft.init.Blocks;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.*;
import gregtech.api.items.GT_MetaGenerated_Tool;
@@ -7,11 +11,9 @@ import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.common.tools.*;
import gregtech.common.tools.pocket.*;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
public class GT_MetaGenerated_Tool_01 extends GT_MetaGenerated_Tool {
+
public static final short SWORD = 0;
public static final short PICKAXE = 2;
public static final short SHOVEL = 4;
@@ -572,300 +574,211 @@ public class GT_MetaGenerated_Tool_01 extends GT_MetaGenerated_Tool {
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Flint, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" I ", "SIS", "SSS", 'I', new ItemStack(Items.flint, 1), 'S', OrePrefixes.stone});
+ new Object[] { " I ", "SIS", "SSS", 'I', new ItemStack(Items.flint, 1), 'S', OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Bronze, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Bronze), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Bronze), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Iron, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Iron), 'S', OrePrefixes.stone});
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Iron), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Steel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Steel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Steel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.WroughtIron, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.WroughtIron), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.WroughtIron), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.RedSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.RedSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.RedSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.BlueSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlueSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlueSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.BlackSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlackSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlackSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.DamascusSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.DamascusSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.DamascusSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Thaumium, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Thaumium), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Thaumium), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.Wood, Materials.Wood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.plank.get(Materials.Wood),
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.plank.get(Materials.Wood), 'S',
+ OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.Plastic, Materials.Plastic, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.Plastic),
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.Plastic), 'S',
+ OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.Aluminium, Materials.Aluminium, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.Aluminium),
- 'S',
- OrePrefixes.stick.get(Materials.Aluminium)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.Aluminium), 'S',
+ OrePrefixes.stick.get(Materials.Aluminium) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.StainlessSteel, Materials.StainlessSteel, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.StainlessSteel),
- 'S',
- OrePrefixes.stick.get(Materials.StainlessSteel)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.StainlessSteel), 'S',
+ OrePrefixes.stick.get(Materials.StainlessSteel) });
if (!GregTech_API.sSpecialFile.get(ConfigCategories.general, "DisableFlintTools", false)) {
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(SWORD, 1, Materials.Flint, Materials.Wood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- "F", "F", "S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F', new ItemStack(Items.flint, 1)
- });
+ new Object[] { "F", "F", "S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F',
+ new ItemStack(Items.flint, 1) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(PICKAXE, 1, Materials.Flint, Materials.Wood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- "FFF",
- " S ",
- " S ",
- 'S',
- OrePrefixes.stick.get(Materials.Wood),
- 'F',
- new ItemStack(Items.flint, 1)
- });
+ new Object[] { "FFF", " S ", " S ", 'S', OrePrefixes.stick.get(Materials.Wood), 'F',
+ new ItemStack(Items.flint, 1) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(SHOVEL, 1, Materials.Flint, Materials.Wood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- "F", "S", "S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F', new ItemStack(Items.flint, 1)
- });
+ new Object[] { "F", "S", "S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F',
+ new ItemStack(Items.flint, 1) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(AXE, 1, Materials.Flint, Materials.Wood, null),
GT_ModHandler.RecipeBits.MIRRORED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- "FF", "FS", " S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F', new ItemStack(Items.flint, 1)
- });
+ new Object[] { "FF", "FS", " S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F',
+ new ItemStack(Items.flint, 1) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(HOE, 1, Materials.Flint, Materials.Wood, null),
GT_ModHandler.RecipeBits.MIRRORED | GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- "FF", " S", " S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F', new ItemStack(Items.flint, 1)
- });
+ new Object[] { "FF", " S", " S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F',
+ new ItemStack(Items.flint, 1) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(KNIFE, 1, Materials.Flint, Materials.Wood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- "F", "S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F', new ItemStack(Items.flint, 1)
- });
+ new Object[] { "F", "S", 'S', OrePrefixes.stick.get(Materials.Wood), 'F',
+ new ItemStack(Items.flint, 1) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Flint, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {" I ", "SIS", "SSS", 'I', new ItemStack(Items.flint, 1), 'S', OrePrefixes.stone});
+ new Object[] { " I ", "SIS", "SSS", 'I', new ItemStack(Items.flint, 1), 'S', OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Bronze, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Bronze), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Bronze), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Iron, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Iron), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Iron), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Steel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Steel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Steel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.WroughtIron, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.WroughtIron), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.WroughtIron), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.RedSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.RedSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.RedSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.BlueSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlueSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlueSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.BlackSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlackSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.BlackSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.DamascusSteel, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.DamascusSteel), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.DamascusSteel), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(MORTAR, 1, Materials.Thaumium, Materials.Stone, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Thaumium), 'S', OrePrefixes.stone
- });
+ new Object[] { " I ", "SIS", "SSS", 'I', OrePrefixes.ingot.get(Materials.Thaumium), 'S',
+ OrePrefixes.stone });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.Wood, Materials.Wood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.plank.get(Materials.Wood),
- 'S',
- OrePrefixes.stick.get(Materials.Wood)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.plank.get(Materials.Wood), 'S',
+ OrePrefixes.stick.get(Materials.Wood) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.Plastic, Materials.Plastic, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.Plastic),
- 'S',
- OrePrefixes.stick.get(Materials.Plastic)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.Plastic), 'S',
+ OrePrefixes.stick.get(Materials.Plastic) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.Aluminium, Materials.Aluminium, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.Aluminium),
- 'S',
- OrePrefixes.stick.get(Materials.Aluminium)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.Aluminium), 'S',
+ OrePrefixes.stick.get(Materials.Aluminium) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.StainlessSteel, Materials.StainlessSteel, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.StainlessSteel),
- 'S',
- OrePrefixes.stick.get(Materials.StainlessSteel)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.StainlessSteel), 'S',
+ OrePrefixes.stick.get(Materials.StainlessSteel) });
GT_ModHandler.addCraftingRecipe(
INSTANCE.getToolWithStats(ROLLING_PIN, 1, Materials.IronWood, Materials.IronWood, null),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {
- " S",
- " I ",
- "S f",
- 'I',
- OrePrefixes.ingot.get(Materials.IronWood),
- 'S',
- OrePrefixes.stick.get(Materials.IronWood)
- });
+ new Object[] { " S", " I ", "S f", 'I', OrePrefixes.ingot.get(Materials.IronWood), 'S',
+ OrePrefixes.stick.get(Materials.IronWood) });
if (GregTech_API.sRecipeFile.get(ConfigCategories.Tools.mortar, "Coal", true)) {
GT_ModHandler.addShapelessCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Coal, 1L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ToolDictNames.craftingToolMortar, new ItemStack(Items.coal, 1)});
+ new Object[] { ToolDictNames.craftingToolMortar, new ItemStack(Items.coal, 1) });
}
if (GregTech_API.sRecipeFile.get(ConfigCategories.Tools.mortar, "Clay", true)) {
GT_ModHandler.addShapelessCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Clay, 1L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ToolDictNames.craftingToolMortar, new ItemStack(Blocks.clay, 1)});
+ new Object[] { ToolDictNames.craftingToolMortar, new ItemStack(Blocks.clay, 1) });
}
if (GregTech_API.sRecipeFile.get(ConfigCategories.Tools.mortar, "Wheat", true)) {
GT_ModHandler.addShapelessCraftingRecipe(
GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Wheat, 1L),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ToolDictNames.craftingToolMortar, new ItemStack(Items.wheat, 1)});
+ new Object[] { ToolDictNames.craftingToolMortar, new ItemStack(Items.wheat, 1) });
}
if (GregTech_API.sRecipeFile.get(ConfigCategories.Tools.mortar, "Flint", true)) {
GT_ModHandler.addShapelessCraftingRecipe(
new ItemStack(Items.flint, 1),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ToolDictNames.craftingToolMortar, new ItemStack(Blocks.gravel, 1)});
+ new Object[] { ToolDictNames.craftingToolMortar, new ItemStack(Blocks.gravel, 1) });
}
if (GregTech_API.sRecipeFile.get(ConfigCategories.Tools.mortar, "Blaze", true)) {
GT_ModHandler.addShapelessCraftingRecipe(
new ItemStack(Items.blaze_powder, 2),
GT_ModHandler.RecipeBits.NOT_REMOVABLE,
- new Object[] {ToolDictNames.craftingToolMortar, new ItemStack(Items.blaze_rod, 1)});
+ new Object[] { ToolDictNames.craftingToolMortar, new ItemStack(Items.blaze_rod, 1) });
}
}
}
diff --git a/src/main/java/gregtech/common/items/GT_NeutronReflector_Item.java b/src/main/java/gregtech/common/items/GT_NeutronReflector_Item.java
index 5e307694f4..cfcedaa8b6 100644
--- a/src/main/java/gregtech/common/items/GT_NeutronReflector_Item.java
+++ b/src/main/java/gregtech/common/items/GT_NeutronReflector_Item.java
@@ -1,11 +1,13 @@
package gregtech.common.items;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.items.GT_Generic_Item;
import ic2.api.reactor.IReactor;
import ic2.api.reactor.IReactorComponent;
-import net.minecraft.item.ItemStack;
public class GT_NeutronReflector_Item extends GT_Generic_Item implements IReactorComponent {
+
public GT_NeutronReflector_Item(String aUnlocalized, String aEnglish, int aMaxDamage) {
super(aUnlocalized, aEnglish, "Undestructable");
this.setMaxStackSize(64);
@@ -13,15 +15,8 @@ public class GT_NeutronReflector_Item extends GT_Generic_Item implements IReacto
}
@Override
- public boolean acceptUraniumPulse(
- IReactor reactor,
- ItemStack yourStack,
- ItemStack pulsingStack,
- int youX,
- int youY,
- int pulseX,
- int pulseY,
- boolean heatrun) {
+ public boolean acceptUraniumPulse(IReactor reactor, ItemStack yourStack, ItemStack pulsingStack, int youX, int youY,
+ int pulseX, int pulseY, boolean heatrun) {
if (!heatrun) {
((IReactorComponent) pulsingStack.getItem())
.acceptUraniumPulse(reactor, pulsingStack, yourStack, pulseX, pulseY, youX, youY, heatrun);
diff --git a/src/main/java/gregtech/common/items/GT_SensorCard_Item.java b/src/main/java/gregtech/common/items/GT_SensorCard_Item.java
index ba744c216c..fbe8ab9728 100644
--- a/src/main/java/gregtech/common/items/GT_SensorCard_Item.java
+++ b/src/main/java/gregtech/common/items/GT_SensorCard_Item.java
@@ -1,14 +1,10 @@
package gregtech.common.items;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.interfaces.tileentity.IGregTechDeviceInformation;
-import gregtech.api.items.GT_Generic_Item;
-import gregtech.api.util.GT_LanguageManager;
import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;
import java.util.UUID;
+
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
@@ -17,9 +13,16 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.ChunkCoordinates;
import net.minecraft.world.World;
+
import shedar.mods.ic2.nuclearcontrol.api.*;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.interfaces.tileentity.IGregTechDeviceInformation;
+import gregtech.api.items.GT_Generic_Item;
+import gregtech.api.util.GT_LanguageManager;
public class GT_SensorCard_Item extends GT_Generic_Item implements IRemoteSensor, IPanelDataSource {
+
private static final UUID CARD_TYPE = new UUID(0L, 41L);
private int strCount;
@@ -38,8 +41,12 @@ public class GT_SensorCard_Item extends GT_Generic_Item implements IRemoteSensor
aList.add(transItem("014", "Missing Coodinates!"));
} else {
aList.add(transItem("015", "Device at:"));
- aList.add(String.format(
- "x: %d, y: %d, z: %d", tNBT.getInteger("x"), tNBT.getInteger("y"), tNBT.getInteger("z")));
+ aList.add(
+ String.format(
+ "x: %d, y: %d, z: %d",
+ tNBT.getInteger("x"),
+ tNBT.getInteger("y"),
+ tNBT.getInteger("z")));
}
}
}
diff --git a/src/main/java/gregtech/common/items/GT_VolumetricFlask.java b/src/main/java/gregtech/common/items/GT_VolumetricFlask.java
index 5c906152ed..db2efa4d81 100644
--- a/src/main/java/gregtech/common/items/GT_VolumetricFlask.java
+++ b/src/main/java/gregtech/common/items/GT_VolumetricFlask.java
@@ -6,27 +6,9 @@ import static ic2.core.util.LiquidUtil.drainContainerStack;
import static ic2.core.util.LiquidUtil.fillContainerStack;
import static ic2.core.util.LiquidUtil.placeFluid;
-import com.gtnewhorizons.modularui.api.ModularUITextures;
-import com.gtnewhorizons.modularui.api.math.Alignment;
-import com.gtnewhorizons.modularui.api.math.Color;
-import com.gtnewhorizons.modularui.api.math.MathExpression;
-import com.gtnewhorizons.modularui.api.math.Pos2d;
-import com.gtnewhorizons.modularui.api.math.Size;
-import com.gtnewhorizons.modularui.api.screen.IItemWithModularUI;
-import com.gtnewhorizons.modularui.api.screen.ModularWindow;
-import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
-import com.gtnewhorizons.modularui.common.widget.VanillaButtonWidget;
-import com.gtnewhorizons.modularui.common.widget.textfield.BaseTextFieldWidget;
-import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.gui.modularui.GT_UIInfos;
-import gregtech.api.gui.modularui.GT_UITextures;
-import gregtech.api.items.GT_Generic_Item;
-import gregtech.api.util.GT_Utility;
-import ic2.core.util.LiquidUtil;
import java.util.List;
import java.util.function.Function;
+
import net.minecraft.block.Block;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
@@ -49,7 +31,29 @@ import net.minecraftforge.fluids.IFluidBlock;
import net.minecraftforge.fluids.IFluidContainerItem;
import net.minecraftforge.fluids.IFluidHandler;
+import com.gtnewhorizons.modularui.api.ModularUITextures;
+import com.gtnewhorizons.modularui.api.math.Alignment;
+import com.gtnewhorizons.modularui.api.math.Color;
+import com.gtnewhorizons.modularui.api.math.MathExpression;
+import com.gtnewhorizons.modularui.api.math.Pos2d;
+import com.gtnewhorizons.modularui.api.math.Size;
+import com.gtnewhorizons.modularui.api.screen.IItemWithModularUI;
+import com.gtnewhorizons.modularui.api.screen.ModularWindow;
+import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
+import com.gtnewhorizons.modularui.common.widget.VanillaButtonWidget;
+import com.gtnewhorizons.modularui.common.widget.textfield.BaseTextFieldWidget;
+import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
+
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.gui.modularui.GT_UIInfos;
+import gregtech.api.gui.modularui.GT_UITextures;
+import gregtech.api.items.GT_Generic_Item;
+import gregtech.api.util.GT_Utility;
+import ic2.core.util.LiquidUtil;
+
public class GT_VolumetricFlask extends GT_Generic_Item implements IFluidContainerItem, IItemWithModularUI {
+
private final int maxCapacity;
private final String unlocalFlaskName;
@@ -72,17 +76,8 @@ public class GT_VolumetricFlask extends GT_Generic_Item implements IFluidContain
}
@Override
- public boolean onItemUse(
- ItemStack stack,
- EntityPlayer player,
- World world,
- int x,
- int y,
- int z,
- int side,
- float xOffset,
- float yOffset,
- float zOffset) {
+ public boolean onItemUse(ItemStack stack, EntityPlayer player, World world, int x, int y, int z, int side,
+ float xOffset, float yOffset, float zOffset) {
if (player instanceof FakePlayer) {
return false;
}
@@ -333,6 +328,7 @@ public class GT_VolumetricFlask extends GT_Generic_Item implements IFluidContain
builder.setBackground(ModularUITextures.VANILLA_BACKGROUND);
textField = new TextFieldWidget() {
+
@Override
public void onDestroy() {
if (isClient()) return;
@@ -342,15 +338,12 @@ public class GT_VolumetricFlask extends GT_Generic_Item implements IFluidContain
};
textField.setText(
String.valueOf(((GT_VolumetricFlask) getCurrentItem().getItem()).getCapacity(getCurrentItem())));
- builder.widget(textField
- .setNumbers(() -> 1, () -> maxCapacity)
- .setPattern(BaseTextFieldWidget.NATURAL_NUMS)
- .setTextAlignment(Alignment.CenterLeft)
- .setTextColor(Color.WHITE.dark(1))
- .setFocusOnGuiOpen(true)
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD_LIGHT_GRAY.withOffset(-1, -1, 2, 2))
- .setPos(60, 55)
- .setSize(59, 12));
+ builder.widget(
+ textField.setNumbers(() -> 1, () -> maxCapacity).setPattern(BaseTextFieldWidget.NATURAL_NUMS)
+ .setTextAlignment(Alignment.CenterLeft).setTextColor(Color.WHITE.dark(1))
+ .setFocusOnGuiOpen(true)
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD_LIGHT_GRAY.withOffset(-1, -1, 2, 2))
+ .setPos(60, 55).setSize(59, 12));
addChangeAmountButton(builder, "+1", new Pos2d(20, 26), new Size(22, 20), val -> val + 1);
addChangeAmountButton(builder, "+10", new Pos2d(48, 26), new Size(28, 20), val -> val + 10);
@@ -360,34 +353,28 @@ public class GT_VolumetricFlask extends GT_Generic_Item implements IFluidContain
addChangeAmountButton(builder, "-10", new Pos2d(48, 75), new Size(28, 20), val -> val - 10);
addChangeAmountButton(builder, "-100", new Pos2d(82, 75), new Size(32, 20), val -> val - 100);
addChangeAmountButton(builder, "-1000", new Pos2d(120, 75), new Size(38, 20), val -> val - 1000);
- builder.widget(new VanillaButtonWidget()
- .setDisplayString("Accept")
- .setClickableGetter(() -> MathExpression.parseMathExpression(textField.getText()) > 0)
- .setOnClick((clickData, widget) -> {
- if (widget.isClient()) {
- textField.onRemoveFocus();
- } else {
- widget.getWindow().tryClose();
- }
- })
- .setPos(128, 51)
- .setSize(38, 20));
+ builder.widget(
+ new VanillaButtonWidget().setDisplayString("Accept")
+ .setClickableGetter(() -> MathExpression.parseMathExpression(textField.getText()) > 0)
+ .setOnClick((clickData, widget) -> {
+ if (widget.isClient()) {
+ textField.onRemoveFocus();
+ } else {
+ widget.getWindow().tryClose();
+ }
+ }).setPos(128, 51).setSize(38, 20));
return builder.build();
}
- private void addChangeAmountButton(
- ModularWindow.Builder builder, String text, Pos2d pos, Size size, Function<Integer, Integer> function) {
- builder.widget(new VanillaButtonWidget()
- .setDisplayString(text)
- .setOnClick((clickData, widget) -> {
- String currentText = textField.getText();
- int amount = (int) MathExpression.parseMathExpression(currentText, 1);
- amount = Math.min(maxCapacity, Math.max(1, function.apply(amount)));
- textField.setText(String.valueOf(amount));
- })
- .setPos(pos)
- .setSize(size));
+ private void addChangeAmountButton(ModularWindow.Builder builder, String text, Pos2d pos, Size size,
+ Function<Integer, Integer> function) {
+ builder.widget(new VanillaButtonWidget().setDisplayString(text).setOnClick((clickData, widget) -> {
+ String currentText = textField.getText();
+ int amount = (int) MathExpression.parseMathExpression(currentText, 1);
+ amount = Math.min(maxCapacity, Math.max(1, function.apply(amount)));
+ textField.setText(String.valueOf(amount));
+ }).setPos(pos).setSize(size));
}
private ItemStack getCurrentItem() {
diff --git a/src/main/java/gregtech/common/items/ItemComb.java b/src/main/java/gregtech/common/items/ItemComb.java
index d7af661e02..3882b71c98 100644
--- a/src/main/java/gregtech/common/items/ItemComb.java
+++ b/src/main/java/gregtech/common/items/ItemComb.java
@@ -2,8 +2,21 @@ package gregtech.common.items;
import static gregtech.api.enums.GT_Values.*;
+import java.util.Arrays;
+import java.util.List;
+
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.init.Items;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableMap.Builder;
+
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.relauncher.Side;
@@ -19,18 +32,9 @@ import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Utility;
import gregtech.loaders.materialprocessing.ProcessingModSupport;
import gregtech.loaders.misc.GT_Bees;
-import java.util.Arrays;
-import java.util.List;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
public class ItemComb extends Item {
+
@SideOnly(Side.CLIENT)
private IIcon secondIcon;
@@ -98,92 +102,78 @@ public class ItemComb extends Item {
public void initCombsRecipes() {
// Organic
- addProcessGT(CombType.LIGNIE, new Materials[] {Materials.Lignite}, Voltage.LV);
- addProcessGT(CombType.COAL, new Materials[] {Materials.Coal}, Voltage.LV);
+ addProcessGT(CombType.LIGNIE, new Materials[] { Materials.Lignite }, Voltage.LV);
+ addProcessGT(CombType.COAL, new Materials[] { Materials.Coal }, Voltage.LV);
addCentrifugeToItemStack(
CombType.STICKY,
- new ItemStack[] {ItemList.IC2_Resin.get(1), ItemList.IC2_Plantball.get(1), ItemList.FR_Wax.get(1)},
- new int[] {50 * 100, 15 * 100, 50 * 100},
+ new ItemStack[] { ItemList.IC2_Resin.get(1), ItemList.IC2_Plantball.get(1), ItemList.FR_Wax.get(1) },
+ new int[] { 50 * 100, 15 * 100, 50 * 100 },
Voltage.ULV);
- addProcessGT(CombType.OIL, new Materials[] {Materials.Oilsands}, Voltage.LV);
- addProcessGT(CombType.APATITE, new Materials[] {Materials.Apatite}, Voltage.LV);
+ addProcessGT(CombType.OIL, new Materials[] { Materials.Oilsands }, Voltage.LV);
+ addProcessGT(CombType.APATITE, new Materials[] { Materials.Apatite }, Voltage.LV);
addCentrifugeToMaterial(
CombType.ASH,
- new Materials[] {Materials.DarkAsh, Materials.Ash},
- new int[] {50 * 100, 50 * 100},
+ new Materials[] { Materials.DarkAsh, Materials.Ash },
+ new int[] { 50 * 100, 50 * 100 },
new int[] {},
Voltage.ULV,
NI,
50 * 100);
addCentrifugeToItemStack(
CombType.PHOSPHORUS,
- new ItemStack[] {
- Materials.Phosphorus.getDust(3), Materials.TricalciumPhosphate.getDust(2), ItemList.FR_Wax.get(1)
- },
- new int[] {100 * 100, 75 * 100, 100 * 100},
+ new ItemStack[] { Materials.Phosphorus.getDust(3), Materials.TricalciumPhosphate.getDust(2),
+ ItemList.FR_Wax.get(1) },
+ new int[] { 100 * 100, 75 * 100, 100 * 100 },
Voltage.HV);
addCentrifugeToItemStack(
CombType.MICA,
- new ItemStack[] {Materials.Mica.getDust(2), ItemList.FR_Wax.get(1)},
- new int[] {100 * 100, 75 * 100},
+ new ItemStack[] { Materials.Mica.getDust(2), ItemList.FR_Wax.get(1) },
+ new int[] { 100 * 100, 75 * 100 },
Voltage.HV);
if (GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToItemStack(
CombType.LIGNIE,
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Lignite, 1), ItemList.FR_Wax.get(1)
- },
- new int[] {90 * 100, 50 * 100},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Lignite, 1),
+ ItemList.FR_Wax.get(1) },
+ new int[] { 90 * 100, 50 * 100 },
Voltage.ULV);
addCentrifugeToItemStack(
CombType.COAL,
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Coal, 1), ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 50 * 100},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Coal, 1),
+ ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 50 * 100 },
Voltage.ULV);
addCentrifugeToItemStack(
CombType.OIL,
- new ItemStack[] {
- ItemList.Crop_Drop_OilBerry.get(6),
- GT_Bees.drop.getStackForType(DropType.OIL),
- ItemList.FR_Wax.get(1)
- },
- new int[] {100 * 100, 100 * 100, 50 * 100},
+ new ItemStack[] { ItemList.Crop_Drop_OilBerry.get(6), GT_Bees.drop.getStackForType(DropType.OIL),
+ ItemList.FR_Wax.get(1) },
+ new int[] { 100 * 100, 100 * 100, 50 * 100 },
Voltage.ULV);
} else {
addCentrifugeToItemStack(
CombType.LIGNIE,
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Lignite, 1),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Lignite, 1),
- ItemList.FR_Wax.get(1)
- },
- new int[] {90 * 100, 100 * 100, 50 * 100},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Lignite, 1),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Lignite, 1),
+ ItemList.FR_Wax.get(1) },
+ new int[] { 90 * 100, 100 * 100, 50 * 100 },
Voltage.ULV);
addCentrifugeToItemStack(
CombType.COAL,
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Coal, 1),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Coal, 1),
- ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 100 * 100, 50 * 100},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.gem, Materials.Coal, 1),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Coal, 1), ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 100 * 100, 50 * 100 },
Voltage.ULV);
addCentrifugeToItemStack(
CombType.OIL,
- new ItemStack[] {
- ItemList.Crop_Drop_OilBerry.get(6),
- GT_Bees.drop.getStackForType(DropType.OIL),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Oilsands, 1),
- ItemList.FR_Wax.get(1)
- },
- new int[] {100 * 100, 100 * 100, 100 * 100, 50 * 100},
+ new ItemStack[] { ItemList.Crop_Drop_OilBerry.get(6), GT_Bees.drop.getStackForType(DropType.OIL),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Oilsands, 1),
+ ItemList.FR_Wax.get(1) },
+ new int[] { 100 * 100, 100 * 100, 100 * 100, 50 * 100 },
Voltage.ULV);
addCentrifugeToMaterial(
CombType.APATITE,
- new Materials[] {Materials.Apatite, Materials.Phosphate},
- new int[] {100 * 100, 80 * 100},
+ new Materials[] { Materials.Apatite, Materials.Phosphate },
+ new int[] { 100 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -192,145 +182,138 @@ public class ItemComb extends Item {
// ic2
addCentrifugeToItemStack(
CombType.COOLANT,
- new ItemStack[] {GT_Bees.drop.getStackForType(DropType.COOLANT), ItemList.FR_Wax.get(1)},
- new int[] {100 * 100, 100 * 100},
+ new ItemStack[] { GT_Bees.drop.getStackForType(DropType.COOLANT), ItemList.FR_Wax.get(1) },
+ new int[] { 100 * 100, 100 * 100 },
Voltage.HV,
196);
addCentrifugeToItemStack(
CombType.ENERGY,
- new ItemStack[] {
- GT_Bees.drop.getStackForType(DropType.HOT_COOLANT),
- ItemList.IC2_Energium_Dust.get(1L),
- ItemList.FR_RefractoryWax.get(1)
- },
- new int[] {20 * 100, 20 * 100, 50 * 100},
+ new ItemStack[] { GT_Bees.drop.getStackForType(DropType.HOT_COOLANT),
+ ItemList.IC2_Energium_Dust.get(1L), ItemList.FR_RefractoryWax.get(1) },
+ new int[] { 20 * 100, 20 * 100, 50 * 100 },
Voltage.HV,
196);
addCentrifugeToItemStack(
CombType.LAPOTRON,
- new ItemStack[] {
- GT_Bees.drop.getStackForType(DropType.LAPIS),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.LapotronDust", 1, 0),
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 2)
- },
- new int[] {20 * 100, 15 * 100, 40 * 100},
+ new ItemStack[] { GT_Bees.drop.getStackForType(DropType.LAPIS),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.LapotronDust", 1, 0),
+ GT_ModHandler.getModItem("MagicBees", "wax", 1, 2) },
+ new int[] { 20 * 100, 15 * 100, 40 * 100 },
Voltage.HV,
196);
addCentrifugeToMaterial(
CombType.PYROTHEUM,
- new Materials[] {Materials.Blaze, Materials.Pyrotheum},
- new int[] {25 * 100, 20 * 100},
+ new Materials[] { Materials.Blaze, Materials.Pyrotheum },
+ new int[] { 25 * 100, 20 * 100 },
new int[] {},
Voltage.HV,
NI,
30 * 100);
addCentrifugeToItemStack(
CombType.CRYOTHEUM,
- new ItemStack[] {ItemList.FR_RefractoryWax.get(1), Materials.Cryotheum.getDust(1)},
- new int[] {50 * 100, 100 * 100},
+ new ItemStack[] { ItemList.FR_RefractoryWax.get(1), Materials.Cryotheum.getDust(1) },
+ new int[] { 50 * 100, 100 * 100 },
Voltage.MV);
addCentrifugeToItemStack(
CombType.BLIZZ,
- new ItemStack[] {ItemList.FR_RefractoryWax.get(1), Materials.Blizz.getDust(1)},
- new int[] {50 * 100, 100 * 100},
+ new ItemStack[] { ItemList.FR_RefractoryWax.get(1), Materials.Blizz.getDust(1) },
+ new int[] { 50 * 100, 100 * 100 },
Voltage.MV);
// Alloy
- addProcessGT(CombType.REDALLOY, new Materials[] {Materials.RedAlloy}, Voltage.LV);
- addProcessGT(CombType.REDSTONEALLOY, new Materials[] {Materials.RedstoneAlloy}, Voltage.LV);
- addProcessGT(CombType.CONDUCTIVEIRON, new Materials[] {Materials.ConductiveIron}, Voltage.MV);
- addProcessGT(CombType.VIBRANTALLOY, new Materials[] {Materials.VibrantAlloy}, Voltage.HV);
- addProcessGT(CombType.ENERGETICALLOY, new Materials[] {Materials.EnergeticAlloy}, Voltage.HV);
- addProcessGT(CombType.ELECTRICALSTEEL, new Materials[] {Materials.ElectricalSteel}, Voltage.LV);
- addProcessGT(CombType.DARKSTEEL, new Materials[] {Materials.DarkSteel}, Voltage.MV);
- addProcessGT(CombType.PULSATINGIRON, new Materials[] {Materials.PulsatingIron}, Voltage.HV);
- addProcessGT(CombType.STAINLESSSTEEL, new Materials[] {Materials.StainlessSteel}, Voltage.HV);
- addProcessGT(CombType.BEDROCKIUM, new Materials[] {Materials.Bedrockium}, Voltage.EV);
+ addProcessGT(CombType.REDALLOY, new Materials[] { Materials.RedAlloy }, Voltage.LV);
+ addProcessGT(CombType.REDSTONEALLOY, new Materials[] { Materials.RedstoneAlloy }, Voltage.LV);
+ addProcessGT(CombType.CONDUCTIVEIRON, new Materials[] { Materials.ConductiveIron }, Voltage.MV);
+ addProcessGT(CombType.VIBRANTALLOY, new Materials[] { Materials.VibrantAlloy }, Voltage.HV);
+ addProcessGT(CombType.ENERGETICALLOY, new Materials[] { Materials.EnergeticAlloy }, Voltage.HV);
+ addProcessGT(CombType.ELECTRICALSTEEL, new Materials[] { Materials.ElectricalSteel }, Voltage.LV);
+ addProcessGT(CombType.DARKSTEEL, new Materials[] { Materials.DarkSteel }, Voltage.MV);
+ addProcessGT(CombType.PULSATINGIRON, new Materials[] { Materials.PulsatingIron }, Voltage.HV);
+ addProcessGT(CombType.STAINLESSSTEEL, new Materials[] { Materials.StainlessSteel }, Voltage.HV);
+ addProcessGT(CombType.BEDROCKIUM, new Materials[] { Materials.Bedrockium }, Voltage.EV);
addCentrifugeToItemStack(
CombType.ENDERIUM,
- new ItemStack[] {
- ItemList.FR_RefractoryWax.get(1),
- GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.EnderiumBase, 1),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Enderium, 1)
- },
- new int[] {50 * 100, 30 * 100, 50 * 100},
+ new ItemStack[] { ItemList.FR_RefractoryWax.get(1),
+ GT_OreDictUnificator.get(OrePrefixes.dustSmall, Materials.EnderiumBase, 1),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Enderium, 1) },
+ new int[] { 50 * 100, 30 * 100, 50 * 100 },
Voltage.HV);
if (GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.REDALLOY,
- new Materials[] {Materials.RedAlloy},
- new int[] {100 * 100},
+ new Materials[] { Materials.RedAlloy },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.REDSTONEALLOY,
- new Materials[] {Materials.RedstoneAlloy},
- new int[] {100 * 100},
+ new Materials[] { Materials.RedstoneAlloy },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.CONDUCTIVEIRON,
- new Materials[] {Materials.ConductiveIron},
- new int[] {90 * 100},
+ new Materials[] { Materials.ConductiveIron },
+ new int[] { 90 * 100 },
new int[] {},
Voltage.MV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.VIBRANTALLOY,
- new Materials[] {Materials.VibrantAlloy},
- new int[] {70 * 100},
+ new Materials[] { Materials.VibrantAlloy },
+ new int[] { 70 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.ENERGETICALLOY,
- new Materials[] {Materials.EnergeticAlloy},
- new int[] {80 * 100},
+ new Materials[] { Materials.EnergeticAlloy },
+ new int[] { 80 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.ELECTRICALSTEEL,
- new Materials[] {Materials.ElectricalSteel},
- new int[] {100 * 100},
+ new Materials[] { Materials.ElectricalSteel },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.DARKSTEEL,
- new Materials[] {Materials.DarkSteel},
- new int[] {100 * 100},
+ new Materials[] { Materials.DarkSteel },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.MV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.PULSATINGIRON,
- new Materials[] {Materials.PulsatingIron},
- new int[] {80 * 100},
+ new Materials[] { Materials.PulsatingIron },
+ new int[] { 80 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.STAINLESSSTEEL,
- new Materials[] {Materials.StainlessSteel},
- new int[] {50 * 100},
+ new Materials[] { Materials.StainlessSteel },
+ new int[] { 50 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.BEDROCKIUM,
- new Materials[] {Materials.Bedrockium},
- new int[] {50 * 100},
+ new Materials[] { Materials.Bedrockium },
+ new int[] { 50 * 100 },
new int[] {},
Voltage.EV,
ItemList.FR_RefractoryWax.get(1),
@@ -339,229 +322,204 @@ public class ItemComb extends Item {
} else {
addCentrifugeToMaterial(
CombType.REDALLOY,
- new Materials[] {Materials.RedAlloy, Materials.Redstone, Materials.Copper},
- new int[] {100 * 100, 75 * 100, 90 * 100},
+ new Materials[] { Materials.RedAlloy, Materials.Redstone, Materials.Copper },
+ new int[] { 100 * 100, 75 * 100, 90 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.REDSTONEALLOY,
- new Materials[] {Materials.RedstoneAlloy, Materials.Redstone, Materials.Silicon, Materials.Coal},
- new int[] {100 * 100, 90 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.RedstoneAlloy, Materials.Redstone, Materials.Silicon, Materials.Coal },
+ new int[] { 100 * 100, 90 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.CONDUCTIVEIRON,
- new Materials[] {Materials.ConductiveIron, Materials.Silver, Materials.Iron},
- new int[] {90 * 100, 55 * 100, 65 * 100},
+ new Materials[] { Materials.ConductiveIron, Materials.Silver, Materials.Iron },
+ new int[] { 90 * 100, 55 * 100, 65 * 100 },
new int[] {},
Voltage.MV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.VIBRANTALLOY,
- new Materials[] {Materials.VibrantAlloy, Materials.Chrome},
- new int[] {70 * 100, 50 * 100},
+ new Materials[] { Materials.VibrantAlloy, Materials.Chrome },
+ new int[] { 70 * 100, 50 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.ENERGETICALLOY,
- new Materials[] {Materials.EnergeticAlloy, Materials.Gold},
- new int[] {80 * 100, 60 * 100},
+ new Materials[] { Materials.EnergeticAlloy, Materials.Gold },
+ new int[] { 80 * 100, 60 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.ELECTRICALSTEEL,
- new Materials[] {Materials.ElectricalSteel, Materials.Silicon, Materials.Coal},
- new int[] {100 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.ElectricalSteel, Materials.Silicon, Materials.Coal },
+ new int[] { 100 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.DARKSTEEL,
- new Materials[] {Materials.DarkSteel, Materials.Coal},
- new int[] {100 * 100, 75 * 100},
+ new Materials[] { Materials.DarkSteel, Materials.Coal },
+ new int[] { 100 * 100, 75 * 100 },
new int[] {},
Voltage.MV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.PULSATINGIRON,
- new Materials[] {Materials.PulsatingIron, Materials.Iron},
- new int[] {80 * 100, 75 * 100},
+ new Materials[] { Materials.PulsatingIron, Materials.Iron },
+ new int[] { 80 * 100, 75 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.STAINLESSSTEEL,
- new Materials[] {
- Materials.StainlessSteel,
- Materials.Iron,
- Materials.Chrome,
- Materials.Manganese,
- Materials.Nickel
- },
- new int[] {50 * 100, 75 * 100, 55 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.StainlessSteel, Materials.Iron, Materials.Chrome, Materials.Manganese,
+ Materials.Nickel },
+ new int[] { 50 * 100, 75 * 100, 55 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.HV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
addCentrifugeToMaterial(
CombType.BEDROCKIUM,
- new Materials[] {Materials.Bedrockium},
- new int[] {50 * 100},
+ new Materials[] { Materials.Bedrockium },
+ new int[] { 50 * 100 },
new int[] {},
Voltage.EV,
ItemList.FR_RefractoryWax.get(1),
50 * 100);
}
// Thaumic
- addProcessGT(CombType.THAUMIUMDUST, new Materials[] {Materials.Thaumium}, Voltage.MV);
+ addProcessGT(CombType.THAUMIUMDUST, new Materials[] { Materials.Thaumium }, Voltage.MV);
addCentrifugeToItemStack(
CombType.THAUMIUMSHARD,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "propolis", 1, 1),
- GT_ModHandler.getModItem("MagicBees", "propolis", 1, 2),
- GT_ModHandler.getModItem("MagicBees", "propolis", 1, 3),
- GT_ModHandler.getModItem("MagicBees", "propolis", 1, 4),
- GT_ModHandler.getModItem("MagicBees", "propolis", 1, 5),
- GT_ModHandler.getModItem("MagicBees", "propolis", 1, 6),
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0)
- },
- new int[] {20 * 100, 20 * 100, 20 * 100, 20 * 100, 20 * 100, 20 * 100, 50 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "propolis", 1, 1),
+ GT_ModHandler.getModItem("MagicBees", "propolis", 1, 2),
+ GT_ModHandler.getModItem("MagicBees", "propolis", 1, 3),
+ GT_ModHandler.getModItem("MagicBees", "propolis", 1, 4),
+ GT_ModHandler.getModItem("MagicBees", "propolis", 1, 5),
+ GT_ModHandler.getModItem("MagicBees", "propolis", 1, 6),
+ GT_ModHandler.getModItem("MagicBees", "wax", 1, 0) },
+ new int[] { 20 * 100, 20 * 100, 20 * 100, 20 * 100, 20 * 100, 20 * 100, 50 * 100 },
Voltage.ULV);
- addProcessGT(CombType.AMBER, new Materials[] {Materials.Amber}, Voltage.LV);
- addProcessGT(CombType.QUICKSILVER, new Materials[] {Materials.Cinnabar}, Voltage.LV);
+ addProcessGT(CombType.AMBER, new Materials[] { Materials.Amber }, Voltage.LV);
+ addProcessGT(CombType.QUICKSILVER, new Materials[] { Materials.Cinnabar }, Voltage.LV);
addCentrifugeToItemStack(
CombType.SALISMUNDUS,
- new ItemStack[] {
- GT_ModHandler.getModItem("Thaumcraft", "ItemResource", 1, 14),
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0)
- },
- new int[] {100 * 100, 50 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("Thaumcraft", "ItemResource", 1, 14),
+ GT_ModHandler.getModItem("MagicBees", "wax", 1, 0) },
+ new int[] { 100 * 100, 50 * 100 },
Voltage.MV);
addCentrifugeToItemStack(
CombType.TAINTED,
- new ItemStack[] {
- GT_ModHandler.getModItem("Thaumcraft", "ItemResource", 1, 11),
- GT_ModHandler.getModItem("Thaumcraft", "ItemResource", 1, 12),
- GT_ModHandler.getModItem("Thaumcraft", "blockTaintFibres", 1, 0),
- GT_ModHandler.getModItem("Thaumcraft", "blockTaintFibres", 1, 1),
- GT_ModHandler.getModItem("Thaumcraft", "blockTaintFibres", 1, 2),
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0)
- },
- new int[] {15 * 100, 15 * 100, 15 * 100, 15 * 100, 15 * 100, 50 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("Thaumcraft", "ItemResource", 1, 11),
+ GT_ModHandler.getModItem("Thaumcraft", "ItemResource", 1, 12),
+ GT_ModHandler.getModItem("Thaumcraft", "blockTaintFibres", 1, 0),
+ GT_ModHandler.getModItem("Thaumcraft", "blockTaintFibres", 1, 1),
+ GT_ModHandler.getModItem("Thaumcraft", "blockTaintFibres", 1, 2),
+ GT_ModHandler.getModItem("MagicBees", "wax", 1, 0) },
+ new int[] { 15 * 100, 15 * 100, 15 * 100, 15 * 100, 15 * 100, 50 * 100 },
Voltage.ULV);
- addProcessGT(CombType.MITHRIL, new Materials[] {Materials.Mithril}, Voltage.HV);
- addProcessGT(CombType.ASTRALSILVER, new Materials[] {Materials.AstralSilver}, Voltage.HV);
+ addProcessGT(CombType.MITHRIL, new Materials[] { Materials.Mithril }, Voltage.HV);
+ addProcessGT(CombType.ASTRALSILVER, new Materials[] { Materials.AstralSilver }, Voltage.HV);
addCentrifugeToMaterial(
CombType.ASTRALSILVER,
- new Materials[] {Materials.AstralSilver, Materials.Silver},
- new int[] {20 * 100, (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 75) * 100},
+ new Materials[] { Materials.AstralSilver, Materials.Silver },
+ new int[] { 20 * 100, (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 75) * 100 },
new int[] {},
Voltage.HV,
GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
50 * 100);
addCentrifugeToItemStack(
CombType.THAUMINITE,
- new ItemStack[] {
- GT_ModHandler.getModItem("thaumicbases", "resource", 1, 0),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Thaumium, 1),
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0)
- },
- new int[] {20 * 100, 10 * 100, 50 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("thaumicbases", "resource", 1, 0),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Thaumium, 1),
+ GT_ModHandler.getModItem("MagicBees", "wax", 1, 0) },
+ new int[] { 20 * 100, 10 * 100, 50 * 100 },
Voltage.HV);
- addProcessGT(CombType.SHADOWMETAL, new Materials[] {Materials.Shadow}, Voltage.HV);
+ addProcessGT(CombType.SHADOWMETAL, new Materials[] { Materials.Shadow }, Voltage.HV);
addCentrifugeToMaterial(
CombType.SHADOWMETAL,
- new Materials[] {Materials.Shadow, Materials.ShadowSteel},
- new int[] {(GT_Mod.gregtechproxy.mNerfedCombs ? 20 : 75) * 100, 10 * 100},
+ new Materials[] { Materials.Shadow, Materials.ShadowSteel },
+ new int[] { (GT_Mod.gregtechproxy.mNerfedCombs ? 20 : 75) * 100, 10 * 100 },
new int[] {},
Voltage.HV,
GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
50 * 100);
- addProcessGT(CombType.DIVIDED, new Materials[] {Materials.Diamond}, Voltage.HV);
+ addProcessGT(CombType.DIVIDED, new Materials[] { Materials.Diamond }, Voltage.HV);
addCentrifugeToItemStack(
CombType.DIVIDED,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
- GT_ModHandler.getModItem("ExtraUtilities", "unstableingot", 1, 1),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Iron, 1),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Diamond, 1)
- },
- new int[] {
- 50 * 100,
- 20 * 100,
- (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 75) * 100,
- (GT_Mod.gregtechproxy.mNerfedCombs ? 5 : 55) * 100
- },
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
+ GT_ModHandler.getModItem("ExtraUtilities", "unstableingot", 1, 1),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Iron, 1),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Diamond, 1) },
+ new int[] { 50 * 100, 20 * 100, (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 75) * 100,
+ (GT_Mod.gregtechproxy.mNerfedCombs ? 5 : 55) * 100 },
Voltage.HV);
- addProcessGT(CombType.SPARKELING, new Materials[] {Materials.NetherStar}, Voltage.EV);
+ addProcessGT(CombType.SPARKELING, new Materials[] { Materials.NetherStar }, Voltage.EV);
addCentrifugeToItemStack(
CombType.SPARKELING,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
- GT_ModHandler.getModItem("MagicBees", "miscResources", 2, 5),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.NetherStar, 1)
- },
- new int[] {50 * 100, 10 * 100, (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 50) * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
+ GT_ModHandler.getModItem("MagicBees", "miscResources", 2, 5),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.NetherStar, 1) },
+ new int[] { 50 * 100, 10 * 100, (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 50) * 100 },
Voltage.EV);
if (GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.THAUMIUMDUST,
- new Materials[] {Materials.Thaumium},
- new int[] {100 * 100},
+ new Materials[] { Materials.Thaumium },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.MV,
GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
50 * 100);
addCentrifugeToItemStack(
CombType.QUICKSILVER,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
- GT_ModHandler.getModItem("Thaumcraft", "ItemNugget", 1, 5)
- },
- new int[] {50 * 100, 100 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
+ GT_ModHandler.getModItem("Thaumcraft", "ItemNugget", 1, 5) },
+ new int[] { 50 * 100, 100 * 100 },
Voltage.ULV);
} else {
addCentrifugeToMaterial(
CombType.THAUMIUMDUST,
- new Materials[] {Materials.Thaumium, Materials.Iron},
- new int[] {100 * 100, 75 * 100},
+ new Materials[] { Materials.Thaumium, Materials.Iron },
+ new int[] { 100 * 100, 75 * 100 },
new int[] {},
Voltage.MV,
GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
50 * 100);
addCentrifugeToMaterial(
CombType.AMBER,
- new Materials[] {Materials.Amber},
- new int[] {100 * 100},
+ new Materials[] { Materials.Amber },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
50 * 100);
addCentrifugeToItemStack(
CombType.QUICKSILVER,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
- GT_ModHandler.getModItem("Thaumcraft", "ItemNugget", 1, 5),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Cinnabar, 1)
- },
- new int[] {50 * 100, 100 * 100, 85 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
+ GT_ModHandler.getModItem("Thaumcraft", "ItemNugget", 1, 5),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.Cinnabar, 1) },
+ new int[] { 50 * 100, 100 * 100, 85 * 100 },
Voltage.ULV);
addCentrifugeToMaterial(
CombType.MITHRIL,
- new Materials[] {Materials.Mithril, Materials.Platinum},
- new int[] {75 * 100, 55 * 100},
+ new Materials[] { Materials.Mithril, Materials.Platinum },
+ new int[] { 75 * 100, 55 * 100 },
new int[] {},
Voltage.HV,
GT_ModHandler.getModItem("MagicBees", "wax", 1, 0),
@@ -569,178 +527,168 @@ public class ItemComb extends Item {
}
// Gem Line
- addProcessGT(CombType.STONE, new Materials[] {Materials.Soapstone}, Voltage.LV);
- addProcessGT(CombType.CERTUS, new Materials[] {Materials.CertusQuartz}, Voltage.LV);
- addProcessGT(CombType.FLUIX, new Materials[] {Materials.Fluix}, Voltage.LV);
- addProcessGT(CombType.REDSTONE, new Materials[] {Materials.Redstone}, Voltage.LV);
+ addProcessGT(CombType.STONE, new Materials[] { Materials.Soapstone }, Voltage.LV);
+ addProcessGT(CombType.CERTUS, new Materials[] { Materials.CertusQuartz }, Voltage.LV);
+ addProcessGT(CombType.FLUIX, new Materials[] { Materials.Fluix }, Voltage.LV);
+ addProcessGT(CombType.REDSTONE, new Materials[] { Materials.Redstone }, Voltage.LV);
addCentrifugeToMaterial(
CombType.RAREEARTH,
- new Materials[] {Materials.RareEarth},
- new int[] {100 * 100},
- new int[] {1},
+ new Materials[] { Materials.RareEarth },
+ new int[] { 100 * 100 },
+ new int[] { 1 },
Voltage.ULV,
NI,
30 * 100);
- addProcessGT(CombType.LAPIS, new Materials[] {Materials.Lapis}, Voltage.LV);
- addProcessGT(CombType.RUBY, new Materials[] {Materials.Ruby}, Voltage.LV);
- addProcessGT(CombType.REDGARNET, new Materials[] {Materials.GarnetRed}, Voltage.LV);
- addProcessGT(CombType.YELLOWGARNET, new Materials[] {Materials.GarnetYellow}, Voltage.LV);
- addProcessGT(CombType.SAPPHIRE, new Materials[] {Materials.Sapphire}, Voltage.LV);
- addProcessGT(CombType.DIAMOND, new Materials[] {Materials.Diamond}, Voltage.LV);
- addProcessGT(CombType.OLIVINE, new Materials[] {Materials.Olivine}, Voltage.LV);
- addProcessGT(CombType.EMERALD, new Materials[] {Materials.Emerald}, Voltage.LV);
- addProcessGT(CombType.FIRESTONE, new Materials[] {Materials.Firestone}, Voltage.LV);
- addProcessGT(CombType.PYROPE, new Materials[] {Materials.Pyrope}, Voltage.LV);
- addProcessGT(CombType.GROSSULAR, new Materials[] {Materials.Grossular}, Voltage.LV);
+ addProcessGT(CombType.LAPIS, new Materials[] { Materials.Lapis }, Voltage.LV);
+ addProcessGT(CombType.RUBY, new Materials[] { Materials.Ruby }, Voltage.LV);
+ addProcessGT(CombType.REDGARNET, new Materials[] { Materials.GarnetRed }, Voltage.LV);
+ addProcessGT(CombType.YELLOWGARNET, new Materials[] { Materials.GarnetYellow }, Voltage.LV);
+ addProcessGT(CombType.SAPPHIRE, new Materials[] { Materials.Sapphire }, Voltage.LV);
+ addProcessGT(CombType.DIAMOND, new Materials[] { Materials.Diamond }, Voltage.LV);
+ addProcessGT(CombType.OLIVINE, new Materials[] { Materials.Olivine }, Voltage.LV);
+ addProcessGT(CombType.EMERALD, new Materials[] { Materials.Emerald }, Voltage.LV);
+ addProcessGT(CombType.FIRESTONE, new Materials[] { Materials.Firestone }, Voltage.LV);
+ addProcessGT(CombType.PYROPE, new Materials[] { Materials.Pyrope }, Voltage.LV);
+ addProcessGT(CombType.GROSSULAR, new Materials[] { Materials.Grossular }, Voltage.LV);
if (GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.STONE,
- new Materials[] {
- Materials.Stone,
- Materials.GraniteBlack,
- Materials.GraniteRed,
- Materials.Basalt,
- Materials.Marble,
- Materials.Redrock
- },
- new int[] {70 * 100, 50 * 100, 50 * 100, 50 * 100, 50 * 100, 50 * 100},
- new int[] {9, 9, 9, 9, 9, 9},
+ new Materials[] { Materials.Stone, Materials.GraniteBlack, Materials.GraniteRed, Materials.Basalt,
+ Materials.Marble, Materials.Redrock },
+ new int[] { 70 * 100, 50 * 100, 50 * 100, 50 * 100, 50 * 100, 50 * 100 },
+ new int[] { 9, 9, 9, 9, 9, 9 },
Voltage.ULV,
NI,
50 * 100);
addCentrifugeToMaterial(
CombType.FLUIX,
- new Materials[] {Materials.Fluix},
- new int[] {25 * 100},
- new int[] {9},
+ new Materials[] { Materials.Fluix },
+ new int[] { 25 * 100 },
+ new int[] { 9 },
Voltage.ULV,
NI,
30 * 100);
} else {
addCentrifugeToMaterial(
CombType.STONE,
- new Materials[] {
- Materials.Soapstone,
- Materials.Talc,
- Materials.Apatite,
- Materials.Phosphate,
- Materials.TricalciumPhosphate
- },
- new int[] {95 * 100, 90 * 100, 80 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.Soapstone, Materials.Talc, Materials.Apatite, Materials.Phosphate,
+ Materials.TricalciumPhosphate },
+ new int[] { 95 * 100, 90 * 100, 80 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
50 * 100);
addCentrifugeToMaterial(
CombType.CERTUS,
- new Materials[] {Materials.CertusQuartz, Materials.Quartzite, Materials.Barite},
- new int[] {100 * 100, 80 * 100, 75 * 100},
+ new Materials[] { Materials.CertusQuartz, Materials.Quartzite, Materials.Barite },
+ new int[] { 100 * 100, 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
50 * 100);
addCentrifugeToMaterial(
CombType.FLUIX,
- new Materials[] {Materials.Fluix, Materials.Redstone, Materials.CertusQuartz, Materials.NetherQuartz
- },
- new int[] {25 * 100, 90 * 100, 90 * 100, 90 * 100},
- new int[] {9, 1, 1, 1},
+ new Materials[] { Materials.Fluix, Materials.Redstone, Materials.CertusQuartz,
+ Materials.NetherQuartz },
+ new int[] { 25 * 100, 90 * 100, 90 * 100, 90 * 100 },
+ new int[] { 9, 1, 1, 1 },
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.REDSTONE,
- new Materials[] {Materials.Redstone, Materials.Cinnabar},
- new int[] {100 * 100, 80 * 100},
+ new Materials[] { Materials.Redstone, Materials.Cinnabar },
+ new int[] { 100 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LAPIS,
- new Materials[] {Materials.Lapis, Materials.Sodalite, Materials.Lazurite, Materials.Calcite},
- new int[] {100 * 100, 90 * 100, 90 * 100, 85 * 100},
+ new Materials[] { Materials.Lapis, Materials.Sodalite, Materials.Lazurite, Materials.Calcite },
+ new int[] { 100 * 100, 90 * 100, 90 * 100, 85 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.RUBY,
- new Materials[] {Materials.Ruby, Materials.Redstone},
- new int[] {100 * 100, 90 * 100},
+ new Materials[] { Materials.Ruby, Materials.Redstone },
+ new int[] { 100 * 100, 90 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.REDGARNET,
- new Materials[] {Materials.GarnetRed, Materials.GarnetYellow},
- new int[] {100 * 100, 75 * 100},
+ new Materials[] { Materials.GarnetRed, Materials.GarnetYellow },
+ new int[] { 100 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.YELLOWGARNET,
- new Materials[] {Materials.GarnetYellow, Materials.GarnetRed},
- new int[] {100 * 100, 75 * 100},
+ new Materials[] { Materials.GarnetYellow, Materials.GarnetRed },
+ new int[] { 100 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.SAPPHIRE,
- new Materials[] {Materials.Sapphire, Materials.GreenSapphire, Materials.Almandine, Materials.Pyrope
- },
- new int[] {100 * 100, 90 * 100, 90 * 100, 75 * 100},
+ new Materials[] { Materials.Sapphire, Materials.GreenSapphire, Materials.Almandine,
+ Materials.Pyrope },
+ new int[] { 100 * 100, 90 * 100, 90 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.DIAMOND,
- new Materials[] {Materials.Diamond, Materials.Graphite},
- new int[] {100 * 100, 75 * 100},
+ new Materials[] { Materials.Diamond, Materials.Graphite },
+ new int[] { 100 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.OLIVINE,
- new Materials[] {Materials.Olivine, Materials.Bentonite, Materials.Magnesite, Materials.Glauconite},
- new int[] {100 * 100, 90 * 100, 80 * 100, 75 * 100},
+ new Materials[] { Materials.Olivine, Materials.Bentonite, Materials.Magnesite,
+ Materials.Glauconite },
+ new int[] { 100 * 100, 90 * 100, 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.EMERALD,
- new Materials[] {Materials.Emerald, Materials.Beryllium, Materials.Thorium},
- new int[] {100 * 100, 85 * 100, 75 * 100},
+ new Materials[] { Materials.Emerald, Materials.Beryllium, Materials.Thorium },
+ new int[] { 100 * 100, 85 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.FIRESTONE,
- new Materials[] {Materials.Firestone},
- new int[] {100 * 100},
+ new Materials[] { Materials.Firestone },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
ItemList.FR_RefractoryWax.get(1),
30 * 100);
addCentrifugeToMaterial(
CombType.PYROPE,
- new Materials[] {Materials.Pyrope, Materials.Aluminium, Materials.Magnesium, Materials.Silicon},
- new int[] {100 * 100, 75 * 100, 80 * 100, 75 * 100},
+ new Materials[] { Materials.Pyrope, Materials.Aluminium, Materials.Magnesium, Materials.Silicon },
+ new int[] { 100 * 100, 75 * 100, 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.GROSSULAR,
- new Materials[] {Materials.Grossular, Materials.Aluminium, Materials.Silicon},
- new int[] {100 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.Grossular, Materials.Aluminium, Materials.Silicon },
+ new int[] { 100 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -748,95 +696,95 @@ public class ItemComb extends Item {
}
// Metals Line
- addProcessGT(CombType.SLAG, new Materials[] {Materials.Limestone}, Voltage.LV);
- addProcessGT(CombType.COPPER, new Materials[] {Materials.Copper}, Voltage.LV);
- addProcessGT(CombType.TIN, new Materials[] {Materials.Tin}, Voltage.LV);
- addProcessGT(CombType.LEAD, new Materials[] {Materials.Lead}, Voltage.LV);
- addProcessGT(CombType.INDIUM, new Materials[] {Materials.Indium}, Voltage.ZPM);
- addProcessGT(CombType.NICKEL, new Materials[] {Materials.Nickel}, Voltage.LV);
- addProcessGT(CombType.ZINC, new Materials[] {Materials.Zinc}, Voltage.LV);
- addProcessGT(CombType.SILVER, new Materials[] {Materials.Silver}, Voltage.LV);
- addProcessGT(CombType.CRYOLITE, new Materials[] {Materials.Cryolite}, Voltage.LV);
- addProcessGT(CombType.GOLD, new Materials[] {Materials.Gold}, Voltage.LV);
- addProcessGT(CombType.SULFUR, new Materials[] {Materials.Sulfur}, Voltage.LV);
- addProcessGT(CombType.GALLIUM, new Materials[] {Materials.Gallium}, Voltage.LV);
- addProcessGT(CombType.ARSENIC, new Materials[] {Materials.Arsenic}, Voltage.LV);
+ addProcessGT(CombType.SLAG, new Materials[] { Materials.Limestone }, Voltage.LV);
+ addProcessGT(CombType.COPPER, new Materials[] { Materials.Copper }, Voltage.LV);
+ addProcessGT(CombType.TIN, new Materials[] { Materials.Tin }, Voltage.LV);
+ addProcessGT(CombType.LEAD, new Materials[] { Materials.Lead }, Voltage.LV);
+ addProcessGT(CombType.INDIUM, new Materials[] { Materials.Indium }, Voltage.ZPM);
+ addProcessGT(CombType.NICKEL, new Materials[] { Materials.Nickel }, Voltage.LV);
+ addProcessGT(CombType.ZINC, new Materials[] { Materials.Zinc }, Voltage.LV);
+ addProcessGT(CombType.SILVER, new Materials[] { Materials.Silver }, Voltage.LV);
+ addProcessGT(CombType.CRYOLITE, new Materials[] { Materials.Cryolite }, Voltage.LV);
+ addProcessGT(CombType.GOLD, new Materials[] { Materials.Gold }, Voltage.LV);
+ addProcessGT(CombType.SULFUR, new Materials[] { Materials.Sulfur }, Voltage.LV);
+ addProcessGT(CombType.GALLIUM, new Materials[] { Materials.Gallium }, Voltage.LV);
+ addProcessGT(CombType.ARSENIC, new Materials[] { Materials.Arsenic }, Voltage.LV);
if (ProcessingModSupport.aEnableGCMarsMats) {
- addProcessGT(CombType.IRON, new Materials[] {Materials.Iron}, Voltage.LV);
- addProcessGT(CombType.STEEL, new Materials[] {Materials.Steel}, Voltage.LV);
+ addProcessGT(CombType.IRON, new Materials[] { Materials.Iron }, Voltage.LV);
+ addProcessGT(CombType.STEEL, new Materials[] { Materials.Steel }, Voltage.LV);
} else {
- addProcessGT(CombType.IRON, new Materials[] {Materials.Iron}, Voltage.LV);
- addProcessGT(CombType.STEEL, new Materials[] {Materials.Steel}, Voltage.LV);
+ addProcessGT(CombType.IRON, new Materials[] { Materials.Iron }, Voltage.LV);
+ addProcessGT(CombType.STEEL, new Materials[] { Materials.Steel }, Voltage.LV);
}
if (GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.SLAG,
- new Materials[] {Materials.Stone, Materials.GraniteBlack, Materials.GraniteRed},
- new int[] {50 * 100, 20 * 100, 20 * 100},
- new int[] {9, 9, 9},
+ new Materials[] { Materials.Stone, Materials.GraniteBlack, Materials.GraniteRed },
+ new int[] { 50 * 100, 20 * 100, 20 * 100 },
+ new int[] { 9, 9, 9 },
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.COPPER,
- new Materials[] {Materials.Copper},
- new int[] {70 * 100},
+ new Materials[] { Materials.Copper },
+ new int[] { 70 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.TIN,
- new Materials[] {Materials.Tin},
- new int[] {60 * 100},
+ new Materials[] { Materials.Tin },
+ new int[] { 60 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LEAD,
- new Materials[] {Materials.Lead},
- new int[] {45 * 100},
+ new Materials[] { Materials.Lead },
+ new int[] { 45 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.IRON,
- new Materials[] {Materials.Iron},
- new int[] {30 * 100},
+ new Materials[] { Materials.Iron },
+ new int[] { 30 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.STEEL,
- new Materials[] {Materials.Steel},
- new int[] {40 * 100},
+ new Materials[] { Materials.Steel },
+ new int[] { 40 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.SILVER,
- new Materials[] {Materials.Silver},
- new int[] {80 * 100},
+ new Materials[] { Materials.Silver },
+ new int[] { 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.CRYOLITE,
- new Materials[] {Materials.Cryolite},
- new int[] {80 * 100},
+ new Materials[] { Materials.Cryolite },
+ new int[] { 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.SULFUR,
- new Materials[] {Materials.Sulfur},
- new int[] {100 * 100},
+ new Materials[] { Materials.Sulfur },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -844,45 +792,34 @@ public class ItemComb extends Item {
} else {
addCentrifugeToMaterial(
CombType.SLAG,
- new Materials[] {
- Materials.Salt,
- Materials.RockSalt,
- Materials.Lepidolite,
- Materials.Spodumene,
- Materials.Monazite
- },
- new int[] {100 * 100, 100 * 100, 100 * 100},
+ new Materials[] { Materials.Salt, Materials.RockSalt, Materials.Lepidolite, Materials.Spodumene,
+ Materials.Monazite },
+ new int[] { 100 * 100, 100 * 100, 100 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.COPPER,
- new Materials[] {
- Materials.Copper,
- Materials.Tetrahedrite,
- Materials.Chalcopyrite,
- Materials.Malachite,
- Materials.Pyrite,
- Materials.Stibnite
- },
- new int[] {100 * 100, 85 * 100, 95 * 100, 80 * 100, 75 * 100, 65 * 100},
+ new Materials[] { Materials.Copper, Materials.Tetrahedrite, Materials.Chalcopyrite,
+ Materials.Malachite, Materials.Pyrite, Materials.Stibnite },
+ new int[] { 100 * 100, 85 * 100, 95 * 100, 80 * 100, 75 * 100, 65 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.TIN,
- new Materials[] {Materials.Tin, Materials.Cassiterite, Materials.CassiteriteSand},
- new int[] {100 * 100, 85 * 100, 65 * 100},
+ new Materials[] { Materials.Tin, Materials.Cassiterite, Materials.CassiteriteSand },
+ new int[] { 100 * 100, 85 * 100, 65 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LEAD,
- new Materials[] {Materials.Lead, Materials.Galena},
- new int[] {100 * 100, 75 * 100},
+ new Materials[] { Materials.Lead, Materials.Galena },
+ new int[] { 100 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -890,30 +827,18 @@ public class ItemComb extends Item {
if (ProcessingModSupport.aEnableGCMarsMats) {
addCentrifugeToMaterial(
CombType.IRON,
- new Materials[] {
- Materials.Iron,
- Materials.Magnetite,
- Materials.BrownLimonite,
- Materials.YellowLimonite,
- Materials.VanadiumMagnetite,
- Materials.MeteoricIron
- },
- new int[] {100 * 100, 90 * 100, 85 * 100, 85 * 100, 80 * 100, 75 * 100},
+ new Materials[] { Materials.Iron, Materials.Magnetite, Materials.BrownLimonite,
+ Materials.YellowLimonite, Materials.VanadiumMagnetite, Materials.MeteoricIron },
+ new int[] { 100 * 100, 90 * 100, 85 * 100, 85 * 100, 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LEAD,
- new Materials[] {
- Materials.Steel,
- Materials.Magnetite,
- Materials.VanadiumMagnetite,
- Materials.Molybdenite,
- Materials.Molybdenum,
- Materials.MeteoricIron
- },
- new int[] {100 * 100, 90 * 100, 80 * 100, 65 * 100, 65 * 100, 75 * 100},
+ new Materials[] { Materials.Steel, Materials.Magnetite, Materials.VanadiumMagnetite,
+ Materials.Molybdenite, Materials.Molybdenum, Materials.MeteoricIron },
+ new int[] { 100 * 100, 90 * 100, 80 * 100, 65 * 100, 65 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -921,30 +846,18 @@ public class ItemComb extends Item {
} else {
addCentrifugeToMaterial(
CombType.IRON,
- new Materials[] {
- Materials.Iron,
- Materials.Magnetite,
- Materials.BrownLimonite,
- Materials.YellowLimonite,
- Materials.VanadiumMagnetite,
- Materials.BandedIron
- },
- new int[] {100 * 100, 90 * 100, 85 * 100, 85 * 100, 80 * 100, 85 * 100},
+ new Materials[] { Materials.Iron, Materials.Magnetite, Materials.BrownLimonite,
+ Materials.YellowLimonite, Materials.VanadiumMagnetite, Materials.BandedIron },
+ new int[] { 100 * 100, 90 * 100, 85 * 100, 85 * 100, 80 * 100, 85 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.STEEL,
- new Materials[] {
- Materials.Steel,
- Materials.Magnetite,
- Materials.VanadiumMagnetite,
- Materials.BandedIron,
- Materials.Molybdenite,
- Materials.Molybdenum
- },
- new int[] {100 * 100, 90 * 100, 80 * 100, 85 * 100, 65 * 100, 65 * 100},
+ new Materials[] { Materials.Steel, Materials.Magnetite, Materials.VanadiumMagnetite,
+ Materials.BandedIron, Materials.Molybdenite, Materials.Molybdenum },
+ new int[] { 100 * 100, 90 * 100, 80 * 100, 85 * 100, 65 * 100, 65 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -952,71 +865,65 @@ public class ItemComb extends Item {
}
addCentrifugeToMaterial(
CombType.NICKEL,
- new Materials[] {
- Materials.Nickel,
- Materials.Garnierite,
- Materials.Pentlandite,
- Materials.Cobaltite,
- Materials.Wulfenite,
- Materials.Powellite
- },
- new int[] {100 * 100, 85 * 100, 85 * 100, 80 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.Nickel, Materials.Garnierite, Materials.Pentlandite,
+ Materials.Cobaltite, Materials.Wulfenite, Materials.Powellite },
+ new int[] { 100 * 100, 85 * 100, 85 * 100, 80 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.ZINC,
- new Materials[] {Materials.Zinc, Materials.Sphalerite, Materials.Sulfur},
- new int[] {100 * 100, 80 * 100, 75 * 100},
+ new Materials[] { Materials.Zinc, Materials.Sphalerite, Materials.Sulfur },
+ new int[] { 100 * 100, 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.SILVER,
- new Materials[] {Materials.Silver, Materials.Galena},
- new int[] {100 * 100, 80 * 100},
+ new Materials[] { Materials.Silver, Materials.Galena },
+ new int[] { 100 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.CRYOLITE,
- new Materials[] {Materials.Cryolite, Materials.Silver},
- new int[] {100 * 100, 80 * 100},
+ new Materials[] { Materials.Cryolite, Materials.Silver },
+ new int[] { 100 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.GOLD,
- new Materials[] {Materials.Gold},
- new int[] {100 * 100},
+ new Materials[] { Materials.Gold },
+ new int[] { 100 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.SULFUR,
- new Materials[] {Materials.Sulfur, Materials.Pyrite, Materials.Sphalerite},
- new int[] {100 * 100, 90 * 100, 80 * 100},
+ new Materials[] { Materials.Sulfur, Materials.Pyrite, Materials.Sphalerite },
+ new int[] { 100 * 100, 90 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.GALLIUM,
- new Materials[] {Materials.Gallium, Materials.Niobium},
- new int[] {80 * 100, 75 * 100},
+ new Materials[] { Materials.Gallium, Materials.Niobium },
+ new int[] { 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.ARSENIC,
- new Materials[] {Materials.Arsenic, Materials.Bismuth, Materials.Antimony},
- new int[] {80 * 100, 70 * 100, 70 * 100},
+ new Materials[] { Materials.Arsenic, Materials.Bismuth, Materials.Antimony },
+ new int[] { 80 * 100, 70 * 100, 70 * 100 },
new int[] {},
Voltage.ULV,
NI,
@@ -1024,237 +931,219 @@ public class ItemComb extends Item {
}
// Rare Metals Line
- addProcessGT(CombType.BAUXITE, new Materials[] {Materials.Bauxite}, Voltage.LV);
- addProcessGT(CombType.ALUMINIUM, new Materials[] {Materials.Aluminium}, Voltage.LV);
- addProcessGT(CombType.MANGANESE, new Materials[] {Materials.Manganese}, Voltage.LV);
- addProcessGT(CombType.TITANIUM, new Materials[] {Materials.Titanium}, Voltage.EV);
- addProcessGT(CombType.MAGNESIUM, new Materials[] {Materials.Magnesium}, Voltage.LV);
- addProcessGT(CombType.CHROME, new Materials[] {Materials.Chrome}, Voltage.HV);
- addProcessGT(CombType.TUNGSTEN, new Materials[] {Materials.Tungsten}, Voltage.IV);
- addProcessGT(CombType.PLATINUM, new Materials[] {Materials.Platinum}, Voltage.HV);
- addProcessGT(CombType.MOLYBDENUM, new Materials[] {Materials.Molybdenum}, Voltage.LV);
- addProcessGT(CombType.IRIDIUM, new Materials[] {Materials.Iridium}, Voltage.IV);
- addProcessGT(CombType.OSMIUM, new Materials[] {Materials.Osmium}, Voltage.IV);
- addProcessGT(CombType.LITHIUM, new Materials[] {Materials.Lithium}, Voltage.MV);
- addProcessGT(CombType.ELECTROTINE, new Materials[] {Materials.Electrotine}, Voltage.MV);
+ addProcessGT(CombType.BAUXITE, new Materials[] { Materials.Bauxite }, Voltage.LV);
+ addProcessGT(CombType.ALUMINIUM, new Materials[] { Materials.Aluminium }, Voltage.LV);
+ addProcessGT(CombType.MANGANESE, new Materials[] { Materials.Manganese }, Voltage.LV);
+ addProcessGT(CombType.TITANIUM, new Materials[] { Materials.Titanium }, Voltage.EV);
+ addProcessGT(CombType.MAGNESIUM, new Materials[] { Materials.Magnesium }, Voltage.LV);
+ addProcessGT(CombType.CHROME, new Materials[] { Materials.Chrome }, Voltage.HV);
+ addProcessGT(CombType.TUNGSTEN, new Materials[] { Materials.Tungsten }, Voltage.IV);
+ addProcessGT(CombType.PLATINUM, new Materials[] { Materials.Platinum }, Voltage.HV);
+ addProcessGT(CombType.MOLYBDENUM, new Materials[] { Materials.Molybdenum }, Voltage.LV);
+ addProcessGT(CombType.IRIDIUM, new Materials[] { Materials.Iridium }, Voltage.IV);
+ addProcessGT(CombType.OSMIUM, new Materials[] { Materials.Osmium }, Voltage.IV);
+ addProcessGT(CombType.LITHIUM, new Materials[] { Materials.Lithium }, Voltage.MV);
+ addProcessGT(CombType.ELECTROTINE, new Materials[] { Materials.Electrotine }, Voltage.MV);
if (GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToItemStack(
CombType.SALT,
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Salt, 6),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.RockSalt, 6),
- ItemList.FR_Wax.get(1),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Saltpeter, 6)
- },
- new int[] {100 * 100, 100 * 100, 50 * 100, 25 * 100},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Salt, 6),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.RockSalt, 6), ItemList.FR_Wax.get(1),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Saltpeter, 6) },
+ new int[] { 100 * 100, 100 * 100, 50 * 100, 25 * 100 },
Voltage.MV,
160);
} else {
addCentrifugeToMaterial(
CombType.BAUXITE,
- new Materials[] {Materials.Bauxite, Materials.Aluminium},
- new int[] {75 * 100, 55 * 100},
+ new Materials[] { Materials.Bauxite, Materials.Aluminium },
+ new int[] { 75 * 100, 55 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.ALUMINIUM,
- new Materials[] {Materials.Aluminium, Materials.Bauxite},
- new int[] {60 * 100, 80 * 100},
+ new Materials[] { Materials.Aluminium, Materials.Bauxite },
+ new int[] { 60 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.MANGANESE,
- new Materials[] {
- Materials.Manganese,
- Materials.Grossular,
- Materials.Spessartine,
- Materials.Pyrolusite,
- Materials.Tantalite
- },
- new int[] {30 * 100, 100 * 100, 100 * 100, 100 * 100, 100 * 100},
+ new Materials[] { Materials.Manganese, Materials.Grossular, Materials.Spessartine,
+ Materials.Pyrolusite, Materials.Tantalite },
+ new int[] { 30 * 100, 100 * 100, 100 * 100, 100 * 100, 100 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.TITANIUM,
- new Materials[] {Materials.Titanium, Materials.Ilmenite, Materials.Bauxite, Materials.Rutile},
- new int[] {90 * 100, 80 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.Titanium, Materials.Ilmenite, Materials.Bauxite, Materials.Rutile },
+ new int[] { 90 * 100, 80 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.EV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.MAGNESIUM,
- new Materials[] {Materials.Magnesium, Materials.Magnesite},
- new int[] {100 * 100, 80 * 100},
+ new Materials[] { Materials.Magnesium, Materials.Magnesite },
+ new int[] { 100 * 100, 80 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.CHROME,
- new Materials[] {
- Materials.Chrome,
- Materials.Ruby,
- Materials.Chromite,
- Materials.Redstone,
- Materials.Neodymium,
- Materials.Bastnasite
- },
- new int[] {50 * 100, 100 * 100, 50 * 100, 100 * 100, 80 * 100, 80 * 100},
+ new Materials[] { Materials.Chrome, Materials.Ruby, Materials.Chromite, Materials.Redstone,
+ Materials.Neodymium, Materials.Bastnasite },
+ new int[] { 50 * 100, 100 * 100, 50 * 100, 100 * 100, 80 * 100, 80 * 100 },
new int[] {},
Voltage.HV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.TUNGSTEN,
- new Materials[] {Materials.Tungsten, Materials.Tungstate, Materials.Scheelite, Materials.Lithium},
- new int[] {50 * 100, 80 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.Tungsten, Materials.Tungstate, Materials.Scheelite, Materials.Lithium },
+ new int[] { 50 * 100, 80 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.PLATINUM,
- new Materials[] {Materials.Platinum, Materials.Cooperite, Materials.Palladium},
- new int[] {40 * 100, 40 * 100, 40 * 100},
+ new Materials[] { Materials.Platinum, Materials.Cooperite, Materials.Palladium },
+ new int[] { 40 * 100, 40 * 100, 40 * 100 },
new int[] {},
Voltage.HV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.MOLYBDENUM,
- new Materials[] {
- Materials.Molybdenum, Materials.Molybdenite, Materials.Powellite, Materials.Wulfenite
- },
- new int[] {100 * 100, 80 * 100, 75 * 100},
+ new Materials[] { Materials.Molybdenum, Materials.Molybdenite, Materials.Powellite,
+ Materials.Wulfenite },
+ new int[] { 100 * 100, 80 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.IRIDIUM,
- new Materials[] {Materials.Iridium, Materials.Osmium},
- new int[] {20 * 100, 15 * 100},
+ new Materials[] { Materials.Iridium, Materials.Osmium },
+ new int[] { 20 * 100, 15 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.OSMIUM,
- new Materials[] {Materials.Osmium, Materials.Iridium},
- new int[] {25 * 100, 15 * 100},
+ new Materials[] { Materials.Osmium, Materials.Iridium },
+ new int[] { 25 * 100, 15 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LITHIUM,
- new Materials[] {Materials.Lithium, Materials.Aluminium},
- new int[] {85 * 100, 75 * 100},
+ new Materials[] { Materials.Lithium, Materials.Aluminium },
+ new int[] { 85 * 100, 75 * 100 },
new int[] {},
Voltage.MV,
NI,
30 * 100);
addCentrifugeToItemStack(
CombType.SALT,
- new ItemStack[] {
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Salt, 6),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.RockSalt, 6),
- ItemList.FR_Wax.get(1),
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Saltpeter, 6)
- },
- new int[] {100 * 100, 100 * 100, 50 * 100, 25 * 100},
+ new ItemStack[] { GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Salt, 6),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.RockSalt, 6), ItemList.FR_Wax.get(1),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Saltpeter, 6) },
+ new int[] { 100 * 100, 100 * 100, 50 * 100, 25 * 100 },
Voltage.MV,
160);
}
// Radioactive Line
- addProcessGT(CombType.ALMANDINE, new Materials[] {Materials.Almandine}, Voltage.LV);
- addProcessGT(CombType.URANIUM, new Materials[] {Materials.Uranium}, Voltage.EV);
- addProcessGT(CombType.PLUTONIUM, new Materials[] {Materials.Plutonium}, Voltage.EV);
- addProcessGT(CombType.NAQUADAH, new Materials[] {Materials.Naquadah}, Voltage.IV);
- addProcessGT(CombType.NAQUADRIA, new Materials[] {Materials.Naquadria}, Voltage.LuV);
- addProcessGT(CombType.THORIUM, new Materials[] {Materials.Thorium}, Voltage.EV);
- addProcessGT(CombType.LUTETIUM, new Materials[] {Materials.Lutetium}, Voltage.IV);
- addProcessGT(CombType.AMERICIUM, new Materials[] {Materials.Americium}, Voltage.LuV);
- addProcessGT(CombType.NEUTRONIUM, new Materials[] {Materials.Neutronium}, Voltage.UHV);
+ addProcessGT(CombType.ALMANDINE, new Materials[] { Materials.Almandine }, Voltage.LV);
+ addProcessGT(CombType.URANIUM, new Materials[] { Materials.Uranium }, Voltage.EV);
+ addProcessGT(CombType.PLUTONIUM, new Materials[] { Materials.Plutonium }, Voltage.EV);
+ addProcessGT(CombType.NAQUADAH, new Materials[] { Materials.Naquadah }, Voltage.IV);
+ addProcessGT(CombType.NAQUADRIA, new Materials[] { Materials.Naquadria }, Voltage.LuV);
+ addProcessGT(CombType.THORIUM, new Materials[] { Materials.Thorium }, Voltage.EV);
+ addProcessGT(CombType.LUTETIUM, new Materials[] { Materials.Lutetium }, Voltage.IV);
+ addProcessGT(CombType.AMERICIUM, new Materials[] { Materials.Americium }, Voltage.LuV);
+ addProcessGT(CombType.NEUTRONIUM, new Materials[] { Materials.Neutronium }, Voltage.UHV);
if (!GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.ALMANDINE,
- new Materials[] {Materials.Almandine, Materials.Pyrope, Materials.Sapphire, Materials.GreenSapphire
- },
- new int[] {90 * 100, 80 * 100, 75 * 100, 75 * 100},
+ new Materials[] { Materials.Almandine, Materials.Pyrope, Materials.Sapphire,
+ Materials.GreenSapphire },
+ new int[] { 90 * 100, 80 * 100, 75 * 100, 75 * 100 },
new int[] {},
Voltage.ULV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.URANIUM,
- new Materials[] {Materials.Uranium, Materials.Pitchblende, Materials.Uraninite, Materials.Uranium235
- },
- new int[] {50 * 100, 65 * 100, 75 * 100, 50 * 100},
+ new Materials[] { Materials.Uranium, Materials.Pitchblende, Materials.Uraninite,
+ Materials.Uranium235 },
+ new int[] { 50 * 100, 65 * 100, 75 * 100, 50 * 100 },
new int[] {},
Voltage.EV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.PLUTONIUM,
- new Materials[] {Materials.Plutonium, Materials.Uranium235},
- new int[] {10, 5},
+ new Materials[] { Materials.Plutonium, Materials.Uranium235 },
+ new int[] { 10, 5 },
new int[] {},
Voltage.EV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.NAQUADAH,
- new Materials[] {Materials.Naquadah, Materials.NaquadahEnriched, Materials.Naquadria},
- new int[] {10 * 100, 5 * 100, 5 * 100},
+ new Materials[] { Materials.Naquadah, Materials.NaquadahEnriched, Materials.Naquadria },
+ new int[] { 10 * 100, 5 * 100, 5 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.NAQUADRIA,
- new Materials[] {Materials.Naquadria, Materials.NaquadahEnriched, Materials.Naquadah},
- new int[] {10 * 100, 10 * 100, 15 * 100},
+ new Materials[] { Materials.Naquadria, Materials.NaquadahEnriched, Materials.Naquadah },
+ new int[] { 10 * 100, 10 * 100, 15 * 100 },
new int[] {},
Voltage.LuV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.THORIUM,
- new Materials[] {Materials.Thorium, Materials.Uranium, Materials.Coal},
- new int[] {75 * 100, 75 * 100 * 100, 95 * 100},
+ new Materials[] { Materials.Thorium, Materials.Uranium, Materials.Coal },
+ new int[] { 75 * 100, 75 * 100 * 100, 95 * 100 },
new int[] {},
Voltage.EV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LUTETIUM,
- new Materials[] {Materials.Lutetium, Materials.Thorium},
- new int[] {35 * 100, 55 * 100},
+ new Materials[] { Materials.Lutetium, Materials.Thorium },
+ new int[] { 35 * 100, 55 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.AMERICIUM,
- new Materials[] {Materials.Americium, Materials.Lutetium},
- new int[] {25 * 100, 45 * 100},
+ new Materials[] { Materials.Americium, Materials.Lutetium },
+ new int[] { 25 * 100, 45 * 100 },
new int[] {},
Voltage.LuV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.NEUTRONIUM,
- new Materials[] {Materials.Neutronium, Materials.Americium},
- new int[] {15 * 100, 35 * 100},
+ new Materials[] { Materials.Neutronium, Materials.Americium },
+ new int[] { 15 * 100, 35 * 100 },
new int[] {},
Voltage.UHV,
NI,
@@ -1264,126 +1153,96 @@ public class ItemComb extends Item {
// Twilight
addCentrifugeToItemStack(
CombType.NAGA,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 4),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.NagaScaleChip", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.NagaScaleFragment", 1L, 0),
- ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 33 * 100, 8 * 100, 30 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 4),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.NagaScaleChip", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.NagaScaleFragment", 1L, 0), ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 33 * 100, 8 * 100, 30 * 100 },
Voltage.MV);
addCentrifugeToItemStack(
CombType.LICH,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 5),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.LichBoneChip", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.LichBoneFragment", 1L, 0),
- ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 33 * 100, 8 * 100, 30 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 5),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.LichBoneChip", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.LichBoneFragment", 1L, 0), ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 33 * 100, 8 * 100, 30 * 100 },
Voltage.HV);
addCentrifugeToItemStack(
CombType.HYDRA,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 1),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.FieryBloodDrop", 1L, 0),
- GT_Bees.drop.getStackForType(DropType.HYDRA),
- ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 33 * 100, 8 * 100, 30 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 1),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.FieryBloodDrop", 1L, 0),
+ GT_Bees.drop.getStackForType(DropType.HYDRA), ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 33 * 100, 8 * 100, 30 * 100 },
Voltage.HV);
addCentrifugeToItemStack(
CombType.URGHAST,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 2),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.CarminiteChip", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.CarminiteFragment", 1L, 0),
- ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 33 * 100, 8 * 100, 30 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 2),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.CarminiteChip", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.CarminiteFragment", 1L, 0), ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 33 * 100, 8 * 100, 30 * 100 },
Voltage.EV);
addCentrifugeToItemStack(
CombType.SNOWQUEEN,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 3),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.SnowQueenBloodDrop", 1L, 0),
- GT_Bees.drop.getStackForType(DropType.SNOW_QUEEN),
- ItemList.FR_Wax.get(1)
- },
- new int[] {5 * 100, 33 * 100, 8 * 100, 30 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 3),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.SnowQueenBloodDrop", 1L, 0),
+ GT_Bees.drop.getStackForType(DropType.SNOW_QUEEN), ItemList.FR_Wax.get(1) },
+ new int[] { 5 * 100, 33 * 100, 8 * 100, 30 * 100 },
Voltage.EV);
// HEE
addCentrifugeToItemStack(
CombType.ENDDUST,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.End),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO),
- },
- new int[] {20 * 100, 15 * 100, 10 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.End),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO), },
+ new int[] { 20 * 100, 15 * 100, 10 * 100 },
Voltage.HV);
addCentrifugeToItemStack(
CombType.STARDUST,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Stardust),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO)
- },
- new int[] {20 * 100, 15 * 100, 10 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Stardust),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO) },
+ new int[] { 20 * 100, 15 * 100, 10 * 100 },
Voltage.HV);
addCentrifugeToItemStack(
CombType.ECTOPLASMA,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Ectoplasma),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO)
- },
- new int[] {25 * 100, 10 * 100, 15 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Ectoplasma),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO) },
+ new int[] { 25 * 100, 10 * 100, 15 * 100 },
Voltage.EV);
addCentrifugeToItemStack(
CombType.ARCANESHARD,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Arcaneshard),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO)
- },
- new int[] {25 * 100, 10 * 100, 15 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Arcaneshard),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO) },
+ new int[] { 25 * 100, 10 * 100, 15 * 100 },
Voltage.EV);
addCentrifugeToItemStack(
CombType.DRAGONESSENCE,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Dragonessence),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO)
- },
- new int[] {30 * 100, (int) (7.5 * 100), 20 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Dragonessence),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO) },
+ new int[] { 30 * 100, (int) (7.5 * 100), 20 * 100 },
Voltage.IV);
addCentrifugeToItemStack(
CombType.ENDERMAN,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Enderman),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO)
- },
- new int[] {3000, 750, 2000},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Enderman),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO) },
+ new int[] { 3000, 750, 2000 },
Voltage.IV);
addCentrifugeToItemStack(
CombType.SILVERFISH,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Silverfish),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO),
- new ItemStack(Items.spawn_egg, 1, 60)
- },
- new int[] {25 * 100, 10 * 100, 20 * 100, 15 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Silverfish),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO), new ItemStack(Items.spawn_egg, 1, 60) },
+ new int[] { 25 * 100, 10 * 100, 20 * 100, 15 * 100 },
Voltage.EV);
- addProcessGT(CombType.ENDIUM, new Materials[] {Materials.HeeEndium}, Voltage.HV);
+ addProcessGT(CombType.ENDIUM, new Materials[] { Materials.HeeEndium }, Voltage.HV);
if (!GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.ENDIUM,
- new Materials[] {Materials.HeeEndium},
- new int[] {50 * 100},
+ new Materials[] { Materials.HeeEndium },
+ new int[] { 50 * 100 },
new int[] {},
Voltage.HV,
GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
@@ -1391,143 +1250,132 @@ public class ItemComb extends Item {
}
addCentrifugeToItemStack(
CombType.RUNEI,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfPowerFragment", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfAgilityFragment", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfVigorFragment", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfDefenseFragment", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfMagicFragment", 1L, 0)
- },
- new int[] {25 * 100, 5 * 100, 5 * 100, 5 * 100, 5 * 100, 5 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfPowerFragment", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfAgilityFragment", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfVigorFragment", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfDefenseFragment", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfMagicFragment", 1L, 0) },
+ new int[] { 25 * 100, 5 * 100, 5 * 100, 5 * 100, 5 * 100, 5 * 100 },
Voltage.IV);
addCentrifugeToItemStack(
CombType.RUNEII,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfVoidFragment", 1L, 0)
- },
- new int[] {50 * 100, (int) (2.5 * 100)},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.RuneOfVoidFragment", 1L, 0) },
+ new int[] { 50 * 100, (int) (2.5 * 100) },
Voltage.IV);
addCentrifugeToItemStack(
CombType.FIREESSENSE,
- new ItemStack[] {
- GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
- GT_Bees.propolis.getStackForType(PropolisType.Fireessence),
- GT_Bees.drop.getStackForType(DropType.ENDERGOO)
- },
- new int[] {30 * 100, (int) (7.5 * 100), 20 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("MagicBees", "wax", 1L, 0),
+ GT_Bees.propolis.getStackForType(PropolisType.Fireessence),
+ GT_Bees.drop.getStackForType(DropType.ENDERGOO) },
+ new int[] { 30 * 100, (int) (7.5 * 100), 20 * 100 },
Voltage.IV);
// Walrus Recipe
if (Loader.isModLoaded("extracells")) {
addCentrifugeToItemStack(
CombType.WALRUS,
- new ItemStack[] {GT_ModHandler.getModItem("extracells", "walrus", 1L, 0)},
- new int[] {100 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem("extracells", "walrus", 1L, 0) },
+ new int[] { 100 * 100 },
Voltage.LV);
}
// Space Line
addCentrifugeToItemStack(
CombType.SPACE,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- ItemList.FR_RefractoryWax.get(1L),
- GT_Bees.drop.getStackForType(DropType.OXYGEN),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.CoinSpace", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 15 * 100, 5 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L), ItemList.FR_RefractoryWax.get(1L),
+ GT_Bees.drop.getStackForType(DropType.OXYGEN),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.CoinSpace", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 15 * 100, 5 * 100 },
Voltage.HV);
- addProcessGT(CombType.METEORICIRON, new Materials[] {Materials.MeteoricIron}, Voltage.HV);
- addProcessGT(CombType.DESH, new Materials[] {Materials.Desh}, Voltage.EV);
- addProcessGT(CombType.LEDOX, new Materials[] {Materials.Ledox}, Voltage.EV);
- addProcessGT(CombType.CALLISTOICE, new Materials[] {Materials.CallistoIce}, Voltage.IV);
- addProcessGT(CombType.MYTRYL, new Materials[] {Materials.Mytryl}, Voltage.IV);
- addProcessGT(CombType.QUANTIUM, new Materials[] {Materials.Quantium}, Voltage.IV);
- addProcessGT(CombType.ORIHARUKON, new Materials[] {Materials.Oriharukon}, Voltage.IV);
- addProcessGT(CombType.MYSTERIOUSCRYSTAL, new Materials[] {Materials.MysteriousCrystal}, Voltage.LuV);
+ addProcessGT(CombType.METEORICIRON, new Materials[] { Materials.MeteoricIron }, Voltage.HV);
+ addProcessGT(CombType.DESH, new Materials[] { Materials.Desh }, Voltage.EV);
+ addProcessGT(CombType.LEDOX, new Materials[] { Materials.Ledox }, Voltage.EV);
+ addProcessGT(CombType.CALLISTOICE, new Materials[] { Materials.CallistoIce }, Voltage.IV);
+ addProcessGT(CombType.MYTRYL, new Materials[] { Materials.Mytryl }, Voltage.IV);
+ addProcessGT(CombType.QUANTIUM, new Materials[] { Materials.Quantium }, Voltage.IV);
+ addProcessGT(CombType.ORIHARUKON, new Materials[] { Materials.Oriharukon }, Voltage.IV);
+ addProcessGT(CombType.MYSTERIOUSCRYSTAL, new Materials[] { Materials.MysteriousCrystal }, Voltage.LuV);
addCentrifugeToMaterial(
CombType.MYSTERIOUSCRYSTAL,
- new Materials[] {Materials.MysteriousCrystal},
- new int[] {
- (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 40) * 100,
- (GT_Mod.gregtechproxy.mNerfedCombs ? 15 : 50) * 100
- },
+ new Materials[] { Materials.MysteriousCrystal },
+ new int[] { (GT_Mod.gregtechproxy.mNerfedCombs ? 10 : 40) * 100,
+ (GT_Mod.gregtechproxy.mNerfedCombs ? 15 : 50) * 100 },
new int[] {},
Voltage.LuV,
512,
NI,
50 * 100);
- addProcessGT(CombType.BLACKPLUTONIUM, new Materials[] {Materials.BlackPlutonium}, Voltage.LuV);
- addProcessGT(CombType.TRINIUM, new Materials[] {Materials.Trinium}, Voltage.ZPM);
+ addProcessGT(CombType.BLACKPLUTONIUM, new Materials[] { Materials.BlackPlutonium }, Voltage.LuV);
+ addProcessGT(CombType.TRINIUM, new Materials[] { Materials.Trinium }, Voltage.ZPM);
if (!GT_Mod.gregtechproxy.mNerfedCombs) {
addCentrifugeToMaterial(
CombType.METEORICIRON,
- new Materials[] {Materials.MeteoricIron, Materials.Iron},
- new int[] {85 * 100, 100 * 100},
+ new Materials[] { Materials.MeteoricIron, Materials.Iron },
+ new int[] { 85 * 100, 100 * 100 },
new int[] {},
Voltage.HV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.DESH,
- new Materials[] {Materials.Desh, Materials.Titanium},
- new int[] {75 * 100, 50 * 100},
+ new Materials[] { Materials.Desh, Materials.Titanium },
+ new int[] { 75 * 100, 50 * 100 },
new int[] {},
Voltage.EV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.LEDOX,
- new Materials[] {Materials.Ledox, Materials.CallistoIce, Materials.Lead},
- new int[] {65 * 100, 55 * 100, 85 * 100},
+ new Materials[] { Materials.Ledox, Materials.CallistoIce, Materials.Lead },
+ new int[] { 65 * 100, 55 * 100, 85 * 100 },
new int[] {},
Voltage.EV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.CALLISTOICE,
- new Materials[] {Materials.CallistoIce, Materials.Ledox, Materials.Lead},
- new int[] {65 * 100, 75 * 100, 100 * 100},
+ new Materials[] { Materials.CallistoIce, Materials.Ledox, Materials.Lead },
+ new int[] { 65 * 100, 75 * 100, 100 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.MYTRYL,
- new Materials[] {Materials.Mytryl, Materials.Mithril},
- new int[] {55 * 100, 50 * 100},
+ new Materials[] { Materials.Mytryl, Materials.Mithril },
+ new int[] { 55 * 100, 50 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.QUANTIUM,
- new Materials[] {Materials.Quantium, Materials.Osmium},
- new int[] {50 * 100, 60 * 100},
+ new Materials[] { Materials.Quantium, Materials.Osmium },
+ new int[] { 50 * 100, 60 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.ORIHARUKON,
- new Materials[] {Materials.Oriharukon, Materials.Lead},
- new int[] {50 * 100, 75 * 100},
+ new Materials[] { Materials.Oriharukon, Materials.Lead },
+ new int[] { 50 * 100, 75 * 100 },
new int[] {},
Voltage.IV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.BLACKPLUTONIUM,
- new Materials[] {Materials.BlackPlutonium, Materials.Plutonium},
- new int[] {25 * 100, 50 * 100},
+ new Materials[] { Materials.BlackPlutonium, Materials.Plutonium },
+ new int[] { 25 * 100, 50 * 100 },
new int[] {},
Voltage.LuV,
NI,
30 * 100);
addCentrifugeToMaterial(
CombType.TRINIUM,
- new Materials[] {Materials.Trinium, Materials.Iridium},
- new int[] {35 * 100, 45 * 100},
+ new Materials[] { Materials.Trinium, Materials.Iridium },
+ new int[] { 35 * 100, 45 * 100 },
new int[] {},
Voltage.ZPM,
NI,
@@ -1537,159 +1385,135 @@ public class ItemComb extends Item {
// Planet Line
addCentrifugeToItemStack(
CombType.MOON,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.MoonStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.MoonStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.MV,
300);
addCentrifugeToItemStack(
CombType.MARS,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.MarsStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.MarsStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.HV,
300);
addCentrifugeToItemStack(
CombType.JUPITER,
- new ItemStack[] {
- GT_ModHandler.getModItem(MOD_ID_DC, "item.IoStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.EuropaIceDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.EuropaStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.GanymedeStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.CallistoStoneDust", 1L, 0),
- GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.CallistoIce, 1L),
- ItemList.FR_Wax.get(1L)
- },
- new int[] {30 * 100, 30 * 100, 30 * 100, 30 * 100, 30 * 100, 5 * 100, 50 * 100},
+ new ItemStack[] { GT_ModHandler.getModItem(MOD_ID_DC, "item.IoStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.EuropaIceDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.EuropaStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.GanymedeStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.CallistoStoneDust", 1L, 0),
+ GT_OreDictUnificator.get(OrePrefixes.dustTiny, Materials.CallistoIce, 1L),
+ ItemList.FR_Wax.get(1L) },
+ new int[] { 30 * 100, 30 * 100, 30 * 100, 30 * 100, 30 * 100, 5 * 100, 50 * 100 },
Voltage.HV,
300);
addCentrifugeToItemStack(
CombType.MERCURY,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.MercuryCoreDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.MercuryStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.MercuryCoreDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.MercuryStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.EV,
300);
addCentrifugeToItemStack(
CombType.VENUS,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.VenusStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.VenusStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.EV,
300);
addCentrifugeToItemStack(
CombType.SATURN,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.EnceladusStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.TitanStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.EnceladusStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.TitanStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.IV,
300);
addCentrifugeToItemStack(
CombType.URANUS,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.MirandaStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.OberonStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.MirandaStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.OberonStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.IV,
300);
addCentrifugeToItemStack(
CombType.NEPTUN,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.ProteusStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.TritonStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.ProteusStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.TritonStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.IV,
300);
addCentrifugeToItemStack(
CombType.PLUTO,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.PlutoStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.PlutoIceDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.PlutoStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.PlutoIceDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.LuV,
300);
addCentrifugeToItemStack(
CombType.HAUMEA,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.HaumeaStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.HaumeaStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.LuV,
300);
addCentrifugeToItemStack(
CombType.MAKEMAKE,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.MakeMakeStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.MakeMakeStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.LuV,
300);
addCentrifugeToItemStack(
CombType.CENTAURI,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.CentauriASurfaceDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.CentauriAStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.CentauriASurfaceDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.CentauriAStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.ZPM,
300);
addCentrifugeToItemStack(
CombType.TCETI,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.TCetiEStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.TCetiEStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.ZPM,
300);
addCentrifugeToItemStack(
CombType.BARNARDA,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.BarnardaEStoneDust", 1L, 0),
- GT_ModHandler.getModItem(MOD_ID_DC, "item.BarnardaFStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.BarnardaEStoneDust", 1L, 0),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.BarnardaFStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100, 30 * 100 },
Voltage.ZPM,
300);
addCentrifugeToItemStack(
CombType.VEGA,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem(MOD_ID_DC, "item.VegaBStoneDust", 1L, 0)
- },
- new int[] {50 * 100, 30 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem(MOD_ID_DC, "item.VegaBStoneDust", 1L, 0) },
+ new int[] { 50 * 100, 30 * 100 },
Voltage.ZPM,
300);
if (Loader.isModLoaded("GalaxySpace")) {
addCentrifugeToItemStack(
CombType.SEAWEED,
- new ItemStack[] {
- ItemList.FR_Wax.get(1L), GT_ModHandler.getModItem("GalaxySpace", "tcetiedandelions", 1L, 0)
- },
- new int[] {50 * 100, 100 * 100},
+ new ItemStack[] { ItemList.FR_Wax.get(1L),
+ GT_ModHandler.getModItem("GalaxySpace", "tcetiedandelions", 1L, 0) },
+ new int[] { 50 * 100, 100 * 100 },
Voltage.UV,
100);
}
// Infinity Line
addCentrifugeToMaterial(
CombType.INFINITYCATALYST,
- new Materials[] {Materials.InfinityCatalyst, Materials.Neutronium},
- new int[] {(int) (25 * 100), 20 * 100},
+ new Materials[] { Materials.InfinityCatalyst, Materials.Neutronium },
+ new int[] { (int) (25 * 100), 20 * 100 },
new int[] {},
Voltage.ZPM,
100,
@@ -1707,16 +1531,17 @@ public class ItemComb extends Item {
// yes, unknowwater. Its not my typo, its how it is spelled. Stupid game.
addFluidExtractorProcess(CombType.UNKNOWNWATER, FluidRegistry.getFluidStack("unknowwater", 250), Voltage.ZPM);
/**
- * The Centrifuge Recipes for Infused Shards and Nether/End-Shard from the Infused Shard Line are below the NobleGas
- * Lines for Xenon and co. in Gt_MachineRecipeLoader.java In Lines 1525
- * **/
+ * The Centrifuge Recipes for Infused Shards and Nether/End-Shard from the Infused Shard Line are below the
+ * NobleGas Lines for Xenon and co. in Gt_MachineRecipeLoader.java In Lines 1525
+ **/
}
/**
* Currently only used for CombType.MOLYBDENUM
+ *
* @param circuitNumber should not conflict with addProcessGT
*
- * **/
+ **/
public void addAutoclaveProcess(CombType comb, Materials aMaterial, Voltage volt, int circuitNumber) {
if (GT_OreDictUnificator.get(OrePrefixes.crushedPurified, aMaterial, 4) == NI) return;
RA.addAutoclaveRecipe(
@@ -1737,18 +1562,19 @@ public class ItemComb extends Item {
null,
fluid,
100 * 100,
- (fluid.getFluid().getDensity() * 128 > 0
- ? (int) (fluid.getFluid().getDensity() * 100)
- : 128),
+ (fluid.getFluid().getDensity() * 128 > 0 ? (int) (fluid.getFluid().getDensity() * 100) : 128),
volt.getSimpleEnergy() / 2);
}
/**
- * this only adds Chemical and AutoClave process.
- * If you need Centrifuge recipe. use addCentrifugeToMaterial or addCentrifugeToItemStack
- * @param volt This determine the required Tier of process for this recipes. This decide the required aEU/t, progress time, required additional UU-Matter, requirement of cleanRoom, needed fluid stack for Chemical.
+ * this only adds Chemical and AutoClave process. If you need Centrifuge recipe. use addCentrifugeToMaterial or
+ * addCentrifugeToItemStack
+ *
+ * @param volt This determine the required Tier of process for this recipes. This decide the required aEU/t,
+ * progress time, required additional UU-Matter, requirement of cleanRoom, needed fluid stack for
+ * Chemical.
* @param aMaterial result of Material that should be generated by this process.
- * **/
+ **/
public void addProcessGT(CombType comb, Materials[] aMaterial, Voltage volt) {
ItemStack tComb = getStackForType(comb);
for (int i = 0; i < aMaterial.length; i++) {
@@ -1816,35 +1642,30 @@ public class ItemComb extends Item {
}
/**
- * this method only adds Centrifuge based on Material. If volt is lower than MV than it will also adds forestry centrifuge recipe.
- * @param comb BeeComb
- * @param aMaterial resulting Material of processing. can be more than 6. but over 6 will be ignored in Gregtech Centrifuge.
- * @param chance chance to get result, 10000 == 100%
- * @param volt required Voltage Tier for this recipe, this also affect the duration, amount of UU-Matter, and needed liquid type and amount for chemical reactor
- * @param stackSize This parameter can be null, in that case stack size will be just 1. This handle the stackSize of the resulting Item, and Also the Type of Item. if this value is multiple of 9, than related Material output will be dust, if this value is multiple of 4 than output will be Small dust, else the output will be Tiny dust
- * @param beeWax if this is null, then the comb will product default Bee wax. But if aMaterial is more than 5, beeWax will be ignored in Gregtech Centrifuge.
+ * this method only adds Centrifuge based on Material. If volt is lower than MV than it will also adds forestry
+ * centrifuge recipe.
+ *
+ * @param comb BeeComb
+ * @param aMaterial resulting Material of processing. can be more than 6. but over 6 will be ignored in Gregtech
+ * Centrifuge.
+ * @param chance chance to get result, 10000 == 100%
+ * @param volt required Voltage Tier for this recipe, this also affect the duration, amount of UU-Matter, and
+ * needed liquid type and amount for chemical reactor
+ * @param stackSize This parameter can be null, in that case stack size will be just 1. This handle the stackSize of
+ * the resulting Item, and Also the Type of Item. if this value is multiple of 9, than related
+ * Material output will be dust, if this value is multiple of 4 than output will be Small dust,
+ * else the output will be Tiny dust
+ * @param beeWax if this is null, then the comb will product default Bee wax. But if aMaterial is more than 5,
+ * beeWax will be ignored in Gregtech Centrifuge.
* @param waxChance have same format like "chance"
**/
- public void addCentrifugeToMaterial(
- CombType comb,
- Materials[] aMaterial,
- int[] chance,
- int[] stackSize,
- Voltage volt,
- ItemStack beeWax,
- int waxChance) {
+ public void addCentrifugeToMaterial(CombType comb, Materials[] aMaterial, int[] chance, int[] stackSize,
+ Voltage volt, ItemStack beeWax, int waxChance) {
addCentrifugeToMaterial(comb, aMaterial, chance, stackSize, volt, volt.getSimpleTime(), beeWax, waxChance);
}
- public void addCentrifugeToMaterial(
- CombType comb,
- Materials[] aMaterial,
- int[] chance,
- int[] stackSize,
- Voltage volt,
- int duration,
- ItemStack beeWax,
- int waxChance) {
+ public void addCentrifugeToMaterial(CombType comb, Materials[] aMaterial, int[] chance, int[] stackSize,
+ Voltage volt, int duration, ItemStack beeWax, int waxChance) {
ItemStack[] aOutPut = new ItemStack[aMaterial.length + 1];
stackSize = Arrays.copyOf(stackSize, aMaterial.length);
chance = Arrays.copyOf(chance, aOutPut.length);
@@ -1871,7 +1692,7 @@ public class ItemComb extends Item {
}
/**
- * @param volt required Tier of system. If it's lower than MV, it will also add forestry centrifuge.
+ * @param volt required Tier of system. If it's lower than MV, it will also add forestry centrifuge.
* @param aItem can be more than 6. but Over 6 will be ignored in Gregtech Centrifuge.
**/
public void addCentrifugeToItemStack(CombType comb, ItemStack[] aItem, int[] chance, Voltage volt) {
@@ -1923,6 +1744,7 @@ public class ItemComb extends Item {
}
enum Voltage {
+
ULV,
LV,
MV,
@@ -1942,11 +1764,13 @@ public class ItemComb extends Item {
public int getVoltage() {
return (int) V[this.ordinal()];
}
- /**@return aEU/t needed for chemical and autoclave process related to the Tier**/
+
+ /** @return aEU/t needed for chemical and autoclave process related to the Tier **/
public int getVoltageFromEU() {
return (int) Math.max(Math.floor(Math.log(2 * this.getVoltage()) / Math.log(4) - 1), 0);
}
- /**@return Voltage tier according to EU provided. 0 = ULV, 1 = LV, 2 = MV ...**/
+
+ /** @return Voltage tier according to EU provided. 0 = ULV, 1 = LV, 2 = MV ... **/
public int getChemicalEnergy() {
return this.getVoltage() * 3 / 4;
}
@@ -1954,7 +1778,8 @@ public class ItemComb extends Item {
public int getAutoClaveEnergy() {
return (int) ((this.getVoltage() * 3 / 4) * (Math.max(1, Math.pow(2, 5 - this.ordinal()))));
}
- /**@return FluidStack needed for chemical process related to the Tier**/
+
+ /** @return FluidStack needed for chemical process related to the Tier **/
public FluidStack getComplexChemical() {
if (this.compareTo(Voltage.MV) < 0) {
return Materials.HydrofluoricAcid.getFluid((this.compareTo(Voltage.ULV) > 0) ? 1000 : 500);
@@ -1968,7 +1793,8 @@ public class ItemComb extends Item {
return NF;
}
}
- /**@return FluidStack needed for chemical process related to the Tier**/
+
+ /** @return FluidStack needed for chemical process related to the Tier **/
public FluidStack getFluidAccordingToCombTier() {
// checking what Voltage tier the Comb is
// cascading from IV to UMV since all recipes use HydrofluiricAcid
@@ -1976,38 +1802,41 @@ public class ItemComb extends Item {
int fluidAmount = this.getFluidAmount();
switch (this.getVoltageFromEU()) {
case 0:
- /**ULV**/
+ /** ULV **/
return Materials.Water.getFluid(fluidAmount);
case 1:
- /**LV**/
+ /** LV **/
return Materials.SulfuricAcid.getFluid(fluidAmount);
case 2:
- /**MV**/
+ /** MV **/
return Materials.HydrochloricAcid.getFluid(fluidAmount);
case 3:
- /**HV**/
+ /** HV **/
return Materials.PhosphoricAcid.getFluid(fluidAmount);
case 4:
- /**EV**/
+ /** EV **/
return Materials.HydrofluoricAcid.getFluid(this.getFluidAmount());
default:
return Materials.PhthalicAcid.getFluid(fluidAmount);
}
}
- /**@return additional required UU-Matter amount for Autoclave process related to the Tier**/
+
+ /** @return additional required UU-Matter amount for Autoclave process related to the Tier **/
public int getUUAmplifier() {
return 9 * ((this.compareTo(Voltage.MV) < 0) ? 1 : this.compareTo(Voltage.MV));
}
- /**@return duration needed for Chemical process related to the Tier**/
+
+ /** @return duration needed for Chemical process related to the Tier **/
public int getComplexTime() {
return 64 + this.ordinal() * 32;
}
- /**@return Fluid amount needed for Chemical process related to the Tier**/
+
+ /** @return Fluid amount needed for Chemical process related to the Tier **/
public int getFluidAmount() {
return 9 * this.getSimpleTime() / 3;
}
- /**@return duration needed for Centrifuge process related to the Tier**/
+ /** @return duration needed for Centrifuge process related to the Tier **/
public int getSimpleTime() {
if (!GT_Mod.gregtechproxy.mNerfedCombs) {
return 96 + this.ordinal() * 32;
@@ -2016,7 +1845,8 @@ public class ItemComb extends Item {
return 128 * (Math.max(1, this.ordinal()));
}
}
- /**@return aEU/t needed for Centrifuge process related to the Tier**/
+
+ /** @return aEU/t needed for Centrifuge process related to the Tier **/
public int getSimpleEnergy() {
if (this == Voltage.ULV) {
return 5;
diff --git a/src/main/java/gregtech/common/items/ItemDrop.java b/src/main/java/gregtech/common/items/ItemDrop.java
index 37b9d583c5..4887e47722 100644
--- a/src/main/java/gregtech/common/items/ItemDrop.java
+++ b/src/main/java/gregtech/common/items/ItemDrop.java
@@ -3,6 +3,16 @@ package gregtech.common.items;
import static gregtech.api.enums.GT_Values.MOD_ID;
import static gregtech.api.enums.GT_Values.MOD_ID_DC;
+import java.util.List;
+
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import cpw.mods.fml.common.Loader;
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.relauncher.Side;
@@ -12,16 +22,9 @@ import forestry.api.recipes.RecipeManagers;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.Materials;
import gregtech.api.util.GT_ModHandler;
-import java.util.List;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
public class ItemDrop extends Item {
+
@SideOnly(Side.CLIENT)
private IIcon secondIcon;
@@ -104,7 +107,7 @@ public class ItemDrop extends Item {
8);
RecipeManagers.squeezerManager.addRecipe(
40,
- new ItemStack[] {tDrop},
+ new ItemStack[] { tDrop },
Materials.OilHeavy.getFluid(100L),
GT_ModHandler.getModItem("Forestry", "propolis", 1L, 0),
30);
@@ -117,7 +120,7 @@ public class ItemDrop extends Item {
8);
RecipeManagers.squeezerManager.addRecipe(
40,
- new ItemStack[] {tDrop},
+ new ItemStack[] { tDrop },
new FluidStack(FluidRegistry.getFluid("ic2coolant"), 100),
GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 0),
30);
@@ -130,7 +133,7 @@ public class ItemDrop extends Item {
8);
RecipeManagers.squeezerManager.addRecipe(
40,
- new ItemStack[] {tDrop},
+ new ItemStack[] { tDrop },
new FluidStack(FluidRegistry.getFluid("ic2hotcoolant"), 100),
GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 2),
30);
@@ -151,7 +154,7 @@ public class ItemDrop extends Item {
2);
RecipeManagers.squeezerManager.addRecipe(
400,
- new ItemStack[] {tDrop},
+ new ItemStack[] { tDrop },
new FluidStack(FluidRegistry.getFluid("ic2coolant"), 100),
GT_ModHandler.getModItem("MagicBees", "propolis", 1L, 3),
30);
@@ -172,7 +175,7 @@ public class ItemDrop extends Item {
8);
RecipeManagers.squeezerManager.addRecipe(
400,
- new ItemStack[] {tDrop},
+ new ItemStack[] { tDrop },
new FluidStack(FluidRegistry.getFluid("ic2coolant"), 100),
GT_ModHandler.getModItem("ExtraBees", "propolis", 1L, 2),
30);
@@ -185,8 +188,8 @@ public class ItemDrop extends Item {
GT_Values.RA.addFluidExtractionRecipe(tDrop, aOutput2, aOutput, aChance, 32, aEUt);
}
- public void addProcessLV(
- ItemStack tDrop, FluidStack aOutput, ItemStack aOutput2, int aChance, int aDuration, int aEUt) {
+ public void addProcessLV(ItemStack tDrop, FluidStack aOutput, ItemStack aOutput2, int aChance, int aDuration,
+ int aEUt) {
GT_Values.RA.addFluidExtractionRecipe(tDrop, aOutput2, aOutput, aChance, aDuration, aEUt);
}
diff --git a/src/main/java/gregtech/common/items/ItemPollen.java b/src/main/java/gregtech/common/items/ItemPollen.java
index 0532d52f9d..b2e2462585 100644
--- a/src/main/java/gregtech/common/items/ItemPollen.java
+++ b/src/main/java/gregtech/common/items/ItemPollen.java
@@ -2,18 +2,21 @@ package gregtech.common.items;
import static gregtech.api.enums.GT_Values.MOD_ID;
-import cpw.mods.fml.common.registry.GameRegistry;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import forestry.api.core.Tabs;
import java.util.List;
+
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
+import cpw.mods.fml.common.registry.GameRegistry;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import forestry.api.core.Tabs;
+
public class ItemPollen extends Item {
+
@SideOnly(Side.CLIENT)
private IIcon secondIcon;
diff --git a/src/main/java/gregtech/common/items/ItemPropolis.java b/src/main/java/gregtech/common/items/ItemPropolis.java
index dbb5f45786..c2d46a8249 100644
--- a/src/main/java/gregtech/common/items/ItemPropolis.java
+++ b/src/main/java/gregtech/common/items/ItemPropolis.java
@@ -3,6 +3,15 @@ package gregtech.common.items;
import static gregtech.api.enums.GT_Values.MOD_ID;
import static gregtech.api.enums.GT_Values.MOD_ID_DC;
+import java.util.List;
+
+import net.minecraft.client.renderer.texture.IIconRegister;
+import net.minecraft.creativetab.CreativeTabs;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IIcon;
+import net.minecraftforge.fluids.FluidRegistry;
+
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@@ -12,15 +21,9 @@ import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_OreDictUnificator;
-import java.util.List;
-import net.minecraft.client.renderer.texture.IIconRegister;
-import net.minecraft.creativetab.CreativeTabs;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IIcon;
-import net.minecraftforge.fluids.FluidRegistry;
public class ItemPropolis extends Item {
+
@SideOnly(Side.CLIENT)
private IIcon secondIcon;
@@ -100,16 +103,31 @@ public class ItemPropolis extends Item {
public void addProcessHV(ItemStack tPropolis, ItemStack aOutput2) {
GT_Values.RA.addFluidExtractionRecipe(
- tPropolis, aOutput2, FluidRegistry.getFluidStack("endergoo", 100), 5000, 50, 480);
+ tPropolis,
+ aOutput2,
+ FluidRegistry.getFluidStack("endergoo", 100),
+ 5000,
+ 50,
+ 480);
}
public void addProcessEV(ItemStack tPropolis, ItemStack aOutput2) {
GT_Values.RA.addFluidExtractionRecipe(
- tPropolis, aOutput2, FluidRegistry.getFluidStack("endergoo", 200), 2500, 100, 1920);
+ tPropolis,
+ aOutput2,
+ FluidRegistry.getFluidStack("endergoo", 200),
+ 2500,
+ 100,
+ 1920);
}
public void addProcessIV(ItemStack tPropolis, ItemStack aOutput2) {
GT_Values.RA.addFluidExtractionRecipe(
- tPropolis, aOutput2, FluidRegistry.getFluidStack("endergoo", 300), 1500, 150, 7680);
+ tPropolis,
+ aOutput2,
+ FluidRegistry.getFluidStack("endergoo", 300),
+ 1500,
+ 150,
+ 7680);
}
}
diff --git a/src/main/java/gregtech/common/items/PollenType.java b/src/main/java/gregtech/common/items/PollenType.java
index cb7499e862..b8cccb70b6 100644
--- a/src/main/java/gregtech/common/items/PollenType.java
+++ b/src/main/java/gregtech/common/items/PollenType.java
@@ -4,11 +4,10 @@ import gregtech.api.enums.Materials;
import gregtech.api.util.GT_LanguageManager;
public enum PollenType {
+
MATRIX("matrix", true);
- private static int[][] colours = new int[][] {
- {0x19191B, 0x303032},
- };
+ private static int[][] colours = new int[][] { { 0x19191B, 0x303032 }, };
public boolean showInList;
public Materials material;
public int chance;
@@ -25,7 +24,8 @@ public enum PollenType {
public String getName() {
return GT_LanguageManager.addStringLocalization(
- "pollen." + this.name, this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Pollen");
+ "pollen." + this.name,
+ this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Pollen");
}
public int[] getColours() {
diff --git a/src/main/java/gregtech/common/items/PropolisType.java b/src/main/java/gregtech/common/items/PropolisType.java
index 4d3d7407f8..15f4a2400b 100644
--- a/src/main/java/gregtech/common/items/PropolisType.java
+++ b/src/main/java/gregtech/common/items/PropolisType.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.Materials;
import gregtech.api.util.GT_LanguageManager;
public enum PropolisType {
+
End("End", true),
Ectoplasma("Ectoplasma", true),
Arcaneshard("Arcaneshard", true),
@@ -14,8 +15,8 @@ public enum PropolisType {
Endium("Endium", true),
Fireessence("Fireessence", true);
- private static int[] colours =
- new int[] {0xCC00FA, 0xDCB0E5, 0x9010AD, 0xFFFF00, 0x911ECE, 0x161616, 0xEE053D, 0xa0ffff, 0xD41238};
+ private static int[] colours = new int[] { 0xCC00FA, 0xDCB0E5, 0x9010AD, 0xFFFF00, 0x911ECE, 0x161616, 0xEE053D,
+ 0xa0ffff, 0xD41238 };
public boolean showInList;
public Materials material;
@@ -32,7 +33,7 @@ public enum PropolisType {
}
public String getName() {
- // return "gt.comb."+this.name;
+ // return "gt.comb."+this.name;
return GT_LanguageManager.addStringLocalization(
"propolis." + this.name,
this.name.substring(0, 1).toUpperCase() + this.name.substring(1) + " Propolis");
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow.java
index 9c7d261eb6..93414ec8aa 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow.java
@@ -1,9 +1,5 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SubTag;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.entities.GT_Entity_Arrow;
import net.minecraft.block.BlockDispenser;
import net.minecraft.dispenser.IBlockSource;
import net.minecraft.dispenser.IPosition;
@@ -17,7 +13,13 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.EnumFacing;
import net.minecraft.world.World;
+import gregtech.api.enums.SubTag;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.entities.GT_Entity_Arrow;
+
public class Behaviour_Arrow extends Behaviour_None {
+
public static Behaviour_Arrow DEFAULT_WOODEN = new Behaviour_Arrow(GT_Entity_Arrow.class, 1.0F, 6.0F);
public static Behaviour_Arrow DEFAULT_PLASTIC = new Behaviour_Arrow(GT_Entity_Arrow.class, 1.5F, 6.0F);
private final int mLevel;
@@ -30,12 +32,8 @@ public class Behaviour_Arrow extends Behaviour_None {
this(aArrow, aSpeed, aPrecision, null, 0);
}
- public Behaviour_Arrow(
- Class<? extends GT_Entity_Arrow> aArrow,
- float aSpeed,
- float aPrecision,
- Enchantment aEnchantment,
- int aLevel) {
+ public Behaviour_Arrow(Class<? extends GT_Entity_Arrow> aArrow, float aSpeed, float aPrecision,
+ Enchantment aEnchantment, int aLevel) {
this.mArrow = aArrow;
this.mSpeedMultiplier = aSpeed;
this.mPrecision = aPrecision;
@@ -83,7 +81,13 @@ public class Behaviour_Arrow extends Behaviour_None {
IPosition tPosition = BlockDispenser.func_149939_a(aSource);
EnumFacing tFacing = BlockDispenser.func_149937_b(aSource.getBlockMetadata());
GT_Entity_Arrow tEntityArrow = (GT_Entity_Arrow) getProjectile(
- aItem, SubTag.PROJECTILE_ARROW, aStack, aWorld, tPosition.getX(), tPosition.getY(), tPosition.getZ());
+ aItem,
+ SubTag.PROJECTILE_ARROW,
+ aStack,
+ aWorld,
+ tPosition.getX(),
+ tPosition.getY(),
+ tPosition.getZ());
if (tEntityArrow != null) {
tEntityArrow.setThrowableHeading(
tFacing.getFrontOffsetX(),
@@ -108,40 +112,33 @@ public class Behaviour_Arrow extends Behaviour_None {
}
@Override
- public EntityArrow getProjectile(
- GT_MetaBase_Item aItem,
- SubTag aProjectileType,
- ItemStack aStack,
- World aWorld,
- double aX,
- double aY,
- double aZ) {
+ public EntityArrow getProjectile(GT_MetaBase_Item aItem, SubTag aProjectileType, ItemStack aStack, World aWorld,
+ double aX, double aY, double aZ) {
if (!hasProjectile(aItem, aProjectileType, aStack)) {
return null;
}
- GT_Entity_Arrow rArrow =
- (GT_Entity_Arrow) GT_Utility.callConstructor(this.mArrow.getName(), -1, null, true, new Object[] {
- aWorld, Double.valueOf(aX), Double.valueOf(aY), Double.valueOf(aZ)
- });
+ GT_Entity_Arrow rArrow = (GT_Entity_Arrow) GT_Utility.callConstructor(
+ this.mArrow.getName(),
+ -1,
+ null,
+ true,
+ new Object[] { aWorld, Double.valueOf(aX), Double.valueOf(aY), Double.valueOf(aZ) });
rArrow.setArrowItem(aStack);
return rArrow;
}
@Override
- public EntityArrow getProjectile(
- GT_MetaBase_Item aItem,
- SubTag aProjectileType,
- ItemStack aStack,
- World aWorld,
- EntityLivingBase aEntity,
- float aSpeed) {
+ public EntityArrow getProjectile(GT_MetaBase_Item aItem, SubTag aProjectileType, ItemStack aStack, World aWorld,
+ EntityLivingBase aEntity, float aSpeed) {
if (!hasProjectile(aItem, aProjectileType, aStack)) {
return null;
}
- GT_Entity_Arrow rArrow =
- (GT_Entity_Arrow) GT_Utility.callConstructor(this.mArrow.getName(), -1, null, true, new Object[] {
- aWorld, aEntity, Float.valueOf(this.mSpeedMultiplier * aSpeed)
- });
+ GT_Entity_Arrow rArrow = (GT_Entity_Arrow) GT_Utility.callConstructor(
+ this.mArrow.getName(),
+ -1,
+ null,
+ true,
+ new Object[] { aWorld, aEntity, Float.valueOf(this.mSpeedMultiplier * aSpeed) });
rArrow.setArrowItem(aStack);
return rArrow;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow_Potion.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow_Potion.java
index 8b2d4ab4ce..4397429018 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow_Potion.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow_Potion.java
@@ -1,8 +1,5 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SubTag;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.common.entities.GT_Entity_Arrow_Potion;
import net.minecraft.enchantment.Enchantment;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
@@ -12,7 +9,12 @@ import net.minecraft.item.ItemStack;
import net.minecraft.potion.PotionEffect;
import net.minecraft.world.World;
+import gregtech.api.enums.SubTag;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.common.entities.GT_Entity_Arrow_Potion;
+
public class Behaviour_Arrow_Potion extends Behaviour_Arrow {
+
private final int[] mPotions;
public Behaviour_Arrow_Potion(float aSpeed, float aPrecision, int... aPotions) {
@@ -20,8 +22,8 @@ public class Behaviour_Arrow_Potion extends Behaviour_Arrow {
this.mPotions = aPotions;
}
- public Behaviour_Arrow_Potion(
- float aSpeed, float aPrecision, Enchantment aEnchantment, int aLevel, int... aPotions) {
+ public Behaviour_Arrow_Potion(float aSpeed, float aPrecision, Enchantment aEnchantment, int aLevel,
+ int... aPotions) {
super(GT_Entity_Arrow_Potion.class, aSpeed, aPrecision, aEnchantment, aLevel);
this.mPotions = aPotions;
}
@@ -31,9 +33,12 @@ public class Behaviour_Arrow_Potion extends Behaviour_Arrow {
if ((aEntity instanceof EntityLivingBase)) {
for (int i = 3; i < this.mPotions.length; i += 4) {
if (aEntity.worldObj.rand.nextInt(100) < this.mPotions[i]) {
- ((EntityLivingBase) aEntity)
- .addPotionEffect(new PotionEffect(
- this.mPotions[(i - 3)], this.mPotions[(i - 2)], this.mPotions[(i - 1)], false));
+ ((EntityLivingBase) aEntity).addPotionEffect(
+ new PotionEffect(
+ this.mPotions[(i - 3)],
+ this.mPotions[(i - 2)],
+ this.mPotions[(i - 1)],
+ false));
}
}
}
@@ -41,14 +46,8 @@ public class Behaviour_Arrow_Potion extends Behaviour_Arrow {
}
@Override
- public EntityArrow getProjectile(
- GT_MetaBase_Item aItem,
- SubTag aProjectileType,
- ItemStack aStack,
- World aWorld,
- double aX,
- double aY,
- double aZ) {
+ public EntityArrow getProjectile(GT_MetaBase_Item aItem, SubTag aProjectileType, ItemStack aStack, World aWorld,
+ double aX, double aY, double aZ) {
if (!hasProjectile(aItem, aProjectileType, aStack)) {
return null;
}
@@ -59,13 +58,8 @@ public class Behaviour_Arrow_Potion extends Behaviour_Arrow {
}
@Override
- public EntityArrow getProjectile(
- GT_MetaBase_Item aItem,
- SubTag aProjectileType,
- ItemStack aStack,
- World aWorld,
- EntityLivingBase aEntity,
- float aSpeed) {
+ public EntityArrow getProjectile(GT_MetaBase_Item aItem, SubTag aProjectileType, ItemStack aStack, World aWorld,
+ EntityLivingBase aEntity, float aSpeed) {
if (!hasProjectile(aItem, aProjectileType, aStack)) {
return null;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Cover_Tool.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Cover_Tool.java
index c0bda95262..4a7beb453c 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Cover_Tool.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Cover_Tool.java
@@ -1,13 +1,8 @@
package gregtech.common.items.behaviors;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.interfaces.IItemBehaviour;
-import gregtech.api.interfaces.tileentity.ICoverable;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.*;
import java.util.ArrayList;
import java.util.List;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.ItemStack;
@@ -18,27 +13,25 @@ import net.minecraft.util.EnumChatFormatting;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.interfaces.IItemBehaviour;
+import gregtech.api.interfaces.tileentity.ICoverable;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.*;
+
public class Behaviour_Cover_Tool extends Behaviour_None {
+
public static final IItemBehaviour<GT_MetaBase_Item> INSTANCE = new Behaviour_Cover_Tool();
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.cover_copy_paste", "Can copy/paste cover data.");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.cover_copy_paste", "Can copy/paste cover data.");
private ISerializableObject mStoredData = GregTech_API.sNoBehavior.createDataObject();
private int mCoverType;
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
@@ -90,38 +83,42 @@ public class Behaviour_Cover_Tool extends Behaviour_None {
}
}
- @SuppressWarnings({"unchecked", "rawtypes"})
- private void doCopy(
- TileEntity aTileEntity,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ,
- List aList) {
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ private void doCopy(TileEntity aTileEntity, World aWorld, int aX, int aY, int aZ, int aSide, float hitX, float hitY,
+ float hitZ, List aList) {
aList.add(
- "----- X: " + EnumChatFormatting.AQUA + GT_Utility.formatNumbers(aX) + EnumChatFormatting.RESET + " Y: "
- + EnumChatFormatting.AQUA + GT_Utility.formatNumbers(aY) + EnumChatFormatting.RESET + " Z: "
- + EnumChatFormatting.AQUA + GT_Utility.formatNumbers(aZ) + EnumChatFormatting.RESET + " D: "
- + EnumChatFormatting.AQUA + aWorld.provider.dimensionId + EnumChatFormatting.RESET + " -----");
+ "----- X: " + EnumChatFormatting.AQUA
+ + GT_Utility.formatNumbers(aX)
+ + EnumChatFormatting.RESET
+ + " Y: "
+ + EnumChatFormatting.AQUA
+ + GT_Utility.formatNumbers(aY)
+ + EnumChatFormatting.RESET
+ + " Z: "
+ + EnumChatFormatting.AQUA
+ + GT_Utility.formatNumbers(aZ)
+ + EnumChatFormatting.RESET
+ + " D: "
+ + EnumChatFormatting.AQUA
+ + aWorld.provider.dimensionId
+ + EnumChatFormatting.RESET
+ + " -----");
if (aTileEntity instanceof ICoverable) {
ICoverable tCoverable = (ICoverable) aTileEntity;
- int tSide = tCoverable.getCoverItemAtSide((byte) aSide) != null
- ? aSide
+ int tSide = tCoverable.getCoverItemAtSide((byte) aSide) != null ? aSide
: tCoverable.getCoverItemAtSide(GT_Utility.determineWrenchingSide((byte) aSide, hitX, hitY, hitZ))
- != null
- ? GT_Utility.determineWrenchingSide((byte) aSide, hitX, hitY, hitZ)
- : -1;
+ != null ? GT_Utility.determineWrenchingSide((byte) aSide, hitX, hitY, hitZ) : -1;
if (tSide != -1) {
mStoredData = tCoverable.getComplexCoverDataAtSide((byte) tSide);
mCoverType = tCoverable.getCoverIDAtSide((byte) tSide);
- aList.add("Block Side: " + EnumChatFormatting.AQUA
- + ForgeDirection.getOrientation(tSide).name() + EnumChatFormatting.RESET);
- aList.add("Cover Type: " + EnumChatFormatting.GREEN
- + tCoverable.getCoverItemAtSide((byte) tSide).getDisplayName() + EnumChatFormatting.RESET);
+ aList.add(
+ "Block Side: " + EnumChatFormatting.AQUA
+ + ForgeDirection.getOrientation(tSide).name()
+ + EnumChatFormatting.RESET);
+ aList.add(
+ "Cover Type: " + EnumChatFormatting.GREEN
+ + tCoverable.getCoverItemAtSide((byte) tSide).getDisplayName()
+ + EnumChatFormatting.RESET);
} else {
mStoredData = GregTech_API.sNoBehavior.createDataObject();
mCoverType = 0;
@@ -141,12 +138,9 @@ public class Behaviour_Cover_Tool extends Behaviour_None {
GT_Utility.sendChatToPlayer(aPlayer, "Please Copy a Valid Cover First.");
return;
}
- int tSide = tCoverable.getCoverItemAtSide((byte) aSide) != null
- ? aSide
+ int tSide = tCoverable.getCoverItemAtSide((byte) aSide) != null ? aSide
: tCoverable.getCoverItemAtSide(GT_Utility.determineWrenchingSide((byte) aSide, hitX, hitY, hitZ))
- != null
- ? GT_Utility.determineWrenchingSide((byte) aSide, hitX, hitY, hitZ)
- : -1;
+ != null ? GT_Utility.determineWrenchingSide((byte) aSide, hitX, hitY, hitZ) : -1;
if (tSide != -1) {
int tCoverID = tCoverable.getCoverIDAtSide((byte) tSide);
if (tCoverID == mCoverType) {
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Crowbar.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Crowbar.java
index 866eb6b9e9..9a8231cf4c 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Crowbar.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Crowbar.java
@@ -1,16 +1,18 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Crowbar extends Behaviour_None {
+
private final int mVanillaCosts;
private final int mEUCosts;
@@ -20,18 +22,8 @@ public class Behaviour_Crowbar extends Behaviour_None {
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_DataOrb.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_DataOrb.java
index f219db6e0c..8893245639 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_DataOrb.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_DataOrb.java
@@ -1,13 +1,16 @@
package gregtech.common.items.behaviors;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_DataOrb extends Behaviour_None {
+
public static void copyInventory(ItemStack[] aInventory, ItemStack[] aNewContent, int aIndexlength) {
for (int i = 0; i < aIndexlength; i++) {
if (aNewContent[i] == null) {
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_DataStick.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_DataStick.java
index 27efe7230d..1dbcd4691d 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_DataStick.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_DataStick.java
@@ -1,11 +1,14 @@
package gregtech.common.items.behaviors;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.item.ItemStack;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_DataStick extends Behaviour_None {
+
@Override
public List<String> getAdditionalToolTips(GT_MetaBase_Item aItem, List<String> aList, ItemStack aStack) {
String tString = GT_Utility.ItemNBT.getBookTitle(aStack);
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Hoe.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Hoe.java
index 6194537a5b..933f30acb7 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Hoe.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Hoe.java
@@ -1,12 +1,7 @@
package gregtech.common.items.behaviors;
-import cpw.mods.fml.common.eventhandler.Event;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
-import gregtech.api.util.WorldSpawnedEventBuilder;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
@@ -15,7 +10,15 @@ import net.minecraft.world.World;
import net.minecraftforge.common.MinecraftForge;
import net.minecraftforge.event.entity.player.UseHoeEvent;
+import cpw.mods.fml.common.eventhandler.Event;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+import gregtech.api.util.WorldSpawnedEventBuilder;
+
public class Behaviour_Hoe extends Behaviour_None {
+
private final int mCosts;
private final String mTooltip = GT_LanguageManager.addStringLocalization("gt.behaviour.hoe", "Can till Dirt");
@@ -24,18 +27,8 @@ public class Behaviour_Hoe extends Behaviour_None {
}
@Override
- public boolean onItemUse(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUse(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (!aPlayer.canPlayerEdit(aX, aY, aZ, aSide, aStack)) {
return false;
}
@@ -50,16 +43,13 @@ public class Behaviour_Hoe extends Behaviour_None {
return true;
}
Block aBlock = aWorld.getBlock(aX, aY, aZ);
- if ((aSide != 0)
- && (GT_Utility.isBlockAir(aWorld, aX, aY + 1, aZ))
+ if ((aSide != 0) && (GT_Utility.isBlockAir(aWorld, aX, aY + 1, aZ))
&& ((aBlock == Blocks.grass) || (aBlock == Blocks.dirt))) {
new WorldSpawnedEventBuilder.SoundEventBuilder()
.setVolume((Blocks.farmland.stepSound.getVolume() + 1.0F) / 2.0F)
.setPitch(Blocks.farmland.stepSound.getPitch() * 0.8F)
.setIdentifier(Blocks.farmland.stepSound.getStepResourcePath())
- .setPosition(aX + 0.5F, aY + 0.5F, aZ + 0.5F)
- .setWorld(aWorld)
- .run();
+ .setPosition(aX + 0.5F, aY + 0.5F, aZ + 0.5F).setWorld(aWorld).run();
if (aWorld.isRemote) {
return true;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Lighter.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Lighter.java
index f18f9cd17a..db10ecfa8e 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Lighter.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Lighter.java
@@ -1,11 +1,7 @@
package gregtech.common.items.behaviors;
-import codechicken.lib.math.MathHelper;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.entity.Entity;
import net.minecraft.entity.monster.EntityCreeper;
import net.minecraft.entity.player.EntityPlayer;
@@ -16,20 +12,27 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import codechicken.lib.math.MathHelper;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Lighter extends Behaviour_None {
+
private final ItemStack mEmptyLighter;
private final ItemStack mUsedLighter;
private final ItemStack mFullLighter;
private final long mFuelAmount;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.lighter.tooltip", "Can light things on Fire");
- private final String mTooltipUses =
- GT_LanguageManager.addStringLocalization("gt.behaviour.lighter.uses", "Remaining Uses:");
- private final String mTooltipUnstackable =
- GT_LanguageManager.addStringLocalization("gt.behaviour.unstackable", "Not usable when stacked!");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.lighter.tooltip", "Can light things on Fire");
+ private final String mTooltipUses = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.lighter.uses", "Remaining Uses:");
+ private final String mTooltipUnstackable = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.unstackable", "Not usable when stacked!");
- public Behaviour_Lighter(
- ItemStack aEmptyLighter, ItemStack aUsedLighter, ItemStack aFullLighter, long aFuelAmount) {
+ public Behaviour_Lighter(ItemStack aEmptyLighter, ItemStack aUsedLighter, ItemStack aFullLighter,
+ long aFuelAmount) {
this.mFullLighter = aFullLighter;
this.mUsedLighter = aUsedLighter;
this.mEmptyLighter = aEmptyLighter;
@@ -69,34 +72,14 @@ public class Behaviour_Lighter extends Behaviour_None {
}
@Override
- public boolean onItemUse(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUse(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
return false;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if ((aWorld.isRemote) || (aStack.stackSize != 1)) {
return false;
}
@@ -147,10 +130,8 @@ public class Behaviour_Lighter extends Behaviour_None {
public List<String> getAdditionalToolTips(GT_MetaBase_Item aItem, List<String> aList, ItemStack aStack) {
aList.add(this.mTooltip);
NBTTagCompound tNBT = aStack.getTagCompound();
- long tFuelAmount = tNBT == null
- ? 0L
- : GT_Utility.areStacksEqual(aStack, this.mFullLighter, true)
- ? this.mFuelAmount
+ long tFuelAmount = tNBT == null ? 0L
+ : GT_Utility.areStacksEqual(aStack, this.mFullLighter, true) ? this.mFuelAmount
: tNBT.getLong("GT.LighterFuel");
aList.add(this.mTooltipUses + " " + tFuelAmount);
aList.add(this.mTooltipUnstackable);
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_None.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_None.java
index f40d200410..ca6a1e8466 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_None.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_None.java
@@ -1,10 +1,7 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SubTag;
-import gregtech.api.interfaces.IItemBehaviour;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.block.BlockDispenser;
import net.minecraft.dispenser.BehaviorDefaultDispenseItem;
import net.minecraft.dispenser.IBlockSource;
@@ -17,41 +14,27 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.EnumFacing;
import net.minecraft.world.World;
+import gregtech.api.enums.SubTag;
+import gregtech.api.interfaces.IItemBehaviour;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_None implements IItemBehaviour<GT_MetaBase_Item> {
+
@Override
public boolean onLeftClickEntity(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, Entity aEntity) {
return false;
}
@Override
- public boolean onItemUse(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUse(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
return false;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
return false;
}
@@ -66,8 +49,8 @@ public class Behaviour_None implements IItemBehaviour<GT_MetaBase_Item> {
}
@Override
- public void onUpdate(
- GT_MetaBase_Item aItem, ItemStack aStack, World aWorld, Entity aPlayer, int aTimer, boolean aIsInHand) {}
+ public void onUpdate(GT_MetaBase_Item aItem, ItemStack aStack, World aWorld, Entity aPlayer, int aTimer,
+ boolean aIsInHand) {}
@Override
public boolean isItemStackUsable(GT_MetaBase_Item aItem, ItemStack aStack) {
@@ -94,25 +77,14 @@ public class Behaviour_None implements IItemBehaviour<GT_MetaBase_Item> {
}
@Override
- public EntityArrow getProjectile(
- GT_MetaBase_Item aItem,
- SubTag aProjectileType,
- ItemStack aStack,
- World aWorld,
- double aX,
- double aY,
- double aZ) {
+ public EntityArrow getProjectile(GT_MetaBase_Item aItem, SubTag aProjectileType, ItemStack aStack, World aWorld,
+ double aX, double aY, double aZ) {
return null;
}
@Override
- public EntityArrow getProjectile(
- GT_MetaBase_Item aItem,
- SubTag aProjectileType,
- ItemStack aStack,
- World aWorld,
- EntityLivingBase aEntity,
- float aSpeed) {
+ public EntityArrow getProjectile(GT_MetaBase_Item aItem, SubTag aProjectileType, ItemStack aStack, World aWorld,
+ EntityLivingBase aEntity, float aSpeed) {
return null;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Essentia.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Essentia.java
index 959e97aff3..c164695c36 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Essentia.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Essentia.java
@@ -1,54 +1,45 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+
import thaumcraft.api.aspects.IEssentiaTransport;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
public class Behaviour_Plunger_Essentia extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip = GT_LanguageManager.addStringLocalization(
- "gt.behaviour.plunger.essentia", "Clears Essentia from Containers and Tubes");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.plunger.essentia", "Clears Essentia from Containers and Tubes");
public Behaviour_Plunger_Essentia(int aCosts) {
this.mCosts = aCosts;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
TileEntity aTileEntity = aWorld.getTileEntity(aX, aY, aZ);
- if (((aTileEntity instanceof IEssentiaTransport))
- && ((aPlayer.capabilities.isCreativeMode)
- || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
+ if (((aTileEntity instanceof IEssentiaTransport)) && ((aPlayer.capabilities.isCreativeMode)
+ || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
GT_Utility.sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
for (ForgeDirection tDirection : ForgeDirection.VALID_DIRECTIONS) {
- ((IEssentiaTransport) aTileEntity)
- .takeEssentia(
- ((IEssentiaTransport) aTileEntity).getEssentiaType(tDirection),
- ((IEssentiaTransport) aTileEntity).getEssentiaAmount(tDirection),
- tDirection);
+ ((IEssentiaTransport) aTileEntity).takeEssentia(
+ ((IEssentiaTransport) aTileEntity).getEssentiaType(tDirection),
+ ((IEssentiaTransport) aTileEntity).getEssentiaAmount(tDirection),
+ tDirection);
}
return true;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Fluid.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Fluid.java
index be14a44d09..e0d0f91e48 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Fluid.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Fluid.java
@@ -1,5 +1,14 @@
package gregtech.common.items.behaviors;
+import java.util.List;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.IFluidHandler;
+
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
@@ -8,36 +17,20 @@ import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicTank;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_Utility;
-import java.util.List;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.IFluidHandler;
public class Behaviour_Plunger_Fluid extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip = GT_LanguageManager.addStringLocalization(
- "gt.behaviour.plunger.fluid", "Clears 1000 Liters of Fluid from Tanks");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.plunger.fluid", "Clears 1000 Liters of Fluid from Tanks");
public Behaviour_Plunger_Fluid(int aCosts) {
this.mCosts = aCosts;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
@@ -49,7 +42,13 @@ public class Behaviour_Plunger_Fluid extends Behaviour_None {
|| (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts))) {
((IFluidHandler) aTileEntity).drain(tDirection, 1000, true);
GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ aWorld,
+ SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE,
+ 1.0F,
+ -1.0F,
+ aX,
+ aY,
+ aZ);
return true;
}
}
@@ -62,8 +61,8 @@ public class Behaviour_Plunger_Fluid extends Behaviour_None {
GT_MetaTileEntity_BasicTank machine = (GT_MetaTileEntity_BasicTank) mTileEntity;
if (machine.mFluid != null && machine.mFluid.amount > 0)
machine.mFluid.amount = machine.mFluid.amount - Math.min(machine.mFluid.amount, 1000);
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
return true;
}
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Item.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Item.java
index e98702629b..1aeafc62fe 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Item.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Plunger_Item.java
@@ -1,5 +1,14 @@
package gregtech.common.items.behaviors;
+import java.util.HashMap;
+import java.util.List;
+
+import net.minecraft.entity.item.EntityItem;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.World;
+
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.metatileentity.IMetaTileEntityItemPipe;
@@ -8,36 +17,20 @@ import gregtech.api.items.GT_MetaBase_Item;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_Utility;
-import java.util.HashMap;
-import java.util.List;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
public class Behaviour_Plunger_Item extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.plunger.item", "Clears Items from Pipes");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.plunger.item", "Clears Items from Pipes");
public Behaviour_Plunger_Item(int aCosts) {
this.mCosts = aCosts;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
@@ -46,15 +39,14 @@ public class Behaviour_Plunger_Item extends Behaviour_None {
IMetaTileEntity tMetaTileEntity = ((IGregTechTileEntity) aTileEntity).getMetaTileEntity();
if ((tMetaTileEntity instanceof IMetaTileEntityItemPipe)) {
for (IMetaTileEntityItemPipe tTileEntity : GT_Utility.sortMapByValuesAcending(
- IMetaTileEntityItemPipe.Util.scanPipes(
- (IMetaTileEntityItemPipe) tMetaTileEntity, new HashMap<>(), 0L, false, true))
+ IMetaTileEntityItemPipe.Util
+ .scanPipes((IMetaTileEntityItemPipe) tMetaTileEntity, new HashMap<>(), 0L, false, true))
.keySet()) {
int i = 0;
for (int j = tTileEntity.getSizeInventory(); i < j; i++) {
if (tTileEntity.isValidSlot(i)) {
- if ((tTileEntity.getStackInSlot(i) != null)
- && ((aPlayer.capabilities.isCreativeMode)
- || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
+ if ((tTileEntity.getStackInSlot(i) != null) && ((aPlayer.capabilities.isCreativeMode)
+ || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
ItemStack tStack = tTileEntity.decrStackSize(i, 64);
if (tStack != null) {
EntityItem tEntity = new EntityItem(
@@ -68,7 +60,13 @@ public class Behaviour_Plunger_Item extends Behaviour_None {
tEntity.motionZ = 0.0D;
aWorld.spawnEntityInWorld(tEntity);
GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ aWorld,
+ SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE,
+ 1.0F,
+ -1.0F,
+ aX,
+ aY,
+ aZ);
}
return true;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_PrintedPages.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_PrintedPages.java
index 7562c0fb80..e3c4d58525 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_PrintedPages.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_PrintedPages.java
@@ -1,12 +1,15 @@
package gregtech.common.items.behaviors;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_PrintedPages extends Behaviour_None {
+
public static String getTitle(ItemStack aStack) {
NBTTagCompound tNBT = aStack.getTagCompound();
if (tNBT == null) {
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Prospecting.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Prospecting.java
index 771e1f696f..1374a33f7d 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Prospecting.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Prospecting.java
@@ -1,5 +1,18 @@
package gregtech.common.items.behaviors;
+import java.util.List;
+import java.util.Random;
+
+import net.minecraft.block.Block;
+import net.minecraft.block.BlockLiquid;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.IFluidBlock;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.enums.SoundResource;
@@ -13,23 +26,13 @@ import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Utility;
import gregtech.common.blocks.GT_Block_Ores_Abstract;
import gregtech.common.blocks.GT_TileEntity_Ores;
-import java.util.List;
-import java.util.Random;
-import net.minecraft.block.Block;
-import net.minecraft.block.BlockLiquid;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.IFluidBlock;
public class Behaviour_Prospecting extends Behaviour_None {
+
private final int mVanillaCosts;
private final int mEUCosts;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.prospecting", "Usable for Prospecting");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.prospecting", "Usable for Prospecting");
public Behaviour_Prospecting(int aVanillaCosts, int aEUCosts) {
this.mVanillaCosts = aVanillaCosts;
@@ -37,18 +40,8 @@ public class Behaviour_Prospecting extends Behaviour_None {
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
@@ -59,14 +52,12 @@ public class Behaviour_Prospecting extends Behaviour_None {
byte aMeta = (byte) aWorld.getBlockMetadata(aX, aY, aZ);
ItemData tAssociation = GT_OreDictUnificator.getAssociation(new ItemStack(aBlock, 1, aMeta));
- if (tAssociation != null
- && tAssociation.mPrefix != null
+ if (tAssociation != null && tAssociation.mPrefix != null
&& tAssociation.mMaterial != null
&& tAssociation.mPrefix.toString().startsWith("ore")) {
GT_Utility.sendChatToPlayer(
aPlayer,
- GT_Utility.trans("100", "This is ")
- + tAssociation.mMaterial.mMaterial.mDefaultLocalName
+ GT_Utility.trans("100", "This is ") + tAssociation.mMaterial.mMaterial.mDefaultLocalName
+ GT_Utility.trans("101", " Ore."));
GT_Utility.sendSoundToPlayers(aWorld, SoundResource.RANDOM_ANVIL_USE, 1.0F, -1.0F, aX, aY, aZ);
return true;
@@ -94,24 +85,26 @@ public class Behaviour_Prospecting extends Behaviour_None {
tBlock = aWorld.getBlock(tX, tY, tZ);
if (tBlock == Blocks.lava || tBlock == Blocks.flowing_lava) {
- GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("102", "There is Lava behind this Rock."));
+ GT_Utility
+ .sendChatToPlayer(aPlayer, GT_Utility.trans("102", "There is Lava behind this Rock."));
break;
}
if (tBlock instanceof BlockLiquid || tBlock instanceof IFluidBlock) {
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("103", "There is a Liquid behind this Rock."));
+ aPlayer,
+ GT_Utility.trans("103", "There is a Liquid behind this Rock."));
break;
}
if (tBlock == Blocks.monster_egg || !GT_Utility.hasBlockHitBox(aWorld, tX, tY, tZ)) {
GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("104", "There is an Air Pocket behind this Rock."));
+ aPlayer,
+ GT_Utility.trans("104", "There is an Air Pocket behind this Rock."));
break;
}
if (tBlock != aBlock) {
- if (i < 4)
- GT_Utility.sendChatToPlayer(
- aPlayer, GT_Utility.trans("105", "Material is changing behind this Rock."));
+ if (i < 4) GT_Utility.sendChatToPlayer(
+ aPlayer,
+ GT_Utility.trans("105", "Material is changing behind this Rock."));
break;
}
}
@@ -125,13 +118,12 @@ public class Behaviour_Prospecting extends Behaviour_None {
if (tBlock instanceof GT_Block_Ores_Abstract) {
TileEntity tTileEntity = aWorld.getTileEntity(tX, tY, tZ);
if (tTileEntity instanceof GT_TileEntity_Ores) {
- Materials tMaterial = GregTech_API.sGeneratedMaterials[
- ((GT_TileEntity_Ores) tTileEntity).mMetaData % 1000];
+ Materials tMaterial = GregTech_API.sGeneratedMaterials[((GT_TileEntity_Ores) tTileEntity).mMetaData
+ % 1000];
if (tMaterial != null && tMaterial != Materials._NULL) {
GT_Utility.sendChatToPlayer(
aPlayer,
- GT_Utility.trans("106", "Found traces of ")
- + tMaterial.mDefaultLocalName
+ GT_Utility.trans("106", "Found traces of ") + tMaterial.mDefaultLocalName
+ GT_Utility.trans("101", " Ore."));
return true;
}
@@ -139,8 +131,7 @@ public class Behaviour_Prospecting extends Behaviour_None {
} else {
tMetaID = aWorld.getBlockMetadata(tX, tY, tZ);
tAssociation = GT_OreDictUnificator.getAssociation(new ItemStack(tBlock, 1, tMetaID));
- if (tAssociation != null
- && tAssociation.mPrefix != null
+ if (tAssociation != null && tAssociation.mPrefix != null
&& tAssociation.mMaterial != null
&& tAssociation.mPrefix.toString().startsWith("ore")) {
GT_Utility.sendChatToPlayer(
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Scanner.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Scanner.java
index a24105bf75..ad8d99f6fb 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Scanner.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Scanner.java
@@ -1,12 +1,8 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.interfaces.IItemBehaviour;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.ArrayList;
import java.util.List;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.item.ItemStack;
@@ -14,24 +10,21 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.world.World;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.interfaces.IItemBehaviour;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Scanner extends Behaviour_None {
+
public static final IItemBehaviour<GT_MetaBase_Item> INSTANCE = new Behaviour_Scanner();
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.scanning", "Can scan Blocks in World");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.scanning", "Can scan Blocks in World");
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
NBTTagCompound tNBT = aStack.getTagCompound();
if (((aPlayer instanceof EntityPlayerMP)) && (aItem.canUse(aStack, 20000.0D))) {
ArrayList<String> tList = new ArrayList<>();
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Scoop.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Scoop.java
index 1cc81b764f..83d5ffffa3 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Scoop.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Scoop.java
@@ -1,21 +1,24 @@
package gregtech.common.items.behaviors;
+import java.util.List;
+
+import net.minecraft.entity.Entity;
+import net.minecraft.entity.item.EntityItem;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+
import forestry.api.lepidopterology.EnumFlutterType;
import forestry.api.lepidopterology.IButterfly;
import forestry.api.lepidopterology.IEntityButterfly;
import gregtech.api.items.GT_MetaBase_Item;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.api.util.GT_LanguageManager;
-import java.util.List;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.item.EntityItem;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
public class Behaviour_Scoop extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.scoop", "Catches Butterflies on Leftclick");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.scoop", "Catches Butterflies on Leftclick");
public Behaviour_Scoop(int aCosts) {
this.mCosts = aCosts;
@@ -30,23 +33,18 @@ public class Behaviour_Scoop extends Behaviour_None {
if ((aPlayer.capabilities.isCreativeMode)
|| (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts))) {
Object tButterfly = ((IEntityButterfly) aEntity).getButterfly();
- ((IButterfly) tButterfly)
- .getGenome()
- .getPrimary()
- .getRoot()
+ ((IButterfly) tButterfly).getGenome().getPrimary().getRoot()
.getBreedingTracker(aEntity.worldObj, aPlayer.getGameProfile())
.registerCatch((IButterfly) tButterfly);
- aPlayer.worldObj.spawnEntityInWorld(new EntityItem(
- aPlayer.worldObj,
- aEntity.posX,
- aEntity.posY,
- aEntity.posZ,
- ((IButterfly) tButterfly)
- .getGenome()
- .getPrimary()
- .getRoot()
- .getMemberStack(
- ((IButterfly) tButterfly).copy(), EnumFlutterType.BUTTERFLY.ordinal())));
+ aPlayer.worldObj.spawnEntityInWorld(
+ new EntityItem(
+ aPlayer.worldObj,
+ aEntity.posX,
+ aEntity.posY,
+ aEntity.posZ,
+ ((IButterfly) tButterfly).getGenome().getPrimary().getRoot().getMemberStack(
+ ((IButterfly) tButterfly).copy(),
+ EnumFlutterType.BUTTERFLY.ordinal())));
aEntity.setDead();
}
return true;
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Screwdriver.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Screwdriver.java
index 2ab5167453..e2fa9d8f71 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Screwdriver.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Screwdriver.java
@@ -1,16 +1,18 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Screwdriver extends Behaviour_None {
+
private final int mVanillaCosts;
private final int mEUCosts;
@@ -20,18 +22,8 @@ public class Behaviour_Screwdriver extends Behaviour_None {
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Sense.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Sense.java
index 4dfc685103..75b4d9e431 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Sense.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Sense.java
@@ -1,37 +1,30 @@
package gregtech.common.items.behaviors;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_LanguageManager;
-import ic2.api.crops.ICropTile;
import java.util.List;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_LanguageManager;
+import ic2.api.crops.ICropTile;
+
public class Behaviour_Sense extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.sense", "Rightclick to harvest Crop Sticks");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.sense", "Rightclick to harvest Crop Sticks");
public Behaviour_Sense(int aCosts) {
this.mCosts = aCosts;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_SensorKit.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_SensorKit.java
index 5b7fb8556f..62ceebd365 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_SensorKit.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_SensorKit.java
@@ -1,11 +1,7 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.ItemList;
-import gregtech.api.interfaces.tileentity.IGregTechDeviceInformation;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.inventory.IInventory;
@@ -14,23 +10,21 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
+import gregtech.api.enums.ItemList;
+import gregtech.api.interfaces.tileentity.IGregTechDeviceInformation;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_SensorKit extends Behaviour_None {
+
private final String mTooltip = GT_LanguageManager.addStringLocalization(
- "gt.behaviour.sensorkit.tooltip", "Used to display Information using the Mod Nuclear Control");
+ "gt.behaviour.sensorkit.tooltip",
+ "Used to display Information using the Mod Nuclear Control");
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if ((aPlayer instanceof EntityPlayerMP)) {
TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
if (((tTileEntity instanceof IInventory)) && (!((IInventory) tTileEntity).isUseableByPlayer(aPlayer))) {
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_SoftHammer.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_SoftHammer.java
index a102e07dcb..7c5780c42d 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_SoftHammer.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_SoftHammer.java
@@ -1,39 +1,32 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_SoftHammer extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.softhammer", "Activates and Deactivates Machines");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.softhammer", "Activates and Deactivates Machines");
public Behaviour_SoftHammer(int aCosts) {
this.mCosts = aCosts;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
@@ -48,8 +41,8 @@ public class Behaviour_SoftHammer extends Behaviour_None {
aWorld.isRemote = true;
aWorld.setBlock(aX, aY, aZ, Blocks.redstone_lamp, 0, 0);
aWorld.isRemote = false;
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
@@ -59,8 +52,8 @@ public class Behaviour_SoftHammer extends Behaviour_None {
aWorld.isRemote = true;
aWorld.setBlock(aX, aY, aZ, Blocks.lit_redstone_lamp, 0, 0);
aWorld.isRemote = false;
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
@@ -70,8 +63,8 @@ public class Behaviour_SoftHammer extends Behaviour_None {
aWorld.isRemote = true;
aWorld.setBlock(aX, aY, aZ, aBlock, (aMeta + 8) % 16, 0);
aWorld.isRemote = false;
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
@@ -81,8 +74,8 @@ public class Behaviour_SoftHammer extends Behaviour_None {
aWorld.isRemote = true;
aWorld.setBlock(aX, aY, aZ, aBlock, (aMeta + 8) % 16, 0);
aWorld.isRemote = false;
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
@@ -93,20 +86,18 @@ public class Behaviour_SoftHammer extends Behaviour_None {
}
return true;
}
- if ((aBlock == Blocks.piston)
- || (aBlock == Blocks.sticky_piston)
+ if ((aBlock == Blocks.piston) || (aBlock == Blocks.sticky_piston)
|| (aBlock == Blocks.dispenser)
|| (aBlock == Blocks.dropper)) {
if ((aPlayer.capabilities.isCreativeMode)
|| (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts))) {
aWorld.setBlockMetadataWithNotify(aX, aY, aZ, (aMeta + 1) % 6, 3);
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
- if ((aBlock == Blocks.pumpkin)
- || (aBlock == Blocks.lit_pumpkin)
+ if ((aBlock == Blocks.pumpkin) || (aBlock == Blocks.lit_pumpkin)
|| (aBlock == Blocks.furnace)
|| (aBlock == Blocks.lit_furnace)
|| (aBlock == Blocks.chest)
@@ -114,8 +105,8 @@ public class Behaviour_SoftHammer extends Behaviour_None {
if ((aPlayer.capabilities.isCreativeMode)
|| (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts))) {
aWorld.setBlockMetadataWithNotify(aX, aY, aZ, (aMeta - 1) % 4 + 2, 3);
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
@@ -123,8 +114,8 @@ public class Behaviour_SoftHammer extends Behaviour_None {
if ((aPlayer.capabilities.isCreativeMode)
|| (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts))) {
aWorld.setBlockMetadataWithNotify(aX, aY, aZ, (aMeta + 1) % 6 != 1 ? (aMeta + 1) % 6 : 2, 3);
- GT_Utility.sendSoundToPlayers(
- aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
+ GT_Utility
+ .sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_RUBBER_TRAMPOLINE, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Sonictron.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Sonictron.java
index c29591a560..a191d97209 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Sonictron.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Sonictron.java
@@ -1,9 +1,5 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.interfaces.IItemBehaviour;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
@@ -11,7 +7,13 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
import net.minecraft.world.World;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.interfaces.IItemBehaviour;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Sonictron extends Behaviour_None {
+
public static final IItemBehaviour<GT_MetaBase_Item> INSTANCE = new Behaviour_Sonictron();
public static int getCurrentIndex(ItemStack aStack) {
@@ -96,18 +98,8 @@ public class Behaviour_Sonictron extends Behaviour_None {
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
setCurrentIndex(aStack, -1);
return false;
}
@@ -119,14 +111,18 @@ public class Behaviour_Sonictron extends Behaviour_None {
}
@Override
- public void onUpdate(
- GT_MetaBase_Item aItem, ItemStack aStack, World aWorld, Entity aPlayer, int aTimer, boolean aIsInHand) {
+ public void onUpdate(GT_MetaBase_Item aItem, ItemStack aStack, World aWorld, Entity aPlayer, int aTimer,
+ boolean aIsInHand) {
int tTickTimer = getTickTimer(aStack);
int tCurrentIndex = getCurrentIndex(aStack);
if ((tTickTimer++ % 2 == 0) && (tCurrentIndex > -1)) {
ItemStack[] tInventory = getNBTInventory(aStack);
GT_Values.GT.doSonictronSound(
- tInventory[tCurrentIndex], aPlayer.worldObj, aPlayer.posX, aPlayer.posY, aPlayer.posZ);
+ tInventory[tCurrentIndex],
+ aPlayer.worldObj,
+ aPlayer.posX,
+ aPlayer.posY,
+ aPlayer.posZ);
tCurrentIndex++;
if (tCurrentIndex > 63) {
tCurrentIndex = -1;
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Spray_Color.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Spray_Color.java
index 2ea4eac2ad..a5a47ddb85 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Spray_Color.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Spray_Color.java
@@ -1,14 +1,9 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.Dyes;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Utility;
import java.util.Arrays;
import java.util.Collection;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.BlockColored;
import net.minecraft.entity.player.EntityPlayer;
@@ -19,7 +14,15 @@ import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.enums.Dyes;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Spray_Color extends Behaviour_None {
+
private final ItemStack mEmpty;
private final ItemStack mUsed;
private final ItemStack mFull;
@@ -34,10 +37,10 @@ public class Behaviour_Spray_Color extends Behaviour_None {
Blocks.hardened_clay,
ItemList.TE_Rockwool.getBlock());
private final String mTooltip;
- private final String mTooltipUses =
- GT_LanguageManager.addStringLocalization("gt.behaviour.paintspray.uses", "Remaining Uses:");
- private final String mTooltipUnstackable =
- GT_LanguageManager.addStringLocalization("gt.behaviour.unstackable", "Not usable when stacked!");
+ private final String mTooltipUses = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.paintspray.uses", "Remaining Uses:");
+ private final String mTooltipUnstackable = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.unstackable", "Not usable when stacked!");
public Behaviour_Spray_Color(ItemStack aEmpty, ItemStack aUsed, ItemStack aFull, long aUses, int aColor) {
this.mEmpty = aEmpty;
@@ -51,18 +54,8 @@ public class Behaviour_Spray_Color extends Behaviour_None {
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if ((aWorld.isRemote) || (aStack.stackSize != 1)) {
return false;
}
@@ -136,8 +129,7 @@ public class Behaviour_Spray_Color extends Behaviour_None {
public List<String> getAdditionalToolTips(GT_MetaBase_Item aItem, List<String> aList, ItemStack aStack) {
aList.add(this.mTooltip);
NBTTagCompound tNBT = aStack.getTagCompound();
- long tRemainingPaint = tNBT == null
- ? 0L
+ long tRemainingPaint = tNBT == null ? 0L
: GT_Utility.areStacksEqual(aStack, this.mFull, true) ? this.mUses : tNBT.getLong("GT.RemainingPaint");
aList.add(this.mTooltipUses + " " + tRemainingPaint);
aList.add(this.mTooltipUnstackable);
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Switch_Metadata.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Switch_Metadata.java
index 69e5cb8a81..cd9deb570d 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Switch_Metadata.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Switch_Metadata.java
@@ -1,10 +1,7 @@
package gregtech.common.items.behaviors;
-import gregtech.api.items.GT_Generic_Block;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Util;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
@@ -12,7 +9,13 @@ import net.minecraft.init.Items;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
+import gregtech.api.items.GT_Generic_Block;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Util;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_Switch_Metadata extends Behaviour_None {
+
public final int mSwitchIndex;
public final boolean mCheckTarget, mShowModeSwitchTooltip;
@@ -37,18 +40,8 @@ public class Behaviour_Switch_Metadata extends Behaviour_None {
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float aHitX,
- float aHitY,
- float aHitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float aHitX, float aHitY, float aHitZ) {
if (aStack != null && (aPlayer == null || aPlayer.isSneaking()) && !aWorld.isRemote) {
if (mCheckTarget) {
Block aBlock = aWorld.blockExists(aX, aY, aZ) ? aWorld.getBlock(aX, aY, aZ) : Blocks.air;
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_Wrench.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_Wrench.java
index 8ccbe915b9..64d2660c53 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_Wrench.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_Wrench.java
@@ -1,14 +1,8 @@
package gregtech.common.items.behaviors;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
-import ic2.api.tile.IWrenchable;
import java.util.Arrays;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.item.EntityItem;
import net.minecraft.entity.player.EntityPlayer;
@@ -18,28 +12,27 @@ import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+import ic2.api.tile.IWrenchable;
+
public class Behaviour_Wrench extends Behaviour_None {
+
private final int mCosts;
- private final String mTooltip =
- GT_LanguageManager.addStringLocalization("gt.behaviour.wrench", "Rotates Blocks on Rightclick");
+ private final String mTooltip = GT_LanguageManager
+ .addStringLocalization("gt.behaviour.wrench", "Rotates Blocks on Rightclick");
public Behaviour_Wrench(int aCosts) {
this.mCosts = aCosts;
}
@Override
- public boolean onItemUseFirst(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUseFirst(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if (aWorld.isRemote) {
return false;
}
@@ -82,8 +75,7 @@ public class Behaviour_Wrench extends Behaviour_None {
}
return true;
}
- } catch (Throwable ignored) {
- }
+ } catch (Throwable ignored) {}
if ((aBlock == Blocks.log) || (aBlock == Blocks.log2) || (aBlock == Blocks.hay_block)) {
if ((aPlayer.capabilities.isCreativeMode)
|| (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts))) {
@@ -119,8 +111,7 @@ public class Behaviour_Wrench extends Behaviour_None {
return true;
}
if (aMeta == aTargetSide) {
- if ((aBlock == Blocks.pumpkin)
- || (aBlock == Blocks.lit_pumpkin)
+ if ((aBlock == Blocks.pumpkin) || (aBlock == Blocks.lit_pumpkin)
|| (aBlock == Blocks.piston)
|| (aBlock == Blocks.sticky_piston)
|| (aBlock == Blocks.dispenser)
@@ -141,37 +132,32 @@ public class Behaviour_Wrench extends Behaviour_None {
return true;
}
} else {
- if ((aBlock == Blocks.piston)
- || (aBlock == Blocks.sticky_piston)
+ if ((aBlock == Blocks.piston) || (aBlock == Blocks.sticky_piston)
|| (aBlock == Blocks.dispenser)
|| (aBlock == Blocks.dropper)) {
- if ((aMeta < 6)
- && ((aPlayer.capabilities.isCreativeMode)
- || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
+ if ((aMeta < 6) && ((aPlayer.capabilities.isCreativeMode)
+ || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
aWorld.setBlockMetadataWithNotify(aX, aY, aZ, aTargetSide, 3);
GT_Utility.sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_WRENCH, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
- if ((aBlock == Blocks.pumpkin)
- || (aBlock == Blocks.lit_pumpkin)
+ if ((aBlock == Blocks.pumpkin) || (aBlock == Blocks.lit_pumpkin)
|| (aBlock == Blocks.furnace)
|| (aBlock == Blocks.lit_furnace)
|| (aBlock == Blocks.chest)
|| (aBlock == Blocks.ender_chest)
|| (aBlock == Blocks.trapped_chest)) {
- if ((aTargetSide > 1)
- && ((aPlayer.capabilities.isCreativeMode)
- || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
+ if ((aTargetSide > 1) && ((aPlayer.capabilities.isCreativeMode)
+ || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
aWorld.setBlockMetadataWithNotify(aX, aY, aZ, aTargetSide, 3);
GT_Utility.sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_WRENCH, 1.0F, -1.0F, aX, aY, aZ);
}
return true;
}
if (aBlock == Blocks.hopper) {
- if ((aTargetSide != 1)
- && ((aPlayer.capabilities.isCreativeMode)
- || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
+ if ((aTargetSide != 1) && ((aPlayer.capabilities.isCreativeMode)
+ || (((GT_MetaGenerated_Tool) aItem).doDamage(aStack, this.mCosts)))) {
aWorld.setBlockMetadataWithNotify(aX, aY, aZ, aTargetSide, 3);
GT_Utility.sendSoundToPlayers(aWorld, SoundResource.IC2_TOOLS_WRENCH, 1.0F, -1.0F, aX, aY, aZ);
}
@@ -179,9 +165,8 @@ public class Behaviour_Wrench extends Behaviour_None {
}
}
if ((Arrays.asList(aBlock.getValidRotations(aWorld, aX, aY, aZ))
- .contains(ForgeDirection.getOrientation(aTargetSide)))
- && ((aPlayer.capabilities.isCreativeMode)
- || (!GT_ModHandler.isElectricItem(aStack))
+ .contains(ForgeDirection.getOrientation(aTargetSide)))
+ && ((aPlayer.capabilities.isCreativeMode) || (!GT_ModHandler.isElectricItem(aStack))
|| (GT_ModHandler.canUseElectricItem(aStack, this.mCosts)))
&& (aBlock.rotateBlock(aWorld, aX, aY, aZ, ForgeDirection.getOrientation(aTargetSide)))) {
if (!aPlayer.capabilities.isCreativeMode) {
diff --git a/src/main/java/gregtech/common/items/behaviors/Behaviour_WrittenBook.java b/src/main/java/gregtech/common/items/behaviors/Behaviour_WrittenBook.java
index c923a54948..947442ad8e 100644
--- a/src/main/java/gregtech/common/items/behaviors/Behaviour_WrittenBook.java
+++ b/src/main/java/gregtech/common/items/behaviors/Behaviour_WrittenBook.java
@@ -1,10 +1,7 @@
package gregtech.common.items.behaviors;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.items.GT_MetaBase_Item;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.client.Minecraft;
import net.minecraft.client.entity.EntityPlayerSP;
import net.minecraft.client.gui.GuiScreenBook;
@@ -12,21 +9,17 @@ import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.items.GT_MetaBase_Item;
+import gregtech.api.util.GT_Utility;
+
public class Behaviour_WrittenBook extends Behaviour_None {
+
@Override
@SideOnly(Side.CLIENT)
- public boolean onItemUse(
- GT_MetaBase_Item aItem,
- ItemStack aStack,
- EntityPlayer aPlayer,
- World aWorld,
- int aX,
- int aY,
- int aZ,
- int aSide,
- float hitX,
- float hitY,
- float hitZ) {
+ public boolean onItemUse(GT_MetaBase_Item aItem, ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX,
+ int aY, int aZ, int aSide, float hitX, float hitY, float hitZ) {
if ((GT_Utility.isStringValid(GT_Utility.ItemNBT.getBookTitle(aStack)))
&& ((aPlayer instanceof EntityPlayerSP))) {
Minecraft.getMinecraft().displayGuiScreen(new GuiScreenBook(aPlayer, aStack, false));
diff --git a/src/main/java/gregtech/common/misc/GT_ClientPollutionMap.java b/src/main/java/gregtech/common/misc/GT_ClientPollutionMap.java
index b05e25e1c8..6e40e5860c 100644
--- a/src/main/java/gregtech/common/misc/GT_ClientPollutionMap.java
+++ b/src/main/java/gregtech/common/misc/GT_ClientPollutionMap.java
@@ -5,6 +5,7 @@ import net.minecraft.client.entity.EntityClientPlayerMP;
import net.minecraft.util.MathHelper;
public class GT_ClientPollutionMap {
+
private static final byte RADIUS = 24;
private static final byte DISTANCE_RELOAD_MAP = 5; // When player moved x chunks, shift the map to new center.
private static final byte SIZE = RADIUS * 2 + 1; // Area to keep stored.
@@ -50,14 +51,14 @@ public class GT_ClientPollutionMap {
int relX = chunkX - x0 + RADIUS;
if (relX >= SIZE || relX < 0) // out of bounds
- return;
+ return;
int relZ = chunkZ - z0 + RADIUS;
if (relZ >= SIZE || relZ < 0) // out of bounds
- return;
+ return;
pollution = pollution / 225;
if (pollution > Short.MAX_VALUE) // Sanity
- chunkMatrix[relX][relZ] = Short.MAX_VALUE; // Max pollution = 7,3mill
+ chunkMatrix[relX][relZ] = Short.MAX_VALUE; // Max pollution = 7,3mill
else if (pollution < 0) chunkMatrix[relX][relZ] = 0;
else chunkMatrix[relX][relZ] = (short) (pollution);
}
@@ -99,43 +100,39 @@ public class GT_ClientPollutionMap {
int xDiff = chunkX - x0;
int zDiff = chunkZ - z0;
boolean[] allEmpty = new boolean[SIZE]; // skip check z row if its empty.
- if (xDiff > 0)
- for (byte x = 0; x < SIZE; x++) {
- int xOff = x + xDiff;
- if (xOff < SIZE) {
- chunkMatrix[x] = chunkMatrix[xOff].clone();
- } else {
- chunkMatrix[x] = new short[SIZE];
- allEmpty[x] = true;
- }
+ if (xDiff > 0) for (byte x = 0; x < SIZE; x++) {
+ int xOff = x + xDiff;
+ if (xOff < SIZE) {
+ chunkMatrix[x] = chunkMatrix[xOff].clone();
+ } else {
+ chunkMatrix[x] = new short[SIZE];
+ allEmpty[x] = true;
}
- else if (xDiff < 0)
- for (byte x = SIZE - 1; x >= 0; x--) {
- int xOff = x + xDiff;
- if (xOff > 0) {
- chunkMatrix[x] = chunkMatrix[xOff].clone();
- } else {
- chunkMatrix[x] = new short[SIZE];
- allEmpty[x] = true;
- }
+ }
+ else if (xDiff < 0) for (byte x = SIZE - 1; x >= 0; x--) {
+ int xOff = x + xDiff;
+ if (xOff > 0) {
+ chunkMatrix[x] = chunkMatrix[xOff].clone();
+ } else {
+ chunkMatrix[x] = new short[SIZE];
+ allEmpty[x] = true;
}
+ }
- if (zDiff > 0)
- for (byte x = 0; x < SIZE; x++) {
- if (allEmpty[x]) continue;
- for (int z = 0; z < SIZE; z++) {
- int zOff = z + zDiff;
- chunkMatrix[x][z] = (zOff < SIZE) ? chunkMatrix[x][zOff] : 0;
- }
+ if (zDiff > 0) for (byte x = 0; x < SIZE; x++) {
+ if (allEmpty[x]) continue;
+ for (int z = 0; z < SIZE; z++) {
+ int zOff = z + zDiff;
+ chunkMatrix[x][z] = (zOff < SIZE) ? chunkMatrix[x][zOff] : 0;
}
- else if (zDiff < 0)
- for (byte x = 0; x < SIZE; x++) {
- if (allEmpty[x]) continue;
- for (int z = SIZE - 1; z >= 0; z--) {
- int zOff = z + zDiff;
- chunkMatrix[x][z] = (zOff > 0) ? chunkMatrix[x][zOff] : 0;
- }
+ }
+ else if (zDiff < 0) for (byte x = 0; x < SIZE; x++) {
+ if (allEmpty[x]) continue;
+ for (int z = SIZE - 1; z >= 0; z--) {
+ int zOff = z + zDiff;
+ chunkMatrix[x][z] = (zOff > 0) ? chunkMatrix[x][zOff] : 0;
}
+ }
x0 = chunkX;
z0 = chunkZ;
diff --git a/src/main/java/gregtech/common/misc/GT_Command.java b/src/main/java/gregtech/common/misc/GT_Command.java
index 8c896253fa..c2af60523d 100644
--- a/src/main/java/gregtech/common/misc/GT_Command.java
+++ b/src/main/java/gregtech/common/misc/GT_Command.java
@@ -1,22 +1,25 @@
package gregtech.common.misc;
-import com.gtnewhorizon.structurelib.StructureLib;
-import gregtech.GT_Mod;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.interfaces.IGlobalWirelessEnergy;
-import gregtech.api.objects.GT_ChunkManager;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.GT_Pollution;
import java.lang.reflect.Field;
import java.math.BigInteger;
import java.util.*;
import java.util.stream.Stream;
+
import net.minecraft.command.CommandBase;
import net.minecraft.command.ICommandSender;
import net.minecraft.util.ChatComponentText;
import net.minecraft.util.ChunkCoordinates;
import net.minecraft.util.EnumChatFormatting;
+import com.gtnewhorizon.structurelib.StructureLib;
+
+import gregtech.GT_Mod;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.interfaces.IGlobalWirelessEnergy;
+import gregtech.api.objects.GT_ChunkManager;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.GT_Pollution;
+
public final class GT_Command extends CommandBase implements IGlobalWirelessEnergy {
@Override
@@ -30,16 +33,18 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
}
private void printHelp(ICommandSender sender) {
- sender.addChatMessage(new ChatComponentText(
- "Usage: gt <toggle|chunks|pollution|global_energy_add|global_energy_set|global_energy_join>"));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Usage: gt <toggle|chunks|pollution|global_energy_add|global_energy_set|global_energy_join>"));
sender.addChatMessage(new ChatComponentText("\"toggle D1\" - toggles general.Debug (D1)"));
sender.addChatMessage(new ChatComponentText("\"toggle D2\" - toggles general.Debug2 (D2)"));
sender.addChatMessage(new ChatComponentText("\"toggle debugCleanroom\" - toggles cleanroom debug log"));
sender.addChatMessage(new ChatComponentText("\"toggle debugDriller\" - toggles oil drill debug log"));
sender.addChatMessage(new ChatComponentText("\"toggle debugBlockPump\" - Possible issues with pumps"));
sender.addChatMessage(new ChatComponentText("\"toggle debugBlockMiner\" - Possible issues with miners"));
- sender.addChatMessage(new ChatComponentText(
- "\"toggle debugEntityCramming\" - How long it takes and how many entities it finds"));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "\"toggle debugEntityCramming\" - How long it takes and how many entities it finds"));
sender.addChatMessage(new ChatComponentText("\"toggle debugWorldGen\" - toggles generic worldgen debug"));
sender.addChatMessage(new ChatComponentText("\"toggle debugOrevein\" - toggles worldgen ore vein debug"));
sender.addChatMessage(new ChatComponentText("\"toggle debugSmallOres\" - toggles worldgen small vein debug"));
@@ -47,73 +52,88 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
sender.addChatMessage(new ChatComponentText("\"toggle debugChunkloaders\" - toggles chunkloaders debug"));
sender.addChatMessage(new ChatComponentText("\"toggle debugMulti\" - toggles structurelib debug"));
sender.addChatMessage(new ChatComponentText("\"chunks\" - print a list of the force loaded chunks"));
- sender.addChatMessage(new ChatComponentText(
- "\"pollution <amount>\" - adds the <amount> of the pollution to the current chunk, "
- + "\n if <amount> isnt specified, will add" + GT_Mod.gregtechproxy.mPollutionSmogLimit
- + "gibbl."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "\"pollution <amount>\" - adds the <amount> of the pollution to the current chunk, "
+ + "\n if <amount> isnt specified, will add"
+ + GT_Mod.gregtechproxy.mPollutionSmogLimit
+ + "gibbl."));
sender.addChatMessage(new ChatComponentText(EnumChatFormatting.GOLD + " --- Global wireless EU controls ---"));
sender.addChatMessage(new ChatComponentText("Allows you to set the amount of EU in a users wireless network."));
- sender.addChatMessage(new ChatComponentText("Usage:" + EnumChatFormatting.RED + " global_energy_set "
- + EnumChatFormatting.BLUE + "[Name] " + EnumChatFormatting.LIGHT_PURPLE + "[EU]"));
- sender.addChatMessage(new ChatComponentText(
- "Allows you to add EU to a users wireless network. Also accepts negative numbers."));
- sender.addChatMessage(new ChatComponentText("Usage:" + EnumChatFormatting.RED + " global_energy_add "
- + EnumChatFormatting.BLUE + "[Name] " + EnumChatFormatting.LIGHT_PURPLE + "[EU]"));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Usage:" + EnumChatFormatting.RED
+ + " global_energy_set "
+ + EnumChatFormatting.BLUE
+ + "[Name] "
+ + EnumChatFormatting.LIGHT_PURPLE
+ + "[EU]"));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Allows you to add EU to a users wireless network. Also accepts negative numbers."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Usage:" + EnumChatFormatting.RED
+ + " global_energy_add "
+ + EnumChatFormatting.BLUE
+ + "[Name] "
+ + EnumChatFormatting.LIGHT_PURPLE
+ + "[EU]"));
sender.addChatMessage(
new ChatComponentText(
"Allows you to join two users together into one network. Can be undone by writing the users name twice."));
- sender.addChatMessage(new ChatComponentText("Usage:" + EnumChatFormatting.RED + " global_energy_join "
- + EnumChatFormatting.BLUE + "[User joining] [User to join]"));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Usage:" + EnumChatFormatting.RED
+ + " global_energy_join "
+ + EnumChatFormatting.BLUE
+ + "[User joining] [User to join]"));
sender.addChatMessage(new ChatComponentText("Shows the amount of EU in a users energy network."));
- sender.addChatMessage(new ChatComponentText(
- "Usage:" + EnumChatFormatting.RED + " global_energy_display " + EnumChatFormatting.BLUE + "[Name]"));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Usage:" + EnumChatFormatting.RED
+ + " global_energy_display "
+ + EnumChatFormatting.BLUE
+ + "[Name]"));
}
@Override
public List addTabCompletionOptions(ICommandSender sender, String[] ss) {
List<String> l = new ArrayList<>();
String test = ss.length == 0 ? "" : ss[0].trim();
- if (ss.length == 0
- || ss.length == 1
- && (test.isEmpty()
- || Stream.of(
- "toggle",
- "chunks",
- "pollution",
- "global_energy_add",
- "global_energy_set",
- "global_energy_join",
- "global_energy_display")
- .anyMatch(s -> s.startsWith(test)))) {
+ if (ss.length == 0 || ss.length == 1 && (test.isEmpty() || Stream.of(
+ "toggle",
+ "chunks",
+ "pollution",
+ "global_energy_add",
+ "global_energy_set",
+ "global_energy_join",
+ "global_energy_display").anyMatch(s -> s.startsWith(test)))) {
Stream.of(
- "toggle",
- "chunks",
- "pollution",
- "global_energy_add",
- "global_energy_set",
- "global_energy_join",
- "global_energy_display")
- .filter(s -> test.isEmpty() || s.startsWith(test))
- .forEach(l::add);
+ "toggle",
+ "chunks",
+ "pollution",
+ "global_energy_add",
+ "global_energy_set",
+ "global_energy_join",
+ "global_energy_display").filter(s -> test.isEmpty() || s.startsWith(test)).forEach(l::add);
} else if (test.equals("toggle")) {
String test1 = ss[1].trim();
Stream.of(
- "D1",
- "D2",
- "debugCleanroom",
- "debugDriller",
- "debugBlockPump",
- "debugBlockMiner",
- "debugWorldGen",
- "debugEntityCramming",
- "debugOrevein",
- "debugSmallOres",
- "debugStones",
- "debugChunkloaders",
- "debugMulti",
- "debugWorldData")
- .filter(s -> test1.isEmpty() || s.startsWith(test1))
- .forEach(l::add);
+ "D1",
+ "D2",
+ "debugCleanroom",
+ "debugDriller",
+ "debugBlockPump",
+ "debugBlockMiner",
+ "debugWorldGen",
+ "debugEntityCramming",
+ "debugOrevein",
+ "debugSmallOres",
+ "debugStones",
+ "debugChunkloaders",
+ "debugMulti",
+ "debugWorldData").filter(s -> test1.isEmpty() || s.startsWith(test1)).forEach(l::add);
}
return l;
}
@@ -155,10 +175,11 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
break;
case "pollution":
ChunkCoordinates coordinates = sender.getPlayerCoordinates();
- int amount =
- (strings.length < 2) ? GT_Mod.gregtechproxy.mPollutionSmogLimit : Integer.parseInt(strings[1]);
+ int amount = (strings.length < 2) ? GT_Mod.gregtechproxy.mPollutionSmogLimit
+ : Integer.parseInt(strings[1]);
GT_Pollution.addPollution(
- sender.getEntityWorld().getChunkFromBlockCoords(coordinates.posX, coordinates.posZ), amount);
+ sender.getEntityWorld().getChunkFromBlockCoords(coordinates.posX, coordinates.posZ),
+ amount);
break;
case "global_energy_add": {
String username = strings[1];
@@ -179,19 +200,26 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
+ GT_Utility.formatNumbers(new BigInteger(EU_String))
+ EnumChatFormatting.RESET;
- if (addEUToGlobalEnergyMap(uuid, new BigInteger(EU_String)))
- sender.addChatMessage(new ChatComponentText("Successfully added " + EU_string_formatted
- + "EU to the global energy network of " + formatted_username + "."));
- else
- sender.addChatMessage(new ChatComponentText(
- "Failed to add " + EU_string_formatted + "EU to the global energy map of "
- + formatted_username + ". Insufficient energy in network. "));
+ if (addEUToGlobalEnergyMap(uuid, new BigInteger(EU_String))) sender.addChatMessage(
+ new ChatComponentText(
+ "Successfully added " + EU_string_formatted
+ + "EU to the global energy network of "
+ + formatted_username
+ + "."));
+ else sender.addChatMessage(
+ new ChatComponentText(
+ "Failed to add " + EU_string_formatted
+ + "EU to the global energy map of "
+ + formatted_username
+ + ". Insufficient energy in network. "));
sender.addChatMessage(
- new ChatComponentText(formatted_username + " currently has " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(
- new BigInteger(getUserEU(uuid).toString()))
- + EnumChatFormatting.RESET + "EU in their network."));
+ new ChatComponentText(
+ formatted_username + " currently has "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(new BigInteger(getUserEU(uuid).toString()))
+ + EnumChatFormatting.RESET
+ + "EU in their network."));
break;
}
@@ -219,9 +247,14 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
setUserEU(uuid, new BigInteger(EU_String_0));
- sender.addChatMessage(new ChatComponentText("Successfully set " + formatted_username
- + "'s global energy network to " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(new BigInteger(EU_String_0)) + EnumChatFormatting.RESET + "EU."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Successfully set " + formatted_username
+ + "'s global energy network to "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(new BigInteger(EU_String_0))
+ + EnumChatFormatting.RESET
+ + "EU."));
break;
}
@@ -240,11 +273,16 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
if (uuid_1.equals("") && uuid_0.equals("")) {
if (username_0.equals(username_1)) {
- sender.addChatMessage(new ChatComponentText(
- "User " + formatted_username_0 + " has no global energy network."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "User " + formatted_username_0 + " has no global energy network."));
} else {
- sender.addChatMessage(new ChatComponentText("User " + formatted_username_0 + " and "
- + formatted_username_1 + " have no global energy networks."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "User " + formatted_username_0
+ + " and "
+ + formatted_username_1
+ + " have no global energy networks."));
}
break;
}
@@ -263,18 +301,24 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
if (uuid_0.equals(uuid_1)) {
joinUserNetwork(uuid_0, uuid_1);
- sender.addChatMessage(new ChatComponentText(
- "User " + formatted_username_0 + " has rejoined their own global energy network."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "User " + formatted_username_0 + " has rejoined their own global energy network."));
break;
}
joinUserNetwork(uuid_0, uuid_1);
- sender.addChatMessage(new ChatComponentText(
- "Success! " + formatted_username_0 + " has joined " + formatted_username_1 + "."));
- sender.addChatMessage(new ChatComponentText(
- "To undo this simply join your own network again with /gt global_energy_join "
- + formatted_username_0 + " " + formatted_username_0 + "."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "Success! " + formatted_username_0 + " has joined " + formatted_username_1 + "."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "To undo this simply join your own network again with /gt global_energy_join "
+ + formatted_username_0
+ + " "
+ + formatted_username_0
+ + "."));
break;
}
@@ -292,9 +336,14 @@ public final class GT_Command extends CommandBase implements IGlobalWirelessEner
break;
}
- sender.addChatMessage(new ChatComponentText("User " + formatted_username + " has "
- + EnumChatFormatting.RED + GT_Utility.formatNumbers(getUserEU(uuid)) + EnumChatFormatting.RESET
- + "EU in their network."));
+ sender.addChatMessage(
+ new ChatComponentText(
+ "User " + formatted_username
+ + " has "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(getUserEU(uuid))
+ + EnumChatFormatting.RESET
+ + "EU in their network."));
break;
}
diff --git a/src/main/java/gregtech/common/misc/GT_DrillingLogicDelegate.java b/src/main/java/gregtech/common/misc/GT_DrillingLogicDelegate.java
index 35a47fed87..9edee98725 100644
--- a/src/main/java/gregtech/common/misc/GT_DrillingLogicDelegate.java
+++ b/src/main/java/gregtech/common/misc/GT_DrillingLogicDelegate.java
@@ -2,25 +2,28 @@ package gregtech.common.misc;
import static gregtech.api.enums.GT_Values.debugBlockMiner;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.blocks.GT_TileEntity_Ores;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.init.Blocks;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.util.FakePlayer;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.blocks.GT_TileEntity_Ores;
+
/** @author Relvl on 27.01.2022 */
@SuppressWarnings("ObjectEquality")
public class GT_DrillingLogicDelegate {
+
public static final ItemStack MINING_PIPE_STACK = GT_ModHandler.getIC2Item("miningPipe", 0);
public static final Block MINING_PIPE_BLOCK = GT_Utility.getBlockFromStack(MINING_PIPE_STACK);
- public static final Block MINING_PIPE_TIP_BLOCK =
- GT_Utility.getBlockFromStack(GT_ModHandler.getIC2Item("miningPipeTip", 0));
+ public static final Block MINING_PIPE_TIP_BLOCK = GT_Utility
+ .getBlockFromStack(GT_ModHandler.getIC2Item("miningPipeTip", 0));
/** The owner machine pointer */
private final GT_IDrillingLogicDelegateOwner owner;
@@ -140,9 +143,13 @@ public class GT_DrillingLogicDelegate {
owner.getBaseMetaTileEntity().getWorld().setBlock(xCoord, actualDrillY + 1, zCoord, MINING_PIPE_TIP_BLOCK);
}
// Remove the old pipe tip
- aBaseMetaTileEntity
- .getWorld()
- .setBlock(xCoord, actualDrillY, zCoord, Blocks.air, 0, /*send to client without neighbour updates*/ 2);
+ aBaseMetaTileEntity.getWorld().setBlock(
+ xCoord,
+ actualDrillY,
+ zCoord,
+ Blocks.air,
+ 0,
+ /* send to client without neighbour updates */ 2);
// Return the pipe back to the machine (inputs allowed for this case!)
owner.pushOutputs(MINING_PIPE_STACK, 1, false, true);
@@ -176,17 +183,19 @@ public class GT_DrillingLogicDelegate {
}
ItemStack cobble = GT_Utility.getCobbleForOre(block, metaData);
- te.getWorld()
- .setBlock(
- x,
- y,
- z,
- Block.getBlockFromItem(cobble.getItem()),
- cobble.getItemDamage(), /*cause updates(1) + send to client(2)*/
- 3);
+ te.getWorld().setBlock(
+ x,
+ y,
+ z,
+ Block.getBlockFromItem(cobble.getItem()),
+ cobble.getItemDamage(), /* cause updates(1) + send to client(2) */
+ 3);
}
- /** Returns NEGATIVE (eg -5) depth of current drilling Y world level. RELATIVELY TO MINER ENTITY! This means '(miner world Y) + depth = (actual world Y)'. */
+ /**
+ * Returns NEGATIVE (eg -5) depth of current drilling Y world level. RELATIVELY TO MINER ENTITY! This means '(miner
+ * world Y) + depth = (actual world Y)'.
+ */
public int getTipDepth() {
return tipDepth;
}
@@ -206,7 +215,10 @@ public class GT_DrillingLogicDelegate {
}
}
- /** Creates and provides the Fake Player for owners. todo maybe will provide player owner uuid? im sure some servers not allow to fakers, in griefing reasons. */
+ /**
+ * Creates and provides the Fake Player for owners. todo maybe will provide player owner uuid? im sure some servers
+ * not allow to fakers, in griefing reasons.
+ */
public FakePlayer getFakePlayer(IGregTechTileEntity te) {
if (mFakePlayer == null) {
mFakePlayer = GT_Utility.getFakePlayer(te);
@@ -219,8 +231,8 @@ public class GT_DrillingLogicDelegate {
}
public boolean canFakePlayerInteract(IGregTechTileEntity te, int xCoord, int yCoord, int zCoord) {
- return GT_Utility.setBlockByFakePlayer(
- getFakePlayer(te), xCoord, yCoord, zCoord, MINING_PIPE_TIP_BLOCK, 0, true);
+ return GT_Utility
+ .setBlockByFakePlayer(getFakePlayer(te), xCoord, yCoord, zCoord, MINING_PIPE_TIP_BLOCK, 0, true);
}
/** Get target block drops. We need to encapsulate everyting of mining in this class. */
diff --git a/src/main/java/gregtech/common/misc/GT_IDrillingLogicDelegateOwner.java b/src/main/java/gregtech/common/misc/GT_IDrillingLogicDelegateOwner.java
index f290e8ac8c..9b10b6fcf0 100644
--- a/src/main/java/gregtech/common/misc/GT_IDrillingLogicDelegateOwner.java
+++ b/src/main/java/gregtech/common/misc/GT_IDrillingLogicDelegateOwner.java
@@ -1,9 +1,10 @@
package gregtech.common.misc;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+
/** @author Relvl on 27.01.2022 */
public interface GT_IDrillingLogicDelegateOwner extends IMetaTileEntity {
diff --git a/src/main/java/gregtech/common/misc/GlobalEnergyWorldSavedData.java b/src/main/java/gregtech/common/misc/GlobalEnergyWorldSavedData.java
index 621fb3beae..63cf6cfa60 100644
--- a/src/main/java/gregtech/common/misc/GlobalEnergyWorldSavedData.java
+++ b/src/main/java/gregtech/common/misc/GlobalEnergyWorldSavedData.java
@@ -2,16 +2,18 @@ package gregtech.common.misc;
import static gregtech.common.misc.GlobalVariableStorage.*;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import java.io.*;
import java.math.BigInteger;
import java.util.HashMap;
+
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.world.World;
import net.minecraft.world.WorldSavedData;
import net.minecraft.world.storage.MapStorage;
import net.minecraftforge.event.world.WorldEvent;
+import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+
public class GlobalEnergyWorldSavedData extends WorldSavedData {
public static GlobalEnergyWorldSavedData INSTANCE;
diff --git a/src/main/java/gregtech/common/net/MessageSetFlaskCapacity.java b/src/main/java/gregtech/common/net/MessageSetFlaskCapacity.java
index 7ef0244b36..6c51663c47 100644
--- a/src/main/java/gregtech/common/net/MessageSetFlaskCapacity.java
+++ b/src/main/java/gregtech/common/net/MessageSetFlaskCapacity.java
@@ -1,9 +1,5 @@
package gregtech.common.net;
-import com.google.common.io.ByteArrayDataInput;
-import gregtech.api.net.GT_Packet_New;
-import gregtech.common.items.GT_VolumetricFlask;
-import io.netty.buffer.ByteBuf;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
@@ -11,8 +7,15 @@ import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.DimensionManager;
+import com.google.common.io.ByteArrayDataInput;
+
+import gregtech.api.net.GT_Packet_New;
+import gregtech.common.items.GT_VolumetricFlask;
+import io.netty.buffer.ByteBuf;
+
@Deprecated
public final class MessageSetFlaskCapacity extends GT_Packet_New {
+
private int capacity, dimID, playerID;
public MessageSetFlaskCapacity() {
diff --git a/src/main/java/gregtech/common/net/MessageUpdateFluidDisplayItem.java b/src/main/java/gregtech/common/net/MessageUpdateFluidDisplayItem.java
index 619f528502..8d3b60e0f0 100644
--- a/src/main/java/gregtech/common/net/MessageUpdateFluidDisplayItem.java
+++ b/src/main/java/gregtech/common/net/MessageUpdateFluidDisplayItem.java
@@ -1,16 +1,19 @@
package gregtech.common.net;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.WorldServer;
+import net.minecraftforge.common.DimensionManager;
+
import com.google.common.io.ByteArrayDataInput;
+
import gregtech.api.interfaces.IHasFluidDisplayItem;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.net.GT_Packet_New;
import io.netty.buffer.ByteBuf;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.WorldServer;
-import net.minecraftforge.common.DimensionManager;
public class MessageUpdateFluidDisplayItem extends GT_Packet_New {
+
private int mBlockX, mBlockY, mBlockZ, mDim;
public MessageUpdateFluidDisplayItem() {
diff --git a/src/main/java/gregtech/common/power/BasicMachineEUPower.java b/src/main/java/gregtech/common/power/BasicMachineEUPower.java
index 9a858838a9..14f1d27a3f 100644
--- a/src/main/java/gregtech/common/power/BasicMachineEUPower.java
+++ b/src/main/java/gregtech/common/power/BasicMachineEUPower.java
@@ -3,6 +3,7 @@ package gregtech.common.power;
import static gregtech.api.enums.GT_Values.V;
public class BasicMachineEUPower extends EUPower {
+
protected static final String OC = " (OC)";
protected boolean wasOverclocked;
@@ -36,9 +37,8 @@ public class BasicMachineEUPower extends EUPower {
tempEUt <<= 2; // this actually controls overclocking
// xEUt *= 4;//this is effect of everclocking
recipeDuration >>= 1; // this is effect of overclocking
- xEUt = recipeDuration == 0
- ? xEUt >> 1
- : xEUt << 2; // U know, if the time is less than 1 tick make the machine use 2x less power
+ xEUt = recipeDuration == 0 ? xEUt >> 1 : xEUt << 2; // U know, if the time is less than 1 tick make the
+ // machine use 2x less power
}
if (xEUt > Integer.MAX_VALUE - 1) {
recipeEuPerTick = Integer.MAX_VALUE - 1;
diff --git a/src/main/java/gregtech/common/power/EUPower.java b/src/main/java/gregtech/common/power/EUPower.java
index c074cc0b69..815ae0c190 100644
--- a/src/main/java/gregtech/common/power/EUPower.java
+++ b/src/main/java/gregtech/common/power/EUPower.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.GT_Values;
import gregtech.api.util.GT_Utility;
public class EUPower extends Power {
+
protected final int amperage;
protected int originalVoltage;
diff --git a/src/main/java/gregtech/common/power/Power.java b/src/main/java/gregtech/common/power/Power.java
index d4cd5c5342..13d1cc37c1 100644
--- a/src/main/java/gregtech/common/power/Power.java
+++ b/src/main/java/gregtech/common/power/Power.java
@@ -3,6 +3,7 @@ package gregtech.common.power;
import gregtech.api.util.GT_Utility;
public abstract class Power {
+
protected final byte tier;
protected int recipeEuPerTick;
protected int recipeDuration;
diff --git a/src/main/java/gregtech/common/power/SteamPower.java b/src/main/java/gregtech/common/power/SteamPower.java
index b6fd75850c..c79069e261 100644
--- a/src/main/java/gregtech/common/power/SteamPower.java
+++ b/src/main/java/gregtech/common/power/SteamPower.java
@@ -3,9 +3,10 @@ package gregtech.common.power;
import gregtech.api.util.GT_Utility;
public class SteamPower extends Power {
+
private final double euPerTickOverride;
private final double durationOverride;
- private final String[] STEAM_TIER_NAMES = {"Bronze", "Steel"};
+ private final String[] STEAM_TIER_NAMES = { "Bronze", "Steel" };
public SteamPower(byte tier, double euPerTickMultiplier, double durationMultiplier) {
super(tier);
diff --git a/src/main/java/gregtech/common/power/UnspecifiedEUPower.java b/src/main/java/gregtech/common/power/UnspecifiedEUPower.java
index 5ac85adfee..e411f03613 100644
--- a/src/main/java/gregtech/common/power/UnspecifiedEUPower.java
+++ b/src/main/java/gregtech/common/power/UnspecifiedEUPower.java
@@ -3,6 +3,7 @@ package gregtech.common.power;
import gregtech.api.util.GT_Utility;
public class UnspecifiedEUPower extends EUPower {
+
private final String VOLTAGE = GT_Utility.trans("271", "unspecified");
private final String AMPERAGE = GT_Utility.trans("271", "unspecified");
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BasicLogic.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BasicLogic.java
index 41ccf9f98c..ad9b0798dc 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BasicLogic.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BasicLogic.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_BasicLogic extends GT_CircuitryBehavior {
+
public GT_Circuit_BasicLogic(int aIndex) {
super(aIndex);
}
@@ -39,17 +40,16 @@ public class GT_Circuit_BasicLogic extends GT_CircuitryBehavior {
aRedstoneCircuitBlock.getOutputFacing());
} else if (aCircuitData[0] < 7) {
aRedstoneCircuitBlock.setRedstone(
- (byte) (15 - getStrongestRedstone(aRedstoneCircuitBlock)), aRedstoneCircuitBlock.getOutputFacing());
+ (byte) (15 - getStrongestRedstone(aRedstoneCircuitBlock)),
+ aRedstoneCircuitBlock.getOutputFacing());
} else if (aCircuitData[0] < 9) {
aRedstoneCircuitBlock.setRedstone(
- (byte) ((aCircuitData[0] % 2 == 0 ? 15 : 0)
- ^ (getStrongestRedstone(aRedstoneCircuitBlock)
- | getWeakestRedstone(aRedstoneCircuitBlock))),
+ (byte) ((aCircuitData[0] % 2 == 0 ? 15 : 0) ^ (getStrongestRedstone(aRedstoneCircuitBlock)
+ | getWeakestRedstone(aRedstoneCircuitBlock))),
aRedstoneCircuitBlock.getOutputFacing());
} else if (aCircuitData[0] < 11) {
aRedstoneCircuitBlock.setRedstone(
- (byte) ((aCircuitData[0] % 2 == 0 ? 15 : 0)
- ^ getStrongestRedstone(aRedstoneCircuitBlock)
+ (byte) ((aCircuitData[0] % 2 == 0 ? 15 : 0) ^ getStrongestRedstone(aRedstoneCircuitBlock)
^ getWeakestRedstone(aRedstoneCircuitBlock)),
aRedstoneCircuitBlock.getOutputFacing());
} else if (aCircuitData[0] < 13) {
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BitAnd.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BitAnd.java
index 501f7b7785..f5d2fca824 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BitAnd.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_BitAnd.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_BitAnd extends GT_CircuitryBehavior {
+
public GT_Circuit_BitAnd(int aIndex) {
super(aIndex);
}
@@ -47,13 +48,8 @@ public class GT_Circuit_BitAnd extends GT_CircuitryBehavior {
@Override
public void onTick(int[] aCircuitData, IRedstoneCircuitBlock aRedstoneCircuitBlock) {
aRedstoneCircuitBlock.setRedstone(
- (byte)
- ((getStrongestRedstone(aRedstoneCircuitBlock)
- & (aCircuitData[0]
- | aCircuitData[1] << 1
- | aCircuitData[2] << 2
- | aCircuitData[3] << 3))
- != 0
+ (byte) ((getStrongestRedstone(aRedstoneCircuitBlock)
+ & (aCircuitData[0] | aCircuitData[1] << 1 | aCircuitData[2] << 2 | aCircuitData[3] << 3)) != 0
? 15
: 0),
aRedstoneCircuitBlock.getOutputFacing());
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_CombinationLock.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_CombinationLock.java
index 827e4a341e..67d8527606 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_CombinationLock.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_CombinationLock.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_CombinationLock extends GT_CircuitryBehavior {
+
public GT_Circuit_CombinationLock(int aIndex) {
super(aIndex);
}
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Equals.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Equals.java
index c493e32e29..e162040f00 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Equals.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Equals.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_Equals extends GT_CircuitryBehavior {
+
public GT_Circuit_Equals(int aIndex) {
super(aIndex);
}
@@ -33,10 +34,9 @@ public class GT_Circuit_Equals extends GT_CircuitryBehavior {
@Override
public void onTick(int[] aCircuitData, IRedstoneCircuitBlock aRedstoneCircuitBlock) {
aRedstoneCircuitBlock.setRedstone(
- ((byte)
- (((aCircuitData[1] != 0) == (getStrongestRedstone(aRedstoneCircuitBlock) == aCircuitData[0]))
- ? 0
- : 15)),
+ ((byte) (((aCircuitData[1] != 0) == (getStrongestRedstone(aRedstoneCircuitBlock) == aCircuitData[0]))
+ ? 0
+ : 15)),
aRedstoneCircuitBlock.getOutputFacing());
}
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Pulser.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Pulser.java
index 844817e4c3..7f6858b09f 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Pulser.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Pulser.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_Pulser extends GT_CircuitryBehavior {
+
public GT_Circuit_Pulser(int aIndex) {
super(aIndex);
}
@@ -33,8 +34,7 @@ public class GT_Circuit_Pulser extends GT_CircuitryBehavior {
@Override
public void onTick(int[] aCircuitData, IRedstoneCircuitBlock aRedstoneCircuitBlock) {
- byte tRedstone = aCircuitData[1] == 0
- ? getWeakestNonZeroRedstone(aRedstoneCircuitBlock)
+ byte tRedstone = aCircuitData[1] == 0 ? getWeakestNonZeroRedstone(aRedstoneCircuitBlock)
: getStrongestRedstone(aRedstoneCircuitBlock);
if (aCircuitData[4] == 0) {
aCircuitData[5] = tRedstone;
@@ -49,10 +49,8 @@ public class GT_Circuit_Pulser extends GT_CircuitryBehavior {
}
}
aRedstoneCircuitBlock.setRedstone(
- (byte)
- ((aCircuitData[4] > 0) && (aCircuitData[4] <= aCircuitData[0])
- ? (byte) aCircuitData[1]
- : (aCircuitData[1] <= 0) || (aCircuitData[1] > 15) ? (byte) aCircuitData[5] : 0),
+ (byte) ((aCircuitData[4] > 0) && (aCircuitData[4] <= aCircuitData[0]) ? (byte) aCircuitData[1]
+ : (aCircuitData[1] <= 0) || (aCircuitData[1] > 15) ? (byte) aCircuitData[5] : 0),
aRedstoneCircuitBlock.getOutputFacing());
}
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Randomizer.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Randomizer.java
index e666d50e99..a8421d089b 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Randomizer.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Randomizer.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_Randomizer extends GT_CircuitryBehavior {
+
public GT_Circuit_Randomizer(int aIndex) {
super(aIndex);
}
@@ -45,8 +46,8 @@ public class GT_Circuit_Randomizer extends GT_CircuitryBehavior {
}
if (aCircuitData[4] >= aCircuitData[0]) {
aCircuitData[4] = 0;
- aRedstoneCircuitBlock.setRedstone(
- (byte) aRedstoneCircuitBlock.getRandom(16), aRedstoneCircuitBlock.getOutputFacing());
+ aRedstoneCircuitBlock
+ .setRedstone((byte) aRedstoneCircuitBlock.getRandom(16), aRedstoneCircuitBlock.getOutputFacing());
}
}
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_RedstoneMeter.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_RedstoneMeter.java
index 2dd4f73bb5..7755630b26 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_RedstoneMeter.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_RedstoneMeter.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_RedstoneMeter extends GT_CircuitryBehavior {
+
public GT_Circuit_RedstoneMeter(int aIndex) {
super(aIndex);
}
@@ -51,11 +52,8 @@ public class GT_Circuit_RedstoneMeter extends GT_CircuitryBehavior {
public void onTick(int[] aCircuitData, IRedstoneCircuitBlock aRedstoneCircuitBlock) {
byte tRedstone = getStrongestRedstone(aRedstoneCircuitBlock);
aRedstoneCircuitBlock.setRedstone(
- (byte)
- (((tRedstone >= aCircuitData[0]) && (tRedstone <= aCircuitData[1]) ? 1 : 0)
- != (aCircuitData[2] != 0 ? 1 : 0)
- ? (byte) aCircuitData[3]
- : 0),
+ (byte) (((tRedstone >= aCircuitData[0]) && (tRedstone <= aCircuitData[1]) ? 1 : 0)
+ != (aCircuitData[2] != 0 ? 1 : 0) ? (byte) aCircuitData[3] : 0),
aRedstoneCircuitBlock.getOutputFacing());
}
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Repeater.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Repeater.java
index 61432610a9..b96762d73b 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Repeater.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Repeater.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_Repeater extends GT_CircuitryBehavior {
+
public GT_Circuit_Repeater(int aIndex) {
super(aIndex);
}
diff --git a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Timer.java b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Timer.java
index f207609940..c592d10e99 100644
--- a/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Timer.java
+++ b/src/main/java/gregtech/common/redstonecircuits/GT_Circuit_Timer.java
@@ -4,6 +4,7 @@ import gregtech.api.interfaces.IRedstoneCircuitBlock;
import gregtech.api.util.GT_CircuitryBehavior;
public class GT_Circuit_Timer extends GT_CircuitryBehavior {
+
public GT_Circuit_Timer(int aIndex) {
super(aIndex);
}
diff --git a/src/main/java/gregtech/common/render/CosmicItemRendererGT.java b/src/main/java/gregtech/common/render/CosmicItemRendererGT.java
index d8539a6f9a..cea0fd684f 100644
--- a/src/main/java/gregtech/common/render/CosmicItemRendererGT.java
+++ b/src/main/java/gregtech/common/render/CosmicItemRendererGT.java
@@ -1,12 +1,14 @@
package gregtech.common.render;
-import fox.spiteful.avaritia.render.CosmicItemRenderer;
import java.util.*;
+
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraftforge.oredict.OreDictionary;
+import fox.spiteful.avaritia.render.CosmicItemRenderer;
+
public class CosmicItemRendererGT extends CosmicItemRenderer {
private static CosmicItemRendererGT sInstance = null;
diff --git a/src/main/java/gregtech/common/render/GT_CapeRenderer.java b/src/main/java/gregtech/common/render/GT_CapeRenderer.java
index 2d946efd04..1a6d44ca5b 100644
--- a/src/main/java/gregtech/common/render/GT_CapeRenderer.java
+++ b/src/main/java/gregtech/common/render/GT_CapeRenderer.java
@@ -1,9 +1,7 @@
package gregtech.common.render;
-import gregtech.api.enums.GT_Values;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_Utility;
import java.util.Collection;
+
import net.minecraft.client.entity.AbstractClientPlayer;
import net.minecraft.client.model.ModelBiped;
import net.minecraft.client.renderer.entity.RenderManager;
@@ -12,21 +10,24 @@ import net.minecraft.potion.Potion;
import net.minecraft.util.MathHelper;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.client.event.RenderPlayerEvent;
+
import org.lwjgl.opengl.GL11;
+import gregtech.api.enums.GT_Values;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_Utility;
+
public class GT_CapeRenderer extends RenderPlayer {
- private final ResourceLocation[] mCapes = {
- new ResourceLocation("gregtech:textures/BrainTechCape.png"),
- new ResourceLocation("gregtech:textures/GregTechCape.png"),
- new ResourceLocation("gregtech:textures/MrBrainCape.png"),
- new ResourceLocation("gregtech:textures/GregoriusCape.png"),
- new ResourceLocation("gregtech:textures/DonorCape.png"),
- new ResourceLocation("gregtech:textures/DevCape.png"),
- new ResourceLocation("gregtech:textures/Steam.png"),
- new ResourceLocation("gregtech:textures/Titanium.png"),
- new ResourceLocation("gregtech:textures/Neutronium.png"),
- new ResourceLocation("gregtech:textures/Stargate.png")
- };
+
+ private final ResourceLocation[] mCapes = { new ResourceLocation("gregtech:textures/BrainTechCape.png"),
+ new ResourceLocation("gregtech:textures/GregTechCape.png"),
+ new ResourceLocation("gregtech:textures/MrBrainCape.png"),
+ new ResourceLocation("gregtech:textures/GregoriusCape.png"),
+ new ResourceLocation("gregtech:textures/DonorCape.png"),
+ new ResourceLocation("gregtech:textures/DevCape.png"), new ResourceLocation("gregtech:textures/Steam.png"),
+ new ResourceLocation("gregtech:textures/Titanium.png"),
+ new ResourceLocation("gregtech:textures/Neutronium.png"),
+ new ResourceLocation("gregtech:textures/Stargate.png") };
private final Collection<String> mCapeList;
public GT_CapeRenderer(Collection<String> aCapeList) {
@@ -84,14 +85,11 @@ public class GT_CapeRenderer extends RenderPlayer {
bindTexture(tResource);
GL11.glPushMatrix();
GL11.glTranslatef(0.0F, 0.0F, 0.125F);
- double d0 = aPlayer.field_71091_bM
- + (aPlayer.field_71094_bP - aPlayer.field_71091_bM) * aPartialTicks
+ double d0 = aPlayer.field_71091_bM + (aPlayer.field_71094_bP - aPlayer.field_71091_bM) * aPartialTicks
- (aPlayer.prevPosX + (aPlayer.posX - aPlayer.prevPosX) * aPartialTicks);
- double d1 = aPlayer.field_71096_bN
- + (aPlayer.field_71095_bQ - aPlayer.field_71096_bN) * aPartialTicks
+ double d1 = aPlayer.field_71096_bN + (aPlayer.field_71095_bQ - aPlayer.field_71096_bN) * aPartialTicks
- (aPlayer.prevPosY + (aPlayer.posY - aPlayer.prevPosY) * aPartialTicks);
- double d2 = aPlayer.field_71097_bO
- + (aPlayer.field_71085_bR - aPlayer.field_71097_bO) * aPartialTicks
+ double d2 = aPlayer.field_71097_bO + (aPlayer.field_71085_bR - aPlayer.field_71097_bO) * aPartialTicks
- (aPlayer.prevPosZ + (aPlayer.posZ - aPlayer.prevPosZ) * aPartialTicks);
float f6 = aPlayer.prevRenderYawOffset
+ (aPlayer.renderYawOffset - aPlayer.prevRenderYawOffset) * aPartialTicks;
@@ -110,9 +108,9 @@ public class GT_CapeRenderer extends RenderPlayer {
f8 = 0.0F;
}
float f10 = aPlayer.prevCameraYaw + (aPlayer.cameraYaw - aPlayer.prevCameraYaw) * aPartialTicks;
- f7 += MathHelper.sin((aPlayer.prevDistanceWalkedModified
- + (aPlayer.distanceWalkedModified - aPlayer.prevDistanceWalkedModified)
- * aPartialTicks)
+ f7 += MathHelper.sin(
+ (aPlayer.prevDistanceWalkedModified
+ + (aPlayer.distanceWalkedModified - aPlayer.prevDistanceWalkedModified) * aPartialTicks)
* 6.0F)
* 32.0F
* f10;
diff --git a/src/main/java/gregtech/common/render/GT_CopiedBlockTexture.java b/src/main/java/gregtech/common/render/GT_CopiedBlockTexture.java
index 2f6c691253..f0df8277ee 100644
--- a/src/main/java/gregtech/common/render/GT_CopiedBlockTexture.java
+++ b/src/main/java/gregtech/common/render/GT_CopiedBlockTexture.java
@@ -1,14 +1,16 @@
package gregtech.common.render;
-import gregtech.api.interfaces.IBlockContainer;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.util.LightingHelper;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.util.IIcon;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.interfaces.IBlockContainer;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.util.LightingHelper;
+
public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, IBlockContainer {
+
private final Block mBlock;
private final byte mSide, mMeta;
@@ -34,8 +36,7 @@ public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, I
final IIcon aIcon = getIcon(ForgeDirection.EAST.ordinal());
aRenderer.field_152631_f = true;
startDrawingQuads(aRenderer, 1.0f, 0.0f, 0.0f);
- new LightingHelper(aRenderer)
- .setupLightingXPos(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingXPos(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.EAST.ordinal(), 0xffffff);
aRenderer.renderFaceXPos(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
@@ -46,8 +47,7 @@ public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, I
public void renderXNeg(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, -1.0f, 0.0f, 0.0f);
final IIcon aIcon = getIcon(ForgeDirection.WEST.ordinal());
- new LightingHelper(aRenderer)
- .setupLightingXNeg(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingXNeg(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.WEST.ordinal(), 0xffffff);
aRenderer.renderFaceXNeg(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
@@ -57,8 +57,7 @@ public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, I
public void renderYPos(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, 0.0f, 1.0f, 0.0f);
final IIcon aIcon = getIcon(ForgeDirection.UP.ordinal());
- new LightingHelper(aRenderer)
- .setupLightingYPos(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingYPos(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.UP.ordinal(), 0xffffff);
aRenderer.renderFaceYPos(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
@@ -68,8 +67,7 @@ public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, I
public void renderYNeg(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, 0.0f, -1.0f, 0.0f);
final IIcon aIcon = getIcon(ForgeDirection.DOWN.ordinal());
- new LightingHelper(aRenderer)
- .setupLightingYNeg(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingYNeg(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.DOWN.ordinal(), 0xffffff);
aRenderer.renderFaceYNeg(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
@@ -79,8 +77,7 @@ public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, I
public void renderZPos(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, 0.0f, 0.0f, 1.0f);
final IIcon aIcon = getIcon(ForgeDirection.SOUTH.ordinal());
- new LightingHelper(aRenderer)
- .setupLightingZPos(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingZPos(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.SOUTH.ordinal(), 0xffffff);
aRenderer.renderFaceZPos(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
@@ -91,8 +88,7 @@ public class GT_CopiedBlockTexture extends GT_TextureBase implements ITexture, I
startDrawingQuads(aRenderer, 0.0f, 0.0f, -1.0f);
final IIcon aIcon = getIcon(ForgeDirection.NORTH.ordinal());
aRenderer.field_152631_f = true;
- new LightingHelper(aRenderer)
- .setupLightingZNeg(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingZNeg(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.NORTH.ordinal(), 0xffffff);
aRenderer.renderFaceZNeg(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
diff --git a/src/main/java/gregtech/common/render/GT_CopiedCTMBlockTexture.java b/src/main/java/gregtech/common/render/GT_CopiedCTMBlockTexture.java
index 5b9ed1bb29..c96c57398d 100644
--- a/src/main/java/gregtech/common/render/GT_CopiedCTMBlockTexture.java
+++ b/src/main/java/gregtech/common/render/GT_CopiedCTMBlockTexture.java
@@ -1,15 +1,17 @@
package gregtech.common.render;
-import gregtech.api.interfaces.IBlockContainer;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.util.GT_RenderingWorld;
-import gregtech.api.util.LightingHelper;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.util.IIcon;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.interfaces.IBlockContainer;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.util.GT_RenderingWorld;
+import gregtech.api.util.LightingHelper;
+
class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBlockContainer {
+
private final Block mBlock;
private final byte mSide, mMeta;
@@ -40,10 +42,9 @@ class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBloc
final IIcon aIcon = getIcon(ForgeDirection.EAST.ordinal(), aX, aY, aZ, aRenderer);
aRenderer.field_152631_f = true;
startDrawingQuads(aRenderer, 1.0f, 0.0f, 0.0f);
- new LightingHelper(aRenderer)
- .setupLightingXPos(aBlock, aX, aY, aZ)
- .setupColor(
- ForgeDirection.EAST.ordinal(), mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
+ new LightingHelper(aRenderer).setupLightingXPos(aBlock, aX, aY, aZ).setupColor(
+ ForgeDirection.EAST.ordinal(),
+ mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
aRenderer.renderFaceXPos(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
aRenderer.field_152631_f = false;
@@ -53,10 +54,9 @@ class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBloc
public void renderXNeg(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, -1.0f, 0.0f, 0.0f);
final IIcon aIcon = getIcon(ForgeDirection.WEST.ordinal(), aX, aY, aZ, aRenderer);
- new LightingHelper(aRenderer)
- .setupLightingXNeg(aBlock, aX, aY, aZ)
- .setupColor(
- ForgeDirection.WEST.ordinal(), mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
+ new LightingHelper(aRenderer).setupLightingXNeg(aBlock, aX, aY, aZ).setupColor(
+ ForgeDirection.WEST.ordinal(),
+ mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
aRenderer.renderFaceXNeg(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
}
@@ -65,8 +65,7 @@ class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBloc
public void renderYPos(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, 0.0f, 1.0f, 0.0f);
final IIcon aIcon = getIcon(ForgeDirection.UP.ordinal(), aX, aY, aZ, aRenderer);
- new LightingHelper(aRenderer)
- .setupLightingYPos(aBlock, aX, aY, aZ)
+ new LightingHelper(aRenderer).setupLightingYPos(aBlock, aX, aY, aZ)
.setupColor(ForgeDirection.UP.ordinal(), mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
aRenderer.renderFaceYPos(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
@@ -76,10 +75,9 @@ class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBloc
public void renderYNeg(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, 0.0f, -1.0f, 0.0f);
final IIcon aIcon = getIcon(ForgeDirection.DOWN.ordinal(), aX, aY, aZ, aRenderer);
- new LightingHelper(aRenderer)
- .setupLightingYNeg(aBlock, aX, aY, aZ)
- .setupColor(
- ForgeDirection.DOWN.ordinal(), mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
+ new LightingHelper(aRenderer).setupLightingYNeg(aBlock, aX, aY, aZ).setupColor(
+ ForgeDirection.DOWN.ordinal(),
+ mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
aRenderer.renderFaceYNeg(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
}
@@ -88,10 +86,9 @@ class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBloc
public void renderZPos(RenderBlocks aRenderer, Block aBlock, int aX, int aY, int aZ) {
startDrawingQuads(aRenderer, 0.0f, 0.0f, 1.0f);
final IIcon aIcon = getIcon(ForgeDirection.SOUTH.ordinal(), aX, aY, aZ, aRenderer);
- new LightingHelper(aRenderer)
- .setupLightingZPos(aBlock, aX, aY, aZ)
- .setupColor(
- ForgeDirection.SOUTH.ordinal(), mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
+ new LightingHelper(aRenderer).setupLightingZPos(aBlock, aX, aY, aZ).setupColor(
+ ForgeDirection.SOUTH.ordinal(),
+ mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
aRenderer.renderFaceZPos(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
}
@@ -101,10 +98,9 @@ class GT_CopiedCTMBlockTexture extends GT_TextureBase implements ITexture, IBloc
startDrawingQuads(aRenderer, 0.0f, 0.0f, -1.0f);
final IIcon aIcon = getIcon(ForgeDirection.NORTH.ordinal(), aX, aY, aZ, aRenderer);
aRenderer.field_152631_f = true;
- new LightingHelper(aRenderer)
- .setupLightingZNeg(aBlock, aX, aY, aZ)
- .setupColor(
- ForgeDirection.NORTH.ordinal(), mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
+ new LightingHelper(aRenderer).setupLightingZNeg(aBlock, aX, aY, aZ).setupColor(
+ ForgeDirection.NORTH.ordinal(),
+ mBlock.colorMultiplier(getBlockAccess(aRenderer), aX, aY, aZ));
aRenderer.renderFaceZNeg(aBlock, aX, aY, aZ, aIcon);
draw(aRenderer);
aRenderer.field_152631_f = false;
diff --git a/src/main/java/gregtech/common/render/GT_FlaskRenderer.java b/src/main/java/gregtech/common/render/GT_FlaskRenderer.java
index 18fb47cffc..3523b0f4b6 100644
--- a/src/main/java/gregtech/common/render/GT_FlaskRenderer.java
+++ b/src/main/java/gregtech/common/render/GT_FlaskRenderer.java
@@ -1,10 +1,5 @@
package gregtech.common.render;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.enums.ItemList;
-import gregtech.common.items.GT_VolumetricFlask;
-import ic2.core.util.DrawUtil;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
@@ -14,10 +9,18 @@ import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraftforge.fluids.FluidStack;
+
import org.lwjgl.opengl.GL11;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.enums.ItemList;
+import gregtech.common.items.GT_VolumetricFlask;
+import ic2.core.util.DrawUtil;
+
@SideOnly(Side.CLIENT)
public final class GT_FlaskRenderer implements IItemRenderer {
+
public GT_FlaskRenderer() {
MinecraftForgeClient.registerItemRenderer(ItemList.VOLUMETRIC_FLASK.getItem(), this);
}
diff --git a/src/main/java/gregtech/common/render/GT_FluidDisplayStackRenderer.java b/src/main/java/gregtech/common/render/GT_FluidDisplayStackRenderer.java
index caec5e1581..8862f41861 100644
--- a/src/main/java/gregtech/common/render/GT_FluidDisplayStackRenderer.java
+++ b/src/main/java/gregtech/common/render/GT_FluidDisplayStackRenderer.java
@@ -1,11 +1,5 @@
package gregtech.common.render;
-import appeng.util.ReadableNumberConverter;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Materials;
-import gregtech.common.items.GT_FluidDisplayItem;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.FontRenderer;
import net.minecraft.client.renderer.OpenGlHelper;
@@ -14,8 +8,16 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.MinecraftForgeClient;
+
import org.lwjgl.opengl.GL11;
+import appeng.util.ReadableNumberConverter;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.common.items.GT_FluidDisplayItem;
+
@SideOnly(Side.CLIENT)
public class GT_FluidDisplayStackRenderer implements IItemRenderer {
@@ -85,7 +87,11 @@ public class GT_FluidDisplayStackRenderer implements IItemRenderer {
GL11.glScalef(smallTextScale, smallTextScale, 1.0f);
fontRender.drawString(
- amountString, 0, (int) (16 / smallTextScale) - fontRender.FONT_HEIGHT + 1, 0xFFFFFF, true);
+ amountString,
+ 0,
+ (int) (16 / smallTextScale) - fontRender.FONT_HEIGHT + 1,
+ 0xFFFFFF,
+ true);
GL11.glPopMatrix();
GL11.glDisable(GL11.GL_ALPHA_TEST);
}
diff --git a/src/main/java/gregtech/common/render/GT_IconFlipped.java b/src/main/java/gregtech/common/render/GT_IconFlipped.java
index 7cd44a7e70..8258e74ffa 100644
--- a/src/main/java/gregtech/common/render/GT_IconFlipped.java
+++ b/src/main/java/gregtech/common/render/GT_IconFlipped.java
@@ -1,11 +1,13 @@
package gregtech.common.render;
+import net.minecraft.util.IIcon;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
-import net.minecraft.util.IIcon;
@SideOnly(Side.CLIENT)
public class GT_IconFlipped implements IIcon {
+
private final IIcon baseIcon;
private final boolean flipU;
private final boolean flipV;
diff --git a/src/main/java/gregtech/common/render/GT_MetaGenerated_Tool_Renderer.java b/src/main/java/gregtech/common/render/GT_MetaGenerated_Tool_Renderer.java
index 52e99f4539..1f7e72387a 100644
--- a/src/main/java/gregtech/common/render/GT_MetaGenerated_Tool_Renderer.java
+++ b/src/main/java/gregtech/common/render/GT_MetaGenerated_Tool_Renderer.java
@@ -1,10 +1,5 @@
package gregtech.common.render;
-import gregtech.api.enums.Materials;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.interfaces.IToolStats;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_Utility;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
@@ -13,9 +8,17 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.MinecraftForgeClient;
+
import org.lwjgl.opengl.GL11;
+import gregtech.api.enums.Materials;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.interfaces.IToolStats;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_Utility;
+
public class GT_MetaGenerated_Tool_Renderer implements IItemRenderer {
+
public GT_MetaGenerated_Tool_Renderer() {
for (GT_MetaGenerated_Tool tItem : GT_MetaGenerated_Tool.sInstances.values()) {
if (tItem != null) {
@@ -36,8 +39,8 @@ public class GT_MetaGenerated_Tool_Renderer implements IItemRenderer {
}
@Override
- public boolean shouldUseRenderHelper(
- IItemRenderer.ItemRenderType aType, ItemStack aStack, IItemRenderer.ItemRendererHelper aHelper) {
+ public boolean shouldUseRenderHelper(IItemRenderer.ItemRenderType aType, ItemStack aStack,
+ IItemRenderer.ItemRendererHelper aHelper) {
if (GT_Utility.isStackInvalid(aStack)) {
return false;
}
@@ -157,9 +160,8 @@ public class GT_MetaGenerated_Tool_Renderer implements IItemRenderer {
} else if (tDamage >= tMaxDamage) {
aIcon = gregtech.api.enums.Textures.ItemIcons.DURABILITY_BAR[0];
} else {
- aIcon = gregtech.api.enums.Textures.ItemIcons.DURABILITY_BAR[
- ((int) java.lang.Math.max(
- 0L, java.lang.Math.min(7L, (tMaxDamage - tDamage) * 8L / tMaxDamage)))];
+ aIcon = gregtech.api.enums.Textures.ItemIcons.DURABILITY_BAR[((int) java.lang.Math
+ .max(0L, java.lang.Math.min(7L, (tMaxDamage - tDamage) * 8L / tMaxDamage)))];
}
if (aIcon != null) {
IIcon tIcon = aIcon.getIcon();
@@ -207,10 +209,8 @@ public class GT_MetaGenerated_Tool_Renderer implements IItemRenderer {
} else if (tCharge >= tStats[0]) {
aIcon = gregtech.api.enums.Textures.ItemIcons.ENERGY_BAR[8];
} else {
- aIcon = gregtech.api.enums.Textures.ItemIcons.ENERGY_BAR[
- (7
- - (int) java.lang.Math.max(
- 0L, java.lang.Math.min(6L, (tStats[0] - tCharge) * 7L / tStats[0])))];
+ aIcon = gregtech.api.enums.Textures.ItemIcons.ENERGY_BAR[(7 - (int) java.lang.Math
+ .max(0L, java.lang.Math.min(6L, (tStats[0] - tCharge) * 7L / tStats[0])))];
}
} else {
aIcon = null;
diff --git a/src/main/java/gregtech/common/render/GT_MultiTexture.java b/src/main/java/gregtech/common/render/GT_MultiTexture.java
index df5251f784..d3cff271cb 100644
--- a/src/main/java/gregtech/common/render/GT_MultiTexture.java
+++ b/src/main/java/gregtech/common/render/GT_MultiTexture.java
@@ -1,15 +1,21 @@
package gregtech.common.render;
-import gregtech.GT_Mod;
-import gregtech.api.interfaces.ITexture;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
+import gregtech.GT_Mod;
+import gregtech.api.interfaces.ITexture;
+
/**
- * <p>Lets Multiple ITextures Render overlay over each other.<</p>
- * <p>I should have done this much earlier...</p>
+ * <p>
+ * Lets Multiple ITextures Render overlay over each other.<
+ * </p>
+ * <p>
+ * I should have done this much earlier...
+ * </p>
*/
public class GT_MultiTexture extends GT_TextureBase implements ITexture {
+
protected final ITexture[] mTextures;
public static GT_MultiTexture get(ITexture... aTextures) {
diff --git a/src/main/java/gregtech/common/render/GT_PollutionRenderer.java b/src/main/java/gregtech/common/render/GT_PollutionRenderer.java
index 99689a535d..ea8d5d1310 100644
--- a/src/main/java/gregtech/common/render/GT_PollutionRenderer.java
+++ b/src/main/java/gregtech/common/render/GT_PollutionRenderer.java
@@ -1,14 +1,5 @@
package gregtech.common.render;
-import cpw.mods.fml.common.FMLCommonHandler;
-import cpw.mods.fml.common.eventhandler.EventPriority;
-import cpw.mods.fml.common.eventhandler.SubscribeEvent;
-import cpw.mods.fml.common.gameevent.TickEvent;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.GT_Mod;
-import gregtech.common.entities.GT_EntityFXPollution;
-import gregtech.common.misc.GT_ClientPollutionMap;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.client.Minecraft;
@@ -21,10 +12,22 @@ import net.minecraft.world.ChunkCoordIntPair;
import net.minecraft.world.World;
import net.minecraftforge.client.event.EntityViewRenderEvent;
import net.minecraftforge.event.world.WorldEvent;
+
import org.lwjgl.opengl.GL11;
+import cpw.mods.fml.common.FMLCommonHandler;
+import cpw.mods.fml.common.eventhandler.EventPriority;
+import cpw.mods.fml.common.eventhandler.SubscribeEvent;
+import cpw.mods.fml.common.gameevent.TickEvent;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.GT_Mod;
+import gregtech.common.entities.GT_EntityFXPollution;
+import gregtech.common.misc.GT_ClientPollutionMap;
+
@SideOnly(Side.CLIENT)
public class GT_PollutionRenderer {
+
private static GT_ClientPollutionMap pollutionMap;
private static int playerPollution = 0;
@@ -40,11 +43,11 @@ public class GT_PollutionRenderer {
// jump from linear to exponential fog. x*FOG_MAX_AT_POLLUTION+FOG_START_AT_POLLUTION
private static final double FOG_START_EXP_RATIO = 0.02D;
- private static final float[] fogColor = {0.3f, 0.25f, 0.1f};
- private static final short[] grassColor = {230, 180, 40};
- private static final short[] leavesColor = {160, 80, 15};
- private static final short[] liquidColor = {160, 200, 10};
- private static final short[] foliageColor = {160, 80, 15};
+ private static final float[] fogColor = { 0.3f, 0.25f, 0.1f };
+ private static final short[] grassColor = { 230, 180, 40 };
+ private static final short[] leavesColor = { 160, 80, 15 };
+ private static final short[] liquidColor = { 160, 200, 10 };
+ private static final short[] foliageColor = { 160, 80, 15 };
// TODO need to soft update some blocks, grass and leaves does more often than liquid it looks like.
@@ -128,7 +131,8 @@ public class GT_PollutionRenderer {
if (!GT_Mod.gregtechproxy.mRenderPollutionFog) return;
if ((!DEBUG && Minecraft.getMinecraft().thePlayer.capabilities.isCreativeMode)
- || (fogIntensityLastTick <= 0 && fogIntensityLastTick >= FOG_START_EXP_RATIO)) return;
+ || (fogIntensityLastTick <= 0 && fogIntensityLastTick >= FOG_START_EXP_RATIO))
+ return;
if (event.fogMode == 0) {
double v = 1 - fogIntensityLastTick / FOG_START_EXP_RATIO;
@@ -146,10 +150,10 @@ public class GT_PollutionRenderer {
if (!DEBUG && Minecraft.getMinecraft().thePlayer.capabilities.isCreativeMode) return;
- if (event.entity.isPotionActive(Potion.blindness)
- || (fogIntensityLastTick < FOG_START_EXP_RATIO)
+ if (event.entity.isPotionActive(Potion.blindness) || (fogIntensityLastTick < FOG_START_EXP_RATIO)
|| event.block.getMaterial() == Material.water
- || event.block.getMaterial() == Material.lava) return;
+ || event.block.getMaterial() == Material.lava)
+ return;
GL11.glFogi(GL11.GL_FOG_MODE, GL11.GL_EXP2);
event.density = (float) Math.pow(fogIntensityLastTick - FOG_START_EXP_RATIO, .75F) / 5 + 0.01F;
@@ -185,15 +189,13 @@ public class GT_PollutionRenderer {
} else if (DEBUG) {
drawPollution("Intensity: " + (fogIntensityLastTick * 10000), 0);
drawPollution(
- "Pollution: "
- + pollutionMap.getPollution(
- Minecraft.getMinecraft().thePlayer.lastTickPosX,
- Minecraft.getMinecraft().thePlayer.lastTickPosZ),
+ "Pollution: " + pollutionMap.getPollution(
+ Minecraft.getMinecraft().thePlayer.lastTickPosX,
+ Minecraft.getMinecraft().thePlayer.lastTickPosZ),
20);
drawPollution(
- "Density: "
- + ((float) (Math.pow(fogIntensityLastTick - FOG_START_EXP_RATIO, .75F) / 5 + 0.01F)
- * 10000),
+ "Density: " + ((float) (Math.pow(fogIntensityLastTick - FOG_START_EXP_RATIO, .75F) / 5 + 0.01F)
+ * 10000),
40);
}
}
diff --git a/src/main/java/gregtech/common/render/GT_RenderUtil.java b/src/main/java/gregtech/common/render/GT_RenderUtil.java
index c4def72fd1..be0e0ac0b6 100644
--- a/src/main/java/gregtech/common/render/GT_RenderUtil.java
+++ b/src/main/java/gregtech/common/render/GT_RenderUtil.java
@@ -1,13 +1,15 @@
package gregtech.common.render;
-import gregtech.api.items.GT_MetaGenerated_Item;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
+
import org.lwjgl.opengl.GL11;
+import gregtech.api.items.GT_MetaGenerated_Item;
+
public class GT_RenderUtil {
public static void colorGTItem(ItemStack aStack) {
@@ -21,8 +23,8 @@ public class GT_RenderUtil {
}
}
- public static void renderBlockIcon(
- RenderBlocks aRenderer, Block aBlock, double aX, double aY, double aZ, IIcon aIcon, byte aSide) {
+ public static void renderBlockIcon(RenderBlocks aRenderer, Block aBlock, double aX, double aY, double aZ,
+ IIcon aIcon, byte aSide) {
switch (aSide) {
case 0:
aRenderer.renderFaceYNeg(aBlock, aX, aY, aZ, aIcon);
@@ -49,16 +51,8 @@ public class GT_RenderUtil {
renderItemIcon(icon, 0.0D, 0.0D, size, size, z, nx, ny, nz);
}
- public static void renderItemIcon(
- IIcon icon,
- double xStart,
- double yStart,
- double xEnd,
- double yEnd,
- double z,
- float nx,
- float ny,
- float nz) {
+ public static void renderItemIcon(IIcon icon, double xStart, double yStart, double xEnd, double yEnd, double z,
+ float nx, float ny, float nz) {
if (icon == null) {
return;
}
diff --git a/src/main/java/gregtech/common/render/GT_RenderedTexture.java b/src/main/java/gregtech/common/render/GT_RenderedTexture.java
index 3c12c9589d..5346a101d1 100644
--- a/src/main/java/gregtech/common/render/GT_RenderedTexture.java
+++ b/src/main/java/gregtech/common/render/GT_RenderedTexture.java
@@ -2,11 +2,22 @@ package gregtech.common.render;
import static gregtech.api.util.LightingHelper.MAX_BRIGHTNESS;
+import net.minecraft.block.Block;
+import net.minecraft.client.renderer.RenderBlocks;
+import net.minecraft.client.renderer.Tessellator;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.IIcon;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
+
import com.gtnewhorizon.structurelib.alignment.IAlignment;
import com.gtnewhorizon.structurelib.alignment.IAlignmentProvider;
import com.gtnewhorizon.structurelib.alignment.enumerable.ExtendedFacing;
import com.gtnewhorizon.structurelib.alignment.enumerable.Flip;
import com.gtnewhorizon.structurelib.alignment.enumerable.Rotation;
+
import gregtech.GT_Mod;
import gregtech.api.interfaces.IColorModulationContainer;
import gregtech.api.interfaces.IIconContainer;
@@ -14,30 +25,17 @@ import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.LightingHelper;
-import net.minecraft.block.Block;
-import net.minecraft.client.renderer.RenderBlocks;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.IIcon;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_RenderedTexture extends GT_TextureBase implements ITexture, IColorModulationContainer {
+
protected final IIconContainer mIconContainer;
private final short[] mRGBa;
private final boolean glow;
private final boolean stdOrient;
private final boolean useExtFacing;
- protected GT_RenderedTexture(
- IIconContainer aIcon,
- short[] aRGBa,
- boolean allowAlpha,
- boolean glow,
- boolean stdOrient,
- boolean extFacing) {
+ protected GT_RenderedTexture(IIconContainer aIcon, short[] aRGBa, boolean allowAlpha, boolean glow,
+ boolean stdOrient, boolean extFacing) {
if (aRGBa.length != 4) throw new IllegalArgumentException("RGBa doesn't have 4 Values @ GT_RenderedTexture");
mIconContainer = aIcon;
mRGBa = aRGBa;
@@ -214,8 +212,8 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
/**
* Renders the given texture to the bottom face of the block. Args: block, x, y, z, texture
*/
- protected void renderFaceYNeg(
- RenderBlocks aRenderer, double x, double y, double z, IIcon icon, ExtendedFacing extendedFacing) {
+ protected void renderFaceYNeg(RenderBlocks aRenderer, double x, double y, double z, IIcon icon,
+ ExtendedFacing extendedFacing) {
switch (useExtFacing ? extendedFacing.getRotation() : Rotation.NORMAL) {
case COUNTER_CLOCKWISE:
@@ -240,7 +238,9 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
z,
useExtFacing && GT_Mod.gregtechproxy.mRenderFlippedMachinesFlipped
? new GT_IconFlipped(
- icon, aFlip.isHorizontallyFlipped() ^ !stdOrient, aFlip.isVerticallyFliped())
+ icon,
+ aFlip.isHorizontallyFlipped() ^ !stdOrient,
+ aFlip.isVerticallyFliped())
: new GT_IconFlipped(icon, !stdOrient, false));
aRenderer.uvRotateBottom = 0;
}
@@ -248,8 +248,8 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
/**
* Renders the given texture to the top face of the block. Args: block, x, y, z, texture
*/
- protected void renderFaceYPos(
- RenderBlocks aRenderer, double x, double y, double z, IIcon icon, ExtendedFacing extendedFacing) {
+ protected void renderFaceYPos(RenderBlocks aRenderer, double x, double y, double z, IIcon icon,
+ ExtendedFacing extendedFacing) {
switch (useExtFacing ? extendedFacing.getRotation() : Rotation.NORMAL) {
case COUNTER_CLOCKWISE:
@@ -279,10 +279,10 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
}
/**
- * Renders the given texture to the north (z-negative) face of the block. Args: block, x, y, z, texture
+ * Renders the given texture to the north (z-negative) face of the block. Args: block, x, y, z, texture
*/
- protected void renderFaceZNeg(
- RenderBlocks aRenderer, double x, double y, double z, IIcon icon, ExtendedFacing extendedFacing) {
+ protected void renderFaceZNeg(RenderBlocks aRenderer, double x, double y, double z, IIcon icon,
+ ExtendedFacing extendedFacing) {
aRenderer.field_152631_f = true;
// **NOT A BUG**: aRenderer.uvRotateEast REALLY CONTROLS THE ROTATION OF THE NORTH SIDE
switch (useExtFacing ? extendedFacing.getRotation() : Rotation.NORMAL) {
@@ -314,10 +314,10 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
}
/**
- * Renders the given texture to the south (z-positive) face of the block. Args: block, x, y, z, texture
+ * Renders the given texture to the south (z-positive) face of the block. Args: block, x, y, z, texture
*/
- protected void renderFaceZPos(
- RenderBlocks aRenderer, double x, double y, double z, IIcon icon, ExtendedFacing extendedFacing) {
+ protected void renderFaceZPos(RenderBlocks aRenderer, double x, double y, double z, IIcon icon,
+ ExtendedFacing extendedFacing) {
// **NOT A BUG**: aRenderer.uvRotateWest REALLY CONTROLS THE ROTATION OF THE SOUTH SIDE
switch (useExtFacing ? extendedFacing.getRotation() : Rotation.NORMAL) {
case COUNTER_CLOCKWISE:
@@ -347,10 +347,10 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
}
/**
- * Renders the given texture to the west (x-negative) face of the block. Args: block, x, y, z, texture
+ * Renders the given texture to the west (x-negative) face of the block. Args: block, x, y, z, texture
*/
- protected void renderFaceXNeg(
- RenderBlocks aRenderer, double x, double y, double z, IIcon icon, ExtendedFacing extendedFacing) {
+ protected void renderFaceXNeg(RenderBlocks aRenderer, double x, double y, double z, IIcon icon,
+ ExtendedFacing extendedFacing) {
// **NOT A BUG**: aRenderer.uvRotateNorth REALLY CONTROLS THE ROTATION OF THE WEST SIDE
switch (useExtFacing ? extendedFacing.getRotation() : Rotation.NORMAL) {
case COUNTER_CLOCKWISE:
@@ -380,10 +380,10 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
}
/**
- * Renders the given texture to the east (x-positive) face of the block. Args: block, x, y, z, texture
+ * Renders the given texture to the east (x-positive) face of the block. Args: block, x, y, z, texture
*/
- protected void renderFaceXPos(
- RenderBlocks aRenderer, double x, double y, double z, IIcon icon, ExtendedFacing extendedFacing) {
+ protected void renderFaceXPos(RenderBlocks aRenderer, double x, double y, double z, IIcon icon,
+ ExtendedFacing extendedFacing) {
aRenderer.field_152631_f = true;
// **NOT A BUG**: aRenderer.uvRotateSouth REALLY CONTROLS THE ROTATION OF THE EAST SIDE
switch (useExtFacing ? extendedFacing.getRotation() : Rotation.NORMAL) {
@@ -427,8 +427,7 @@ public class GT_RenderedTexture extends GT_TextureBase implements ITexture, ICol
if (meta instanceof IAlignmentProvider) {
alignment = ((IAlignmentProvider) meta).getAlignment();
} else if (meta != null) {
- return ExtendedFacing.of(ForgeDirection.getOrientation(
- meta.getBaseMetaTileEntity().getFrontFacing()));
+ return ExtendedFacing.of(ForgeDirection.getOrientation(meta.getBaseMetaTileEntity().getFrontFacing()));
}
} else if (te instanceof IAlignmentProvider) {
alignment = ((IAlignmentProvider) te).getAlignment();
diff --git a/src/main/java/gregtech/common/render/GT_Renderer_Block.java b/src/main/java/gregtech/common/render/GT_Renderer_Block.java
index 5831c76bf4..454982b48c 100644
--- a/src/main/java/gregtech/common/render/GT_Renderer_Block.java
+++ b/src/main/java/gregtech/common/render/GT_Renderer_Block.java
@@ -21,6 +21,19 @@ import static net.minecraftforge.common.util.ForgeDirection.UP;
import static net.minecraftforge.common.util.ForgeDirection.VALID_DIRECTIONS;
import static net.minecraftforge.common.util.ForgeDirection.WEST;
+import net.minecraft.block.Block;
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.particle.EffectRenderer;
+import net.minecraft.client.particle.EntityDiggingFX;
+import net.minecraft.client.renderer.RenderBlocks;
+import net.minecraft.client.renderer.Tessellator;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.IBlockAccess;
+import net.minecraft.world.World;
+
+import org.lwjgl.opengl.GL11;
+
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
import cpw.mods.fml.client.registry.RenderingRegistry;
import cpw.mods.fml.relauncher.Side;
@@ -36,19 +49,9 @@ import gregtech.api.objects.XSTR;
import gregtech.common.blocks.GT_Block_Machines;
import gregtech.common.blocks.GT_Block_Ores_Abstract;
import gregtech.common.blocks.GT_TileEntity_Ores;
-import net.minecraft.block.Block;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.particle.EffectRenderer;
-import net.minecraft.client.particle.EntityDiggingFX;
-import net.minecraft.client.renderer.RenderBlocks;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.IBlockAccess;
-import net.minecraft.world.World;
-import org.lwjgl.opengl.GL11;
public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
+
public static final float blockMin = 0.0F;
public static final float blockMax = 1.0F;
private static final float coverThickness = blockMax / 8.0F;
@@ -63,34 +66,44 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
RenderingRegistry.registerBlockHandler(this);
}
- public static boolean renderStandardBlock(
- IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock, RenderBlocks aRenderer) {
+ public static boolean renderStandardBlock(IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock,
+ RenderBlocks aRenderer) {
final TileEntity tTileEntity = aWorld.getTileEntity(aX, aY, aZ);
if ((tTileEntity instanceof IPipeRenderedTileEntity)) {
- return renderStandardBlock(aWorld, aX, aY, aZ, aBlock, aRenderer, new ITexture[][] {
- ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) DOWN.ordinal()),
- ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) UP.ordinal()),
- ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) NORTH.ordinal()),
- ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) SOUTH.ordinal()),
- ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) WEST.ordinal()),
- ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) EAST.ordinal())
- });
+ return renderStandardBlock(
+ aWorld,
+ aX,
+ aY,
+ aZ,
+ aBlock,
+ aRenderer,
+ new ITexture[][] { ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) DOWN.ordinal()),
+ ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) UP.ordinal()),
+ ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) NORTH.ordinal()),
+ ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) SOUTH.ordinal()),
+ ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) WEST.ordinal()),
+ ((IPipeRenderedTileEntity) tTileEntity).getTextureCovered((byte) EAST.ordinal()) });
}
if ((tTileEntity instanceof ITexturedTileEntity)) {
- return renderStandardBlock(aWorld, aX, aY, aZ, aBlock, aRenderer, new ITexture[][] {
- ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) DOWN.ordinal()),
- ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) UP.ordinal()),
- ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) NORTH.ordinal()),
- ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) SOUTH.ordinal()),
- ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) WEST.ordinal()),
- ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) EAST.ordinal())
- });
+ return renderStandardBlock(
+ aWorld,
+ aX,
+ aY,
+ aZ,
+ aBlock,
+ aRenderer,
+ new ITexture[][] { ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) DOWN.ordinal()),
+ ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) UP.ordinal()),
+ ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) NORTH.ordinal()),
+ ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) SOUTH.ordinal()),
+ ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) WEST.ordinal()),
+ ((ITexturedTileEntity) tTileEntity).getTexture(aBlock, (byte) EAST.ordinal()) });
}
return false;
}
- public static boolean renderStandardBlock(
- IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock, RenderBlocks aRenderer, ITexture[][] aTextures) {
+ public static boolean renderStandardBlock(IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock,
+ RenderBlocks aRenderer, ITexture[][] aTextures) {
aBlock.setBlockBounds(blockMin, blockMin, blockMin, blockMax, blockMax, blockMax);
aRenderer.setRenderBoundsFromBlock(aBlock);
@@ -103,14 +116,8 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
return true;
}
- public static boolean renderPipeBlock(
- IBlockAccess aWorld,
- int aX,
- int aY,
- int aZ,
- Block aBlock,
- IPipeRenderedTileEntity aTileEntity,
- RenderBlocks aRenderer) {
+ public static boolean renderPipeBlock(IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock,
+ IPipeRenderedTileEntity aTileEntity, RenderBlocks aRenderer) {
final byte aConnections = aTileEntity.getConnections();
if ((aConnections & (HAS_FRESHFOAM | HAS_HARDENEDFOAM)) != 0) {
return renderStandardBlock(aWorld, aX, aY, aZ, aBlock, aRenderer);
@@ -471,8 +478,8 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
@SideOnly(Side.CLIENT)
- public static void addHitEffects(
- EffectRenderer effectRenderer, Block block, World world, int x, int y, int z, int side) {
+ public static void addHitEffects(EffectRenderer effectRenderer, Block block, World world, int x, int y, int z,
+ int side) {
double rX = x + XSTR.XSTR_INSTANCE.nextDouble() * 0.8 + 0.1;
double rY = y + XSTR.XSTR_INSTANCE.nextDouble() * 0.8 + 0.1;
double rZ = z + XSTR.XSTR_INSTANCE.nextDouble() * 0.8 + 0.1;
@@ -489,11 +496,18 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
} else if (side == 5) {
rX = x + 1.1;
}
- effectRenderer.addEffect((new EntityDiggingFX(
- world, rX, rY, rZ, 0.0, 0.0, 0.0, block, block.getDamageValue(world, x, y, z), side))
- .applyColourMultiplier(x, y, z)
- .multiplyVelocity(0.2F)
- .multipleParticleScaleBy(0.6F));
+ effectRenderer.addEffect(
+ (new EntityDiggingFX(
+ world,
+ rX,
+ rY,
+ rZ,
+ 0.0,
+ 0.0,
+ 0.0,
+ block,
+ block.getDamageValue(world, x, y, z),
+ side)).applyColourMultiplier(x, y, z).multiplyVelocity(0.2F).multipleParticleScaleBy(0.6F));
}
@SideOnly(Side.CLIENT)
@@ -504,7 +518,8 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
final double bX = x + (iX + 0.5) / 4.0;
final double bY = y + (iY + 0.5) / 4.0;
final double bZ = z + (iZ + 0.5) / 4.0;
- effectRenderer.addEffect((new EntityDiggingFX(
+ effectRenderer.addEffect(
+ (new EntityDiggingFX(
world,
bX,
bY,
@@ -513,8 +528,7 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
bY - y - 0.5,
bZ - z - 0.5,
block,
- block.getDamageValue(world, x, y, z)))
- .applyColourMultiplier(x, y, z));
+ block.getDamageValue(world, x, y, z))).applyColourMultiplier(x, y, z));
}
}
}
@@ -610,24 +624,65 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
aBlock.setBlockBoundsForItemRender();
aRenderer.setRenderBoundsFromBlock(aBlock);
renderNegativeYFacing(
- null, aRenderer, aBlock, 0, 0, 0, tTileEntity.getTexture(aBlock, (byte) DOWN.ordinal()), true);
+ null,
+ aRenderer,
+ aBlock,
+ 0,
+ 0,
+ 0,
+ tTileEntity.getTexture(aBlock, (byte) DOWN.ordinal()),
+ true);
renderPositiveYFacing(
- null, aRenderer, aBlock, 0, 0, 0, tTileEntity.getTexture(aBlock, (byte) UP.ordinal()), true);
+ null,
+ aRenderer,
+ aBlock,
+ 0,
+ 0,
+ 0,
+ tTileEntity.getTexture(aBlock, (byte) UP.ordinal()),
+ true);
renderNegativeZFacing(
- null, aRenderer, aBlock, 0, 0, 0, tTileEntity.getTexture(aBlock, (byte) NORTH.ordinal()), true);
+ null,
+ aRenderer,
+ aBlock,
+ 0,
+ 0,
+ 0,
+ tTileEntity.getTexture(aBlock, (byte) NORTH.ordinal()),
+ true);
renderPositiveZFacing(
- null, aRenderer, aBlock, 0, 0, 0, tTileEntity.getTexture(aBlock, (byte) SOUTH.ordinal()), true);
+ null,
+ aRenderer,
+ aBlock,
+ 0,
+ 0,
+ 0,
+ tTileEntity.getTexture(aBlock, (byte) SOUTH.ordinal()),
+ true);
renderNegativeXFacing(
- null, aRenderer, aBlock, 0, 0, 0, tTileEntity.getTexture(aBlock, (byte) WEST.ordinal()), true);
+ null,
+ aRenderer,
+ aBlock,
+ 0,
+ 0,
+ 0,
+ tTileEntity.getTexture(aBlock, (byte) WEST.ordinal()),
+ true);
renderPositiveXFacing(
- null, aRenderer, aBlock, 0, 0, 0, tTileEntity.getTexture(aBlock, (byte) EAST.ordinal()), true);
- } else if (aMeta > 0
- && (aMeta < GregTech_API.METATILEENTITIES.length)
+ null,
+ aRenderer,
+ aBlock,
+ 0,
+ 0,
+ 0,
+ tTileEntity.getTexture(aBlock, (byte) EAST.ordinal()),
+ true);
+ } else if (aMeta > 0 && (aMeta < GregTech_API.METATILEENTITIES.length)
&& aBlock instanceof GT_Block_Machines
&& (GregTech_API.METATILEENTITIES[aMeta] != null)
&& (!GregTech_API.METATILEENTITIES[aMeta].renderInInventory(aBlock, aMeta, aRenderer))) {
- renderNormalInventoryMetaTileEntity(aBlock, aMeta, aRenderer);
- }
+ renderNormalInventoryMetaTileEntity(aBlock, aMeta, aRenderer);
+ }
aBlock.setBlockBounds(blockMin, blockMin, blockMin, blockMax, blockMax, blockMax);
}
@@ -756,7 +811,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
0,
0,
tMetaTileEntity.getTexture(
- iGregTechTileEntity, (byte) DOWN.ordinal(), (byte) WEST.ordinal(), (byte) -1, true, false),
+ iGregTechTileEntity,
+ (byte) DOWN.ordinal(),
+ (byte) WEST.ordinal(),
+ (byte) -1,
+ true,
+ false),
true);
renderPositiveYFacing(
null,
@@ -766,7 +826,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
0,
0,
tMetaTileEntity.getTexture(
- iGregTechTileEntity, (byte) UP.ordinal(), (byte) WEST.ordinal(), (byte) -1, true, false),
+ iGregTechTileEntity,
+ (byte) UP.ordinal(),
+ (byte) WEST.ordinal(),
+ (byte) -1,
+ true,
+ false),
true);
renderNegativeZFacing(
null,
@@ -776,7 +841,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
0,
0,
tMetaTileEntity.getTexture(
- iGregTechTileEntity, (byte) NORTH.ordinal(), (byte) WEST.ordinal(), (byte) -1, true, false),
+ iGregTechTileEntity,
+ (byte) NORTH.ordinal(),
+ (byte) WEST.ordinal(),
+ (byte) -1,
+ true,
+ false),
true);
renderPositiveZFacing(
null,
@@ -786,7 +856,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
0,
0,
tMetaTileEntity.getTexture(
- iGregTechTileEntity, (byte) SOUTH.ordinal(), (byte) WEST.ordinal(), (byte) -1, true, false),
+ iGregTechTileEntity,
+ (byte) SOUTH.ordinal(),
+ (byte) WEST.ordinal(),
+ (byte) -1,
+ true,
+ false),
true);
renderNegativeXFacing(
null,
@@ -796,7 +871,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
0,
0,
tMetaTileEntity.getTexture(
- iGregTechTileEntity, (byte) WEST.ordinal(), (byte) WEST.ordinal(), (byte) -1, true, false),
+ iGregTechTileEntity,
+ (byte) WEST.ordinal(),
+ (byte) WEST.ordinal(),
+ (byte) -1,
+ true,
+ false),
true);
renderPositiveXFacing(
null,
@@ -806,24 +886,22 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
0,
0,
tMetaTileEntity.getTexture(
- iGregTechTileEntity, (byte) EAST.ordinal(), (byte) WEST.ordinal(), (byte) -1, true, false),
+ iGregTechTileEntity,
+ (byte) EAST.ordinal(),
+ (byte) WEST.ordinal(),
+ (byte) -1,
+ true,
+ false),
true);
}
}
- public static void renderNegativeYFacing(
- IBlockAccess aWorld,
- RenderBlocks aRenderer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- ITexture[] aIcon,
- boolean aFullBlock) {
+ public static void renderNegativeYFacing(IBlockAccess aWorld, RenderBlocks aRenderer, Block aBlock, int aX, int aY,
+ int aZ, ITexture[] aIcon, boolean aFullBlock) {
if (aWorld != null) {
if ((aFullBlock) && (!aBlock.shouldSideBeRendered(aWorld, aX, aY - 1, aZ, 0))) return;
- Tessellator.instance.setBrightness(
- aBlock.getMixedBrightnessForBlock(aWorld, aX, aFullBlock ? aY - 1 : aY, aZ));
+ Tessellator.instance
+ .setBrightness(aBlock.getMixedBrightnessForBlock(aWorld, aX, aFullBlock ? aY - 1 : aY, aZ));
}
if (aIcon == null) return;
for (ITexture iTexture : aIcon) {
@@ -833,19 +911,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
}
- public static void renderPositiveYFacing(
- IBlockAccess aWorld,
- RenderBlocks aRenderer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- ITexture[] aIcon,
- boolean aFullBlock) {
+ public static void renderPositiveYFacing(IBlockAccess aWorld, RenderBlocks aRenderer, Block aBlock, int aX, int aY,
+ int aZ, ITexture[] aIcon, boolean aFullBlock) {
if (aWorld != null) {
if ((aFullBlock) && (!aBlock.shouldSideBeRendered(aWorld, aX, aY + 1, aZ, 1))) return;
- Tessellator.instance.setBrightness(
- aBlock.getMixedBrightnessForBlock(aWorld, aX, aFullBlock ? aY + 1 : aY, aZ));
+ Tessellator.instance
+ .setBrightness(aBlock.getMixedBrightnessForBlock(aWorld, aX, aFullBlock ? aY + 1 : aY, aZ));
}
if (aIcon == null) return;
for (ITexture iTexture : aIcon) {
@@ -855,19 +926,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
}
- public static void renderNegativeZFacing(
- IBlockAccess aWorld,
- RenderBlocks aRenderer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- ITexture[] aIcon,
- boolean aFullBlock) {
+ public static void renderNegativeZFacing(IBlockAccess aWorld, RenderBlocks aRenderer, Block aBlock, int aX, int aY,
+ int aZ, ITexture[] aIcon, boolean aFullBlock) {
if (aWorld != null) {
if ((aFullBlock) && (!aBlock.shouldSideBeRendered(aWorld, aX, aY, aZ - 1, 2))) return;
- Tessellator.instance.setBrightness(
- aBlock.getMixedBrightnessForBlock(aWorld, aX, aY, aFullBlock ? aZ - 1 : aZ));
+ Tessellator.instance
+ .setBrightness(aBlock.getMixedBrightnessForBlock(aWorld, aX, aY, aFullBlock ? aZ - 1 : aZ));
}
if (aIcon == null) return;
for (ITexture iTexture : aIcon) {
@@ -877,19 +941,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
}
- public static void renderPositiveZFacing(
- IBlockAccess aWorld,
- RenderBlocks aRenderer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- ITexture[] aIcon,
- boolean aFullBlock) {
+ public static void renderPositiveZFacing(IBlockAccess aWorld, RenderBlocks aRenderer, Block aBlock, int aX, int aY,
+ int aZ, ITexture[] aIcon, boolean aFullBlock) {
if (aWorld != null) {
if ((aFullBlock) && (!aBlock.shouldSideBeRendered(aWorld, aX, aY, aZ + 1, 3))) return;
- Tessellator.instance.setBrightness(
- aBlock.getMixedBrightnessForBlock(aWorld, aX, aY, aFullBlock ? aZ + 1 : aZ));
+ Tessellator.instance
+ .setBrightness(aBlock.getMixedBrightnessForBlock(aWorld, aX, aY, aFullBlock ? aZ + 1 : aZ));
}
if (aIcon == null) return;
for (ITexture iTexture : aIcon) {
@@ -899,19 +956,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
}
- public static void renderNegativeXFacing(
- IBlockAccess aWorld,
- RenderBlocks aRenderer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- ITexture[] aIcon,
- boolean aFullBlock) {
+ public static void renderNegativeXFacing(IBlockAccess aWorld, RenderBlocks aRenderer, Block aBlock, int aX, int aY,
+ int aZ, ITexture[] aIcon, boolean aFullBlock) {
if (aWorld != null) {
if ((aFullBlock) && (!aBlock.shouldSideBeRendered(aWorld, aX - 1, aY, aZ, 4))) return;
- Tessellator.instance.setBrightness(
- aBlock.getMixedBrightnessForBlock(aWorld, aFullBlock ? aX - 1 : aX, aY, aZ));
+ Tessellator.instance
+ .setBrightness(aBlock.getMixedBrightnessForBlock(aWorld, aFullBlock ? aX - 1 : aX, aY, aZ));
}
if (aIcon == null) return;
for (ITexture iTexture : aIcon) {
@@ -921,19 +971,12 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
}
- public static void renderPositiveXFacing(
- IBlockAccess aWorld,
- RenderBlocks aRenderer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- ITexture[] aIcon,
- boolean aFullBlock) {
+ public static void renderPositiveXFacing(IBlockAccess aWorld, RenderBlocks aRenderer, Block aBlock, int aX, int aY,
+ int aZ, ITexture[] aIcon, boolean aFullBlock) {
if (aWorld != null) {
if ((aFullBlock) && (!aBlock.shouldSideBeRendered(aWorld, aX + 1, aY, aZ, 5))) return;
- Tessellator.instance.setBrightness(
- aBlock.getMixedBrightnessForBlock(aWorld, aFullBlock ? aX + 1 : aX, aY, aZ));
+ Tessellator.instance
+ .setBrightness(aBlock.getMixedBrightnessForBlock(aWorld, aFullBlock ? aX + 1 : aX, aY, aZ));
}
if (aIcon == null) return;
for (ITexture iTexture : aIcon) {
@@ -944,8 +987,8 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
}
@Override
- public boolean renderWorldBlock(
- IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock, int aModelID, RenderBlocks aRenderer) {
+ public boolean renderWorldBlock(IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock, int aModelID,
+ RenderBlocks aRenderer) {
aRenderer.enableAO = Minecraft.isAmbientOcclusionEnabled() && GT_Mod.gregtechproxy.mRenderTileAmbientOcclusion;
aRenderer.useInventoryTint = false;
if (aBlock instanceof IRenderedBlock) {
@@ -959,13 +1002,11 @@ public class GT_Renderer_Block implements ISimpleBlockRenderingHandler {
} else {
final boolean[] tSides = new boolean[6];
if (tRenderer instanceof IRenderedBlockSideCheck) {
- for (byte tSide : ALL_VALID_SIDES)
- rReturn |= (tSides[tSide] =
- ((IRenderedBlockSideCheck) tRenderer).renderFullBlockSide(aBlock, aRenderer, tSide));
+ for (byte tSide : ALL_VALID_SIDES) rReturn |= (tSides[tSide] = ((IRenderedBlockSideCheck) tRenderer)
+ .renderFullBlockSide(aBlock, aRenderer, tSide));
} else {
- for (byte tSide : ALL_VALID_SIDES)
- rReturn |= (tSides[tSide] = aBlock.shouldSideBeRendered(
- aWorld, aX + OFFX[tSide], aY + OFFY[tSide], aZ + OFFZ[tSide], tSide));
+ for (byte tSide : ALL_VALID_SIDES) rReturn |= (tSides[tSide] = aBlock
+ .shouldSideBeRendered(aWorld, aX + OFFX[tSide], aY + OFFY[tSide], aZ + OFFZ[tSide], tSide));
}
for (int i = 0, j = tRenderer.getRenderPasses(aBlock); i < j; i++) {
if (tRenderer.usesRenderPass(i)) {
diff --git a/src/main/java/gregtech/common/render/GT_Renderer_Entity_Arrow.java b/src/main/java/gregtech/common/render/GT_Renderer_Entity_Arrow.java
index 7feb8ce1b8..028573fdaf 100644
--- a/src/main/java/gregtech/common/render/GT_Renderer_Entity_Arrow.java
+++ b/src/main/java/gregtech/common/render/GT_Renderer_Entity_Arrow.java
@@ -1,11 +1,13 @@
package gregtech.common.render;
-import cpw.mods.fml.client.registry.RenderingRegistry;
import net.minecraft.client.renderer.entity.RenderArrow;
import net.minecraft.entity.Entity;
import net.minecraft.util.ResourceLocation;
+import cpw.mods.fml.client.registry.RenderingRegistry;
+
public class GT_Renderer_Entity_Arrow extends RenderArrow {
+
private final ResourceLocation mTexture;
public GT_Renderer_Entity_Arrow(Class aArrowClass, String aTextureName) {
diff --git a/src/main/java/gregtech/common/render/GT_SidedTexture.java b/src/main/java/gregtech/common/render/GT_SidedTexture.java
index 4fbc28374a..912e339208 100644
--- a/src/main/java/gregtech/common/render/GT_SidedTexture.java
+++ b/src/main/java/gregtech/common/render/GT_SidedTexture.java
@@ -1,40 +1,30 @@
package gregtech.common.render;
+import net.minecraft.block.Block;
+import net.minecraft.client.renderer.RenderBlocks;
+
import gregtech.api.interfaces.IColorModulationContainer;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.interfaces.ITexture;
import gregtech.api.render.TextureFactory;
-import net.minecraft.block.Block;
-import net.minecraft.client.renderer.RenderBlocks;
public class GT_SidedTexture extends GT_TextureBase implements ITexture, IColorModulationContainer {
+
protected final ITexture[] mTextures;
/**
* DO NOT MANIPULATE THE VALUES INSIDE THIS ARRAY!!!
* <p/>
- * Just set this variable to another different Array instead.
- * Otherwise some colored things will get Problems.
+ * Just set this variable to another different Array instead. Otherwise some colored things will get Problems.
*/
private final short[] mRGBa;
- protected GT_SidedTexture(
- IIconContainer aIcon0,
- IIconContainer aIcon1,
- IIconContainer aIcon2,
- IIconContainer aIcon3,
- IIconContainer aIcon4,
- IIconContainer aIcon5,
- short[] aRGBa,
- boolean aAllowAlpha) {
+ protected GT_SidedTexture(IIconContainer aIcon0, IIconContainer aIcon1, IIconContainer aIcon2,
+ IIconContainer aIcon3, IIconContainer aIcon4, IIconContainer aIcon5, short[] aRGBa, boolean aAllowAlpha) {
if (aRGBa.length != 4) throw new IllegalArgumentException("RGBa doesn't have 4 Values @ GT_RenderedTexture");
- mTextures = new ITexture[] {
- TextureFactory.of(aIcon0, aRGBa, aAllowAlpha),
- TextureFactory.of(aIcon1, aRGBa, aAllowAlpha),
- TextureFactory.of(aIcon2, aRGBa, aAllowAlpha),
- TextureFactory.of(aIcon3, aRGBa, aAllowAlpha),
- TextureFactory.of(aIcon4, aRGBa, aAllowAlpha),
- TextureFactory.of(aIcon5, aRGBa, aAllowAlpha)
- };
+ mTextures = new ITexture[] { TextureFactory.of(aIcon0, aRGBa, aAllowAlpha),
+ TextureFactory.of(aIcon1, aRGBa, aAllowAlpha), TextureFactory.of(aIcon2, aRGBa, aAllowAlpha),
+ TextureFactory.of(aIcon3, aRGBa, aAllowAlpha), TextureFactory.of(aIcon4, aRGBa, aAllowAlpha),
+ TextureFactory.of(aIcon5, aRGBa, aAllowAlpha) };
mRGBa = aRGBa;
}
diff --git a/src/main/java/gregtech/common/render/GT_TextureBase.java b/src/main/java/gregtech/common/render/GT_TextureBase.java
index bb39410a8e..20188e2e01 100644
--- a/src/main/java/gregtech/common/render/GT_TextureBase.java
+++ b/src/main/java/gregtech/common/render/GT_TextureBase.java
@@ -1,11 +1,13 @@
package gregtech.common.render;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.util.GT_UtilityClient;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.client.renderer.Tessellator;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.util.GT_UtilityClient;
+
public abstract class GT_TextureBase implements ITexture {
+
protected boolean isDrawing = false;
@Override
diff --git a/src/main/java/gregtech/common/render/GT_TextureBuilder.java b/src/main/java/gregtech/common/render/GT_TextureBuilder.java
index 0971933add..d3941bea24 100644
--- a/src/main/java/gregtech/common/render/GT_TextureBuilder.java
+++ b/src/main/java/gregtech/common/render/GT_TextureBuilder.java
@@ -1,19 +1,22 @@
package gregtech.common.render;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import net.minecraft.block.Block;
+import net.minecraftforge.common.util.ForgeDirection;
+
import gregtech.GT_Mod;
import gregtech.api.enums.Dyes;
import gregtech.api.enums.GT_Values;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.ITextureBuilder;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-import net.minecraft.block.Block;
-import net.minecraftforge.common.util.ForgeDirection;
-@SuppressWarnings({"unused", "ClassWithTooManyFields"})
+@SuppressWarnings({ "unused", "ClassWithTooManyFields" })
public class GT_TextureBuilder implements ITextureBuilder {
+
private final List<IIconContainer> iconContainerList;
private final List<ITexture> textureLayers;
private Block fromBlock;
@@ -134,8 +137,8 @@ public class GT_TextureBuilder implements ITextureBuilder {
}
private boolean isCTMBlock(Block fromBlock, int fromMeta) {
- return GT_Mod.gregtechproxy.mCTMBlockCache.computeIfAbsent(
- fromBlock, (byte) fromMeta, GT_TextureBuilder::apply);
+ return GT_Mod.gregtechproxy.mCTMBlockCache
+ .computeIfAbsent(fromBlock, (byte) fromMeta, GT_TextureBuilder::apply);
}
private static Boolean apply(Block b, Byte m) {
diff --git a/src/main/java/gregtech/common/render/IRenderedBlock.java b/src/main/java/gregtech/common/render/IRenderedBlock.java
index a29ea6b6f9..0f3a472e53 100644
--- a/src/main/java/gregtech/common/render/IRenderedBlock.java
+++ b/src/main/java/gregtech/common/render/IRenderedBlock.java
@@ -1,15 +1,17 @@
package gregtech.common.render;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.ITexture;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.item.ItemStack;
import net.minecraft.world.IBlockAccess;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.ITexture;
+
public interface IRenderedBlock {
+
/** @return the Textures to be rendered */
@SideOnly(Side.CLIENT)
ITexture[] getTexture(Block aBlock, byte aSide, int aRenderPass, boolean[] aShouldSideBeRendered);
@@ -50,6 +52,7 @@ public interface IRenderedBlock {
IRenderedBlock passRenderingToObject(IBlockAccess aWorld, int aX, int aY, int aZ);
class ErrorRenderer implements IRenderedBlockSideCheck, IRenderedBlock {
+
public static final ErrorRenderer INSTANCE = new ErrorRenderer();
public ITexture[] mErrorTexture = Textures.BlockIcons.ERROR_RENDERING;
diff --git a/src/main/java/gregtech/common/render/IRenderedBlockSideCheck.java b/src/main/java/gregtech/common/render/IRenderedBlockSideCheck.java
index ef0c469f04..1d109216de 100644
--- a/src/main/java/gregtech/common/render/IRenderedBlockSideCheck.java
+++ b/src/main/java/gregtech/common/render/IRenderedBlockSideCheck.java
@@ -1,11 +1,13 @@
package gregtech.common.render;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+
public interface IRenderedBlockSideCheck {
+
/** returning false stops all the other Rendering from happening on that Side. */
@SideOnly(Side.CLIENT)
boolean renderFullBlockSide(Block aBlock, RenderBlocks aRenderer, byte aSide);
diff --git a/src/main/java/gregtech/common/render/items/CosmicNeutroniumRenderer.java b/src/main/java/gregtech/common/render/items/CosmicNeutroniumRenderer.java
index 5a9cda6559..5a67abf85a 100644
--- a/src/main/java/gregtech/common/render/items/CosmicNeutroniumRenderer.java
+++ b/src/main/java/gregtech/common/render/items/CosmicNeutroniumRenderer.java
@@ -2,18 +2,21 @@ package gregtech.common.render.items;
import static gregtech.common.render.GT_RenderUtil.colorGTItem;
-import com.gtnewhorizons.modularui.api.math.Pos2d;
-import gregtech.api.enums.Textures;
-import gregtech.common.render.GT_RenderUtil;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.client.renderer.entity.RenderItem;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
+
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
+import com.gtnewhorizons.modularui.api.math.Pos2d;
+
+import gregtech.api.enums.Textures;
+import gregtech.common.render.GT_RenderUtil;
+
public class CosmicNeutroniumRenderer extends GT_GeneratedMaterial_Renderer {
// spotless:off
@@ -101,7 +104,7 @@ public class CosmicNeutroniumRenderer extends GT_GeneratedMaterial_Renderer {
GL11.glPopMatrix();
}
- // GL11.glEnable(GL11.GL_ALPHA_TEST);
+ // GL11.glEnable(GL11.GL_ALPHA_TEST);
GL11.glEnable(GL12.GL_RESCALE_NORMAL);
GL11.glEnable(GL11.GL_DEPTH_TEST);
diff --git a/src/main/java/gregtech/common/render/items/GT_GeneratedItem_Renderer.java b/src/main/java/gregtech/common/render/items/GT_GeneratedItem_Renderer.java
index 26115592f3..7559580f96 100644
--- a/src/main/java/gregtech/common/render/items/GT_GeneratedItem_Renderer.java
+++ b/src/main/java/gregtech/common/render/items/GT_GeneratedItem_Renderer.java
@@ -3,13 +3,8 @@ package gregtech.common.render.items;
import static gregtech.api.enums.ItemList.*;
import static gregtech.api.enums.ItemList.Large_Fluid_Cell_Chrome;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Textures;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.render.GT_RenderUtil;
-import gregtech.loaders.ExtraIcons;
import javax.annotation.Nullable;
+
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
@@ -18,14 +13,21 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.fluids.FluidStack;
+
import org.lwjgl.opengl.GL11;
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Textures;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.render.GT_RenderUtil;
+import gregtech.loaders.ExtraIcons;
+
public class GT_GeneratedItem_Renderer implements IItemRenderer {
@Override
public boolean handleRenderType(ItemStack item, ItemRenderType type) {
- return type == ItemRenderType.EQUIPPED
- || type == ItemRenderType.EQUIPPED_FIRST_PERSON
+ return type == ItemRenderType.EQUIPPED || type == ItemRenderType.EQUIPPED_FIRST_PERSON
|| type == ItemRenderType.INVENTORY
|| type == ItemRenderType.ENTITY;
}
@@ -56,8 +58,8 @@ public class GT_GeneratedItem_Renderer implements IItemRenderer {
if (tCharge >= tStats[0]) {
tIcon = aItem.mIconList[(aMetaData - aItem.mOffset)][8];
} else {
- tIcon = aItem.mIconList[(aMetaData - aItem.mOffset)][
- (7 - (int) Math.max(0L, Math.min(5L, (tStats[0] - tCharge) * 6L / tStats[0])))];
+ tIcon = aItem.mIconList[(aMetaData - aItem.mOffset)][(7
+ - (int) Math.max(0L, Math.min(5L, (tStats[0] - tCharge) * 6L / tStats[0])))];
}
}
} else {
@@ -107,8 +109,8 @@ public class GT_GeneratedItem_Renderer implements IItemRenderer {
return null;
}
- private static void renderLargeFluidCellExtraParts(
- IItemRenderer.ItemRenderType type, ItemList item, ItemStack stack) {
+ private static void renderLargeFluidCellExtraParts(IItemRenderer.ItemRenderType type, ItemList item,
+ ItemStack stack) {
IIcon inner;
if (item == Large_Fluid_Cell_Steel) inner = ExtraIcons.steelLargeCellInner;
diff --git a/src/main/java/gregtech/common/render/items/GT_GeneratedMaterial_Renderer.java b/src/main/java/gregtech/common/render/items/GT_GeneratedMaterial_Renderer.java
index b9419caa28..46d6a13469 100644
--- a/src/main/java/gregtech/common/render/items/GT_GeneratedMaterial_Renderer.java
+++ b/src/main/java/gregtech/common/render/items/GT_GeneratedMaterial_Renderer.java
@@ -1,10 +1,5 @@
package gregtech.common.render.items;
-import codechicken.lib.render.TextureUtils;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.render.GT_RenderUtil;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.item.ItemStack;
@@ -12,14 +7,20 @@ import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
+
import org.lwjgl.opengl.GL11;
+import codechicken.lib.render.TextureUtils;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.render.GT_RenderUtil;
+
public class GT_GeneratedMaterial_Renderer implements IItemRenderer {
@Override
public boolean handleRenderType(ItemStack item, ItemRenderType type) {
- return type == ItemRenderType.EQUIPPED
- || type == ItemRenderType.EQUIPPED_FIRST_PERSON
+ return type == ItemRenderType.EQUIPPED || type == ItemRenderType.EQUIPPED_FIRST_PERSON
|| type == ItemRenderType.INVENTORY
|| type == ItemRenderType.ENTITY;
}
@@ -30,13 +31,12 @@ public class GT_GeneratedMaterial_Renderer implements IItemRenderer {
}
/**
- * Handle special fluid display rendering. Return false if does not need such kind of handling.
- * Note: annotations should not be rendered here. Only render the fluid
- * texture.
- * Parameters are values passed from {@link IItemRenderer#renderItem(ItemRenderType, ItemStack, Object...)}
- * verbatim. Do not modify the argument.
+ * Handle special fluid display rendering. Return false if does not need such kind of handling. Note: annotations
+ * should not be rendered here. Only render the fluid texture. Parameters are values passed from
+ * {@link IItemRenderer#renderItem(ItemRenderType, ItemStack, Object...)} verbatim. Do not modify the argument.
*
* While this is called, BLEND and ALPHA_TEST is on. It is expected that these remain enabled while exit.
+ *
* @return true if did special fluid display rendering. false otherwise.
*/
public boolean renderFluidDisplayItem(ItemRenderType type, ItemStack aStack, Object... data) {
diff --git a/src/main/java/gregtech/common/render/items/GT_MetaGenerated_Item_Renderer.java b/src/main/java/gregtech/common/render/items/GT_MetaGenerated_Item_Renderer.java
index 0133f21c8b..49b5521485 100644
--- a/src/main/java/gregtech/common/render/items/GT_MetaGenerated_Item_Renderer.java
+++ b/src/main/java/gregtech/common/render/items/GT_MetaGenerated_Item_Renderer.java
@@ -2,20 +2,22 @@ package gregtech.common.render.items;
import static gregtech.api.util.GT_OreDictUnificator.getAssociation;
-import gregtech.api.enums.Materials;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.api.util.GT_Utility;
import java.util.Objects;
+
import net.minecraft.client.renderer.entity.RenderItem;
import net.minecraft.item.ItemStack;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.MinecraftForgeClient;
+
import org.lwjgl.opengl.GL11;
+import gregtech.api.enums.Materials;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.api.util.GT_Utility;
+
public class GT_MetaGenerated_Item_Renderer implements IItemRenderer {
- private final IItemRenderer mItemRenderer = new GT_GeneratedItem_Renderer();
- ;
+ private final IItemRenderer mItemRenderer = new GT_GeneratedItem_Renderer();;
private final IItemRenderer mMaterialRenderer = new GT_GeneratedMaterial_Renderer();
public GT_MetaGenerated_Item_Renderer() {
diff --git a/src/main/java/gregtech/common/render/items/GaiaSpiritRenderer.java b/src/main/java/gregtech/common/render/items/GaiaSpiritRenderer.java
index 12510dce30..25ab13bd25 100644
--- a/src/main/java/gregtech/common/render/items/GaiaSpiritRenderer.java
+++ b/src/main/java/gregtech/common/render/items/GaiaSpiritRenderer.java
@@ -1,15 +1,19 @@
package gregtech.common.render.items;
-import gregtech.GT_Mod;
-import gregtech.common.render.GT_RenderUtil;
import java.awt.*;
+
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
+
import org.lwjgl.opengl.GL11;
+import gregtech.GT_Mod;
+import gregtech.common.render.GT_RenderUtil;
+
public class GaiaSpiritRenderer extends GT_GeneratedMaterial_Renderer {
+
@Override
public void renderRegularItem(ItemRenderType type, ItemStack aStack, IIcon icon, boolean shouldModulateColor) {
long animationTicks = GT_Mod.gregtechproxy.getAnimationTicks();
diff --git a/src/main/java/gregtech/common/render/items/InfinityRenderer.java b/src/main/java/gregtech/common/render/items/InfinityRenderer.java
index 4f1695bec0..5733501d95 100644
--- a/src/main/java/gregtech/common/render/items/InfinityRenderer.java
+++ b/src/main/java/gregtech/common/render/items/InfinityRenderer.java
@@ -1,12 +1,7 @@
package gregtech.common.render.items;
-import codechicken.lib.render.TextureUtils;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.render.GT_RenderUtil;
import java.util.Random;
+
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.RenderHelper;
@@ -16,10 +11,19 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.fluids.FluidStack;
+
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
+import codechicken.lib.render.TextureUtils;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.render.GT_RenderUtil;
+
public class InfinityRenderer extends GT_GeneratedMaterial_Renderer {
+
public Random rand = new Random();
@Override
diff --git a/src/main/java/gregtech/common/render/items/TranscendentMetalRenderer.java b/src/main/java/gregtech/common/render/items/TranscendentMetalRenderer.java
index 0865101826..a7ad2cd19c 100644
--- a/src/main/java/gregtech/common/render/items/TranscendentMetalRenderer.java
+++ b/src/main/java/gregtech/common/render/items/TranscendentMetalRenderer.java
@@ -1,44 +1,35 @@
package gregtech.common.render.items;
-import gregtech.GT_Mod;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.common.render.GT_RenderUtil;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraftforge.client.IItemRenderer;
+
import org.lwjgl.opengl.GL11;
+import gregtech.GT_Mod;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.common.render.GT_RenderUtil;
+
public class TranscendentMetalRenderer extends GT_GeneratedMaterial_Renderer {
+
// frameIndex should not have 3 or more frames with same value (unless it's meant to be still)
// otherwise the primitive linear interpolation will render the animation in a pretty sluggish way
- private final int[] frameIndex = new int[] {
- 0, 0, 0, 0, 1, 1, 2, 3, 4, 5, 7, 8, 9, 10, 12, 13, 14, 16, 17, 19, 21, 22, 24, 25, 27, 29, 30, 32, 33, 35, 36,
- 38, 39, 40, 42, 43, 44, 45, 46, 47, 48, 49, 50, 50, 49, 48, 47, 46, 45, 44, 43, 42, 40, 39, 38, 36, 35, 33, 32,
- 30, 29, 27, 25, 24, 22, 21, 19, 17, 16, 14, 13, 12, 10, 9, 8, 7, 5, 4, 3, 2, 1, 1, 0, 0, 0, 0
- };
- private final float[] frameRotation = new float[] {
- 0, 7, 14, 21, 28, 36, 43, 50, 57, 64,
- 72, 79, 86, 93, 100, 108, 115, 122, 129, 136,
- 144, 151, 158, 165, 172, 180, 187, 194, 201, 208,
- 216, 223, 230, 237, 244, 252, 259, 266, 273, 280,
- 288, 295, 302, 309, 316, 324, 331, 338, 345, 352,
- 360
- };
- private final float[] frameAlpha = new float[] {
- 100 / 255f, 106 / 255f, 112 / 255f, 118 / 255f, 124 / 255f, 131 / 255f, 137 / 255f, 143 / 255f, 149 / 255f,
- 155 / 255f,
- 162 / 255f, 168 / 255f, 174 / 255f, 180 / 255f, 186 / 255f, 193 / 255f, 199 / 255f, 205 / 255f, 211 / 255f,
- 217 / 255f,
- 224 / 255f, 230 / 255f, 236 / 255f, 242 / 255f, 248 / 255f, 255 / 255f, 248 / 255f, 242 / 255f, 236 / 255f,
- 230 / 255f,
- 224 / 255f, 217 / 255f, 211 / 255f, 205 / 255f, 199 / 255f, 193 / 255f, 186 / 255f, 180 / 255f, 174 / 255f,
- 168 / 255f,
- 162 / 255f, 155 / 255f, 149 / 255f, 143 / 255f, 137 / 255f, 131 / 255f, 124 / 255f, 118 / 255f, 112 / 255f,
- 106 / 255f,
- 100 / 255f
- };
+ private final int[] frameIndex = new int[] { 0, 0, 0, 0, 1, 1, 2, 3, 4, 5, 7, 8, 9, 10, 12, 13, 14, 16, 17, 19, 21,
+ 22, 24, 25, 27, 29, 30, 32, 33, 35, 36, 38, 39, 40, 42, 43, 44, 45, 46, 47, 48, 49, 50, 50, 49, 48, 47, 46,
+ 45, 44, 43, 42, 40, 39, 38, 36, 35, 33, 32, 30, 29, 27, 25, 24, 22, 21, 19, 17, 16, 14, 13, 12, 10, 9, 8, 7,
+ 5, 4, 3, 2, 1, 1, 0, 0, 0, 0 };
+ private final float[] frameRotation = new float[] { 0, 7, 14, 21, 28, 36, 43, 50, 57, 64, 72, 79, 86, 93, 100, 108,
+ 115, 122, 129, 136, 144, 151, 158, 165, 172, 180, 187, 194, 201, 208, 216, 223, 230, 237, 244, 252, 259,
+ 266, 273, 280, 288, 295, 302, 309, 316, 324, 331, 338, 345, 352, 360 };
+ private final float[] frameAlpha = new float[] { 100 / 255f, 106 / 255f, 112 / 255f, 118 / 255f, 124 / 255f,
+ 131 / 255f, 137 / 255f, 143 / 255f, 149 / 255f, 155 / 255f, 162 / 255f, 168 / 255f, 174 / 255f, 180 / 255f,
+ 186 / 255f, 193 / 255f, 199 / 255f, 205 / 255f, 211 / 255f, 217 / 255f, 224 / 255f, 230 / 255f, 236 / 255f,
+ 242 / 255f, 248 / 255f, 255 / 255f, 248 / 255f, 242 / 255f, 236 / 255f, 230 / 255f, 224 / 255f, 217 / 255f,
+ 211 / 255f, 205 / 255f, 199 / 255f, 193 / 255f, 186 / 255f, 180 / 255f, 174 / 255f, 168 / 255f, 162 / 255f,
+ 155 / 255f, 149 / 255f, 143 / 255f, 137 / 255f, 131 / 255f, 124 / 255f, 118 / 255f, 112 / 255f, 106 / 255f,
+ 100 / 255f };
private static float linearInterpolation(float[] controlPoints, int frameA, int frameB, float partial) {
float a = controlPoints[frameA], b = controlPoints[frameB];
diff --git a/src/main/java/gregtech/common/render/items/UniversiumRenderer.java b/src/main/java/gregtech/common/render/items/UniversiumRenderer.java
index baaf951ddc..d7b1aced36 100644
--- a/src/main/java/gregtech/common/render/items/UniversiumRenderer.java
+++ b/src/main/java/gregtech/common/render/items/UniversiumRenderer.java
@@ -1,10 +1,5 @@
package gregtech.common.render.items;
-import codechicken.lib.render.TextureUtils;
-import gregtech.api.enums.ItemList;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Item;
-import gregtech.common.render.GT_RenderUtil;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.ItemRenderer;
import net.minecraft.client.renderer.RenderHelper;
@@ -17,9 +12,16 @@ import net.minecraft.item.ItemStack;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraftforge.client.IItemRenderer;
+
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
+
import singulariteam.eternalsingularity.render.CosmicRenderStuffs;
+import codechicken.lib.render.TextureUtils;
+import gregtech.api.enums.ItemList;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Item;
+import gregtech.common.render.GT_RenderUtil;
public class UniversiumRenderer extends GT_GeneratedMaterial_Renderer {
@@ -38,7 +40,10 @@ public class UniversiumRenderer extends GT_GeneratedMaterial_Renderer {
@Override
public boolean renderFluidDisplayItem(ItemRenderType type, ItemStack aStack, Object... data) {
magicRenderMethod(
- type, ItemList.Emitter_UEV.get(1), aStack.getItem().getIconFromDamage(aStack.getItemDamage()), data);
+ type,
+ ItemList.Emitter_UEV.get(1),
+ aStack.getItem().getIconFromDamage(aStack.getItemDamage()),
+ data);
return true;
}
@@ -207,7 +212,14 @@ public class UniversiumRenderer extends GT_GeneratedMaterial_Renderer {
// RENDER ITEM IN HAND
ItemRenderer.renderItemIn2D(
- Tessellator.instance, f1, f2, f, f3, icon.getIconWidth(), icon.getIconHeight(), scale);
+ Tessellator.instance,
+ f1,
+ f2,
+ f,
+ f3,
+ icon.getIconWidth(),
+ icon.getIconHeight(),
+ scale);
}
GL11.glDisable(GL11.GL_ALPHA_TEST);
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java
index 7bcbe33b86..52cc1b1b96 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ChestBuffer.java
@@ -6,6 +6,7 @@ import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_CHESTBUFFER_GLOW
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
+
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -16,52 +17,55 @@ import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_ChestBuffer extends GT_MetaTileEntity_Buffer implements IAddUIWidgets {
- private static final int[] tickRate = {400, 200, 100, 20, 4, 1, 1, 1, 1, 1, 1, 1, 1};
- private static final int[] maxStacks = {1, 1, 1, 1, 1, 1, 2, 4, 8, 16, 32, 64, 128};
+ private static final int[] tickRate = { 400, 200, 100, 20, 4, 1, 1, 1, 1, 1, 1, 1, 1 };
+ private static final int[] maxStacks = { 1, 1, 1, 1, 1, 1, 2, 4, 8, 16, 32, 64, 128 };
public GT_MetaTileEntity_ChestBuffer(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 28, new String[] {
- "Buffers up to 27 Item Stacks",
- "Use Screwdriver to regulate output stack size",
- "Does not consume energy to move Item",
- getTickRateDesc(aTier)
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 28,
+ new String[] { "Buffers up to 27 Item Stacks", "Use Screwdriver to regulate output stack size",
+ "Does not consume energy to move Item", getTickRateDesc(aTier) });
}
- public GT_MetaTileEntity_ChestBuffer(
- int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount, String aDescription) {
+ public GT_MetaTileEntity_ChestBuffer(int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aInvSlotCount, aDescription);
}
- public GT_MetaTileEntity_ChestBuffer(
- int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount, String[] aDescription) {
+ public GT_MetaTileEntity_ChestBuffer(int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount,
+ String[] aDescription) {
super(aID, aName, aNameRegional, aTier, aInvSlotCount, aDescription);
}
- public GT_MetaTileEntity_ChestBuffer(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_ChestBuffer(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_ChestBuffer(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_ChestBuffer(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_ChestBuffer(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture getOverlayIcon() {
return TextureFactory.of(
TextureFactory.of(AUTOMATION_CHESTBUFFER),
- TextureFactory.builder()
- .addIcon(AUTOMATION_CHESTBUFFER_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(AUTOMATION_CHESTBUFFER_GLOW).glow().build());
}
@Override
@@ -117,10 +121,9 @@ public class GT_MetaTileEntity_ChestBuffer extends GT_MetaTileEntity_Buffer impl
addEmitRedstoneButton(builder);
addInvertRedstoneButton(builder);
addStockingModeButton(builder);
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(69, true))
- .setPos(80, 60)
- .setSize(69, 22));
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(69, true)).setPos(80, 60)
+ .setSize(69, 22));
addMainUI(builder);
}
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java
index c1be592cf4..70e2673421 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Filter.java
@@ -3,11 +3,15 @@ package gregtech.common.tileentities.automation;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_FILTER;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_FILTER_GLOW;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.ButtonWidget;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.SlotGroup;
+
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -16,35 +20,41 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Buffer;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
public class GT_MetaTileEntity_Filter extends GT_MetaTileEntity_Buffer implements IAddUIWidgets {
+
public boolean bIgnoreNBT = false;
public boolean bInvertFilter = false;
public GT_MetaTileEntity_Filter(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 19, new String[] {
- "Filters up to 9 different Items",
- "Use Screwdriver to regulate output stack size",
- "Does not consume energy to move Item"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 19,
+ new String[] { "Filters up to 9 different Items", "Use Screwdriver to regulate output stack size",
+ "Does not consume energy to move Item" });
}
- public GT_MetaTileEntity_Filter(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Filter(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_Filter(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Filter(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Filter(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
@@ -106,62 +116,48 @@ public class GT_MetaTileEntity_Filter extends GT_MetaTileEntity_Buffer implement
addEmitEnergyButton(builder);
addEmitRedstoneButton(builder);
addInvertRedstoneButton(builder);
- builder.widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> {
- bInvertFilter = !bInvertFilter;
- if (bInvertFilter) {
- GT_Utility.sendChatToPlayer(
- widget.getContext().getPlayer(), GT_Utility.trans("124", "Invert Filter"));
- } else {
- GT_Utility.sendChatToPlayer(
- widget.getContext().getPlayer(),
- GT_Utility.trans("125", "Don't invert Filter"));
- }
- })
- .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_INVERT_FILTER)
- .setPos(61, 62)
- .setSize(18, 18))
- .widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> {
- bIgnoreNBT = !bIgnoreNBT;
- if (bIgnoreNBT) {
- GT_Utility.sendChatToPlayer(
- widget.getContext().getPlayer(), GT_Utility.trans("126", "Ignore NBT"));
- } else {
- GT_Utility.sendChatToPlayer(
- widget.getContext().getPlayer(), GT_Utility.trans("127", "NBT has to match"));
- }
- })
- .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_NBT)
- .setPos(79, 62)
+ builder.widget(new ButtonWidget().setOnClick((clickData, widget) -> {
+ bInvertFilter = !bInvertFilter;
+ if (bInvertFilter) {
+ GT_Utility.sendChatToPlayer(widget.getContext().getPlayer(), GT_Utility.trans("124", "Invert Filter"));
+ } else {
+ GT_Utility.sendChatToPlayer(
+ widget.getContext().getPlayer(),
+ GT_Utility.trans("125", "Don't invert Filter"));
+ }
+ }).setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_INVERT_FILTER).setPos(61, 62)
+ .setSize(18, 18)).widget(new ButtonWidget().setOnClick((clickData, widget) -> {
+ bIgnoreNBT = !bIgnoreNBT;
+ if (bIgnoreNBT) {
+ GT_Utility.sendChatToPlayer(
+ widget.getContext().getPlayer(),
+ GT_Utility.trans("126", "Ignore NBT"));
+ } else {
+ GT_Utility.sendChatToPlayer(
+ widget.getContext().getPlayer(),
+ GT_Utility.trans("127", "NBT has to match"));
+ }
+ }).setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_NBT).setPos(79, 62)
.setSize(18, 18))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_24_WHITE.apply(9, false))
- .setPos(6, 19)
- .setSize(9, 24))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_24_BLUE.apply(24, true))
- .setPos(71, 19)
- .setSize(24, 24))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_24_RED.apply(19, true))
- .setPos(152, 19)
- .setSize(19, 24))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3)
- .setPos(16, 4)
- .setSize(54, 54))
- .widget(SlotGroup.ofItemHandler(inventoryHandler, 3)
- .startFromSlot(9)
- .endAtSlot(17)
- .phantom(true)
- .applyForWidget(widget -> widget.disableShiftInsert().setBackground(GT_UITextures.TRANSPARENT))
- .build()
- .setPos(16, 4))
- .widget(SlotGroup.ofItemHandler(inventoryHandler, 3)
- .startFromSlot(0)
- .endAtSlot(8)
- .build()
- .setPos(97, 4));
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_WHITE.apply(9, false))
+ .setPos(6, 19).setSize(9, 24))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_BLUE.apply(24, true))
+ .setPos(71, 19).setSize(24, 24))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_24_RED.apply(19, true))
+ .setPos(152, 19).setSize(19, 24))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3).setPos(16, 4)
+ .setSize(54, 54))
+ .widget(
+ SlotGroup.ofItemHandler(inventoryHandler, 3).startFromSlot(9).endAtSlot(17).phantom(true)
+ .applyForWidget(
+ widget -> widget.disableShiftInsert().setBackground(GT_UITextures.TRANSPARENT))
+ .build().setPos(16, 4))
+ .widget(
+ SlotGroup.ofItemHandler(inventoryHandler, 3).startFromSlot(0).endAtSlot(8).build()
+ .setPos(97, 4));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java
index bf2fa41b0d..e601847a72 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_ItemDistributor.java
@@ -3,9 +3,15 @@ package gregtech.common.tileentities.automation;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_ITEMDISTRIBUTOR;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_ITEMDISTRIBUTOR_GLOW;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
+
import gregtech.api.enums.Textures;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -15,53 +21,54 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Buffer;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer implements IAddUIWidgets {
+
private byte[] itemsPerSide = new byte[6];
private byte currentSide = 0, currentSideItemCount = 0;
public GT_MetaTileEntity_ItemDistributor(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 28, new String[] {
- "Distributes Items between different Machine Sides",
- "Default Items per Machine Side: 0",
- "Use Screwdriver to increase/decrease Items per Side",
- "Does not consume energy to move Item"
- });
- }
-
- public GT_MetaTileEntity_ItemDistributor(
- int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount, String aDescription) {
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 28,
+ new String[] { "Distributes Items between different Machine Sides", "Default Items per Machine Side: 0",
+ "Use Screwdriver to increase/decrease Items per Side",
+ "Does not consume energy to move Item" });
+ }
+
+ public GT_MetaTileEntity_ItemDistributor(int aID, String aName, String aNameRegional, int aTier, int aInvSlotCount,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aInvSlotCount, aDescription);
}
- public GT_MetaTileEntity_ItemDistributor(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_ItemDistributor(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_ItemDistributor(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_ItemDistributor(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_ItemDistributor(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture getOverlayIcon() {
return TextureFactory.of(
TextureFactory.of(AUTOMATION_ITEMDISTRIBUTOR),
- TextureFactory.builder()
- .addIcon(AUTOMATION_ITEMDISTRIBUTOR_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(AUTOMATION_ITEMDISTRIBUTOR_GLOW).glow().build());
}
@Override
@@ -70,13 +77,8 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
return mTextures[0][aColorIndex + 1];
} else {
@@ -89,8 +91,8 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer
ITexture[][][] returnTextures = new ITexture[2][17][];
ITexture baseIcon = getOverlayIcon(), pipeIcon = TextureFactory.of(Textures.BlockIcons.OVERLAY_PIPE_OUT);
for (int i = 0; i < 17; i++) {
- returnTextures[0][i] = new ITexture[] {Textures.BlockIcons.MACHINE_CASINGS[mTier][i], baseIcon};
- returnTextures[1][i] = new ITexture[] {Textures.BlockIcons.MACHINE_CASINGS[mTier][i], pipeIcon, baseIcon};
+ returnTextures[0][i] = new ITexture[] { Textures.BlockIcons.MACHINE_CASINGS[mTier][i], baseIcon };
+ returnTextures[1][i] = new ITexture[] { Textures.BlockIcons.MACHINE_CASINGS[mTier][i], pipeIcon, baseIcon };
}
return returnTextures;
}
@@ -185,10 +187,9 @@ public class GT_MetaTileEntity_ItemDistributor extends GT_MetaTileEntity_Buffer
addEmitEnergyButton(builder);
addEmitRedstoneButton(builder);
addInvertRedstoneButton(builder);
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(87, true))
- .setPos(62, 60)
- .setSize(87, 22));
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(87, true)).setPos(62, 60)
+ .setSize(87, 22));
addInventorySlots(builder);
}
}
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java
index 14a6af709a..7502ae73de 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_RecipeFilter.java
@@ -3,7 +3,14 @@ package gregtech.common.tileentities.automation;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_RECIPEFILTER;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_RECIPEFILTER_GLOW;
+import java.util.Collections;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.gtnewhorizons.modularui.api.drawable.Text;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
@@ -12,29 +19,28 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_SpecialFilt
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Recipe;
import gregtech.common.blocks.GT_Item_Machines;
-import java.util.Collections;
-import java.util.List;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
public class GT_MetaTileEntity_RecipeFilter extends GT_MetaTileEntity_SpecialFilter {
+
public GT_Recipe.GT_Recipe_Map mRecipeMap;
public GT_MetaTileEntity_RecipeFilter(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, new String[] {
- "Filters 1 Recipe Type",
- "Use Screwdriver to regulate output stack size",
- "Does not consume energy to move Item"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ new String[] { "Filters 1 Recipe Type", "Use Screwdriver to regulate output stack size",
+ "Does not consume energy to move Item" });
}
- public GT_MetaTileEntity_RecipeFilter(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_RecipeFilter(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_RecipeFilter(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_RecipeFilter(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@@ -59,17 +65,18 @@ public class GT_MetaTileEntity_RecipeFilter extends GT_MetaTileEntity_SpecialFil
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_RecipeFilter(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture getOverlayIcon() {
return TextureFactory.of(
TextureFactory.of(AUTOMATION_RECIPEFILTER),
- TextureFactory.builder()
- .addIcon(AUTOMATION_RECIPEFILTER_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(AUTOMATION_RECIPEFILTER_GLOW).glow().build());
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java
index 5abb6d804b..af4426932a 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_Regulator.java
@@ -3,6 +3,12 @@ package gregtech.common.tileentities.automation;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_REGULATOR;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_REGULATOR_GLOW;
+import java.util.Collections;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.internal.wrapper.BaseSlot;
@@ -10,6 +16,7 @@ import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.SlotGroup;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -18,48 +25,48 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Buffer;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import java.util.Collections;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implements IAddUIWidgets {
- public int[] mTargetSlots = {0, 0, 0, 0, 0, 0, 0, 0, 0};
+
+ public int[] mTargetSlots = { 0, 0, 0, 0, 0, 0, 0, 0, 0 };
private boolean charge = false, decharge = false;
public GT_MetaTileEntity_Regulator(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 20, new String[] {
- "Filters up to 9 different Items",
- "Allows Item-specific output stack size",
- "Allows Item-specific output slot",
- "Does not consume energy to move Item"
- });
- }
-
- public GT_MetaTileEntity_Regulator(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 20,
+ new String[] { "Filters up to 9 different Items", "Allows Item-specific output stack size",
+ "Allows Item-specific output slot", "Does not consume energy to move Item" });
+ }
+
+ public GT_MetaTileEntity_Regulator(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_Regulator(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Regulator(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Regulator(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture getOverlayIcon() {
return TextureFactory.of(
TextureFactory.of(AUTOMATION_REGULATOR),
- TextureFactory.builder()
- .addIcon(AUTOMATION_REGULATOR_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(AUTOMATION_REGULATOR_GLOW).glow().build());
}
@Override
@@ -105,19 +112,16 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem
for (int i = 0, tCosts; i < 9; i++) {
if (this.mInventory[(i + 9)] != null) {
tCosts = GT_Utility.moveOneItemStackIntoSlot(
- getBaseMetaTileEntity(),
- getBaseMetaTileEntity()
- .getTileEntityAtSide(
- getBaseMetaTileEntity().getBackFacing()),
- getBaseMetaTileEntity().getBackFacing(),
- this.mTargetSlots[i],
- Collections.singletonList(this.mInventory[(i + 9)]),
- false,
- (byte) this.mInventory[(i + 9)].stackSize,
- (byte) this.mInventory[(i + 9)].stackSize,
- (byte) 64,
- (byte) 1)
- * 3;
+ getBaseMetaTileEntity(),
+ getBaseMetaTileEntity().getTileEntityAtSide(getBaseMetaTileEntity().getBackFacing()),
+ getBaseMetaTileEntity().getBackFacing(),
+ this.mTargetSlots[i],
+ Collections.singletonList(this.mInventory[(i + 9)]),
+ false,
+ (byte) this.mInventory[(i + 9)].stackSize,
+ (byte) this.mInventory[(i + 9)].stackSize,
+ (byte) 64,
+ (byte) 1) * 3;
if (tCosts > 0) {
this.mSuccess = 50;
break;
@@ -128,8 +132,7 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem
@Override
public boolean allowPutStack(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
- return super.allowPutStack(aBaseMetaTileEntity, aIndex, aSide, aStack)
- && aIndex >= 0
+ return super.allowPutStack(aBaseMetaTileEntity, aIndex, aSide, aStack) && aIndex >= 0
&& aIndex <= 8
&& GT_Utility.areStacksEqual(aStack, this.mInventory[(aIndex + 9)]);
}
@@ -167,50 +170,40 @@ public class GT_MetaTileEntity_Regulator extends GT_MetaTileEntity_Buffer implem
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
addEmitEnergyButton(builder);
builder.widget(createChargerSlot(43, 62));
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(84, true))
- .setPos(65, 60)
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_22_RED.apply(84, true)).setPos(65, 60)
.setSize(84, 22))
- .widget(SlotGroup.ofItemHandler(inventoryHandler, 3)
- .startFromSlot(0)
- .endAtSlot(8)
- .build()
- .setPos(7, 5))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3)
- .setPos(62, 5)
- .setSize(54, 54))
- .widget(SlotGroup.ofItemHandler(inventoryHandler, 3)
- .phantom(true)
- .startFromSlot(9)
- .endAtSlot(17)
- .applyForWidget(
- widget -> widget.setControlsAmount(true).setBackground(GT_UITextures.TRANSPARENT))
- .build()
- .setPos(62, 5))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3)
- .setPos(117, 5)
- .setSize(54, 54));
+ .widget(SlotGroup.ofItemHandler(inventoryHandler, 3).startFromSlot(0).endAtSlot(8).build().setPos(7, 5))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3).setPos(62, 5)
+ .setSize(54, 54))
+ .widget(
+ SlotGroup.ofItemHandler(inventoryHandler, 3).phantom(true).startFromSlot(9).endAtSlot(17)
+ .applyForWidget(
+ widget -> widget.setControlsAmount(true)
+ .setBackground(GT_UITextures.TRANSPARENT))
+ .build().setPos(62, 5))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SLOTS_HOLO_3BY3).setPos(117, 5)
+ .setSize(54, 54));
int xBase = 117, yBase = 5;
for (int i = 0; i < mTargetSlots.length; i++) {
final int index = i;
int xPos = xBase + (i % 3) * 18, yPos = yBase + (i / 3) * 18;
- builder.widget(
- new SlotWidget(BaseSlot.empty()) {
- @Override
- protected void phantomClick(ClickData clickData, ItemStack cursorStack) {
- mTargetSlots[index] = Math.min(
- 99,
- Math.max(
- 0,
- mTargetSlots[index]
- + (clickData.mouseButton == 0 ? -1 : 1)
- * (clickData.shift ? 16 : 1)));
- }
- }.setBackground(GT_UITextures.TRANSPARENT).setPos(xPos, yPos))
- .widget(TextWidget.dynamicString(() -> String.valueOf(mTargetSlots[index]))
+ builder.widget(new SlotWidget(BaseSlot.empty()) {
+
+ @Override
+ protected void phantomClick(ClickData clickData, ItemStack cursorStack) {
+ mTargetSlots[index] = Math.min(
+ 99,
+ Math.max(
+ 0,
+ mTargetSlots[index]
+ + (clickData.mouseButton == 0 ? -1 : 1) * (clickData.shift ? 16 : 1)));
+ }
+ }.setBackground(GT_UITextures.TRANSPARENT).setPos(xPos, yPos)).widget(
+ TextWidget.dynamicString(() -> String.valueOf(mTargetSlots[index]))
.setDefaultColor(COLOR_TEXT_WHITE.get())
.setPos(xPos + 2 + (i % 3 == 0 ? 1 : 0), yPos + 3 + (i / 3 == 0 ? 1 : 0)));
}
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java
index a91a082c4e..cefd3152c1 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_SuperBuffer.java
@@ -3,54 +3,61 @@ package gregtech.common.tileentities.automation;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_SUPERBUFFER;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_SUPERBUFFER_GLOW;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import net.minecraft.item.ItemStack;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
+
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_SuperBuffer extends GT_MetaTileEntity_ChestBuffer {
+
public GT_MetaTileEntity_SuperBuffer(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 257, new String[] {
- "Buffers up to 256 Item Stacks",
- "Use Screwdriver to regulate output stack size",
- "Does not consume energy to move Item",
- getTickRateDesc(aTier)
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 257,
+ new String[] { "Buffers up to 256 Item Stacks", "Use Screwdriver to regulate output stack size",
+ "Does not consume energy to move Item", getTickRateDesc(aTier) });
}
- public GT_MetaTileEntity_SuperBuffer(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_SuperBuffer(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_SuperBuffer(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_SuperBuffer(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_SuperBuffer(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture getOverlayIcon() {
return TextureFactory.of(
TextureFactory.of(AUTOMATION_SUPERBUFFER),
- TextureFactory.builder()
- .addIcon(AUTOMATION_SUPERBUFFER_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(AUTOMATION_SUPERBUFFER_GLOW).glow().build());
}
@Override
@@ -86,9 +93,7 @@ public class GT_MetaTileEntity_SuperBuffer extends GT_MetaTileEntity_ChestBuffer
@Override
protected void addMainUI(ModularWindow.Builder builder) {
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SUPER_BUFFER)
- .setPos(61, 4)
- .setSize(54, 54));
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SUPER_BUFFER).setPos(61, 4).setSize(54, 54));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_TypeFilter.java b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_TypeFilter.java
index 49cdc6617c..64b5a43ad8 100644
--- a/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_TypeFilter.java
+++ b/src/main/java/gregtech/common/tileentities/automation/GT_MetaTileEntity_TypeFilter.java
@@ -4,7 +4,16 @@ import static gregtech.api.enums.GT_Values.W;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_TYPEFILTER;
import static gregtech.api.enums.Textures.BlockIcons.AUTOMATION_TYPEFILTER_GLOW;
+import java.util.Arrays;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+
import com.google.common.collect.ImmutableList;
+
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -14,14 +23,9 @@ import gregtech.api.objects.ItemData;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Utility;
-import java.util.Arrays;
-import java.util.List;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
public class GT_MetaTileEntity_TypeFilter extends GT_MetaTileEntity_SpecialFilter {
+
public int mRotationIndex = 0;
public OrePrefixes mPrefix = OrePrefixes.ore;
@@ -41,37 +45,40 @@ public class GT_MetaTileEntity_TypeFilter extends GT_MetaTileEntity_SpecialFilte
OrePrefixes.oreMarble);
public GT_MetaTileEntity_TypeFilter(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, new String[] {
- "Filters 1 Item Type",
- "Use Screwdriver to regulate output stack size",
- "Does not consume energy to move Item"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ new String[] { "Filters 1 Item Type", "Use Screwdriver to regulate output stack size",
+ "Does not consume energy to move Item" });
}
- public GT_MetaTileEntity_TypeFilter(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_TypeFilter(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_TypeFilter(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_TypeFilter(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_TypeFilter(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture getOverlayIcon() {
return TextureFactory.of(
TextureFactory.of(AUTOMATION_TYPEFILTER),
- TextureFactory.builder()
- .addIcon(AUTOMATION_TYPEFILTER_GLOW)
- .glow()
- .build());
+ TextureFactory.builder().addIcon(AUTOMATION_TYPEFILTER_GLOW).glow().build());
}
@Override
@@ -121,8 +128,8 @@ public class GT_MetaTileEntity_TypeFilter extends GT_MetaTileEntity_SpecialFilte
}
this.mInventory[SPECIAL_SLOT_INDEX] = GT_Utility.copyAmount(
1L,
- this.mPrefix.mPrefixedItems.get(
- this.mRotationIndex = (this.mRotationIndex + 1) % this.mPrefix.mPrefixedItems.size()));
+ this.mPrefix.mPrefixedItems
+ .get(this.mRotationIndex = (this.mRotationIndex + 1) % this.mPrefix.mPrefixedItems.size()));
if (this.mInventory[SPECIAL_SLOT_INDEX] == null) return;
if (this.mInventory[SPECIAL_SLOT_INDEX].getItemDamage() == W) this.mInventory[9].setItemDamage(0);
this.mInventory[SPECIAL_SLOT_INDEX].setStackDisplayName(this.mPrefix.toString());
diff --git a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler.java b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler.java
index 9eb861ad06..3d2f69c26d 100644
--- a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler.java
+++ b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler.java
@@ -2,6 +2,14 @@ package gregtech.common.tileentities.boilers;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.fluids.IFluidHandler;
+
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
import com.gtnewhorizons.modularui.api.drawable.UITexture;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
@@ -9,6 +17,7 @@ import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
@@ -30,16 +39,10 @@ import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
import gregtech.common.GT_Pollution;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.fluids.IFluidHandler;
public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTank
implements IGetTitleColor, IAddUIWidgets {
+
public static final byte SOUND_EVENT_LET_OFF_EXCESS_STEAM = 1;
public int mTemperature = 20;
public int mProcessingEnergy = 0;
@@ -48,13 +51,13 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
public boolean mHadNoWater = false;
private int mExcessWater = 0;
- public GT_MetaTileEntity_Boiler(
- int aID, String aName, String aNameRegional, String aDescription, ITexture... aTextures) {
+ public GT_MetaTileEntity_Boiler(int aID, String aName, String aNameRegional, String aDescription,
+ ITexture... aTextures) {
super(aID, aName, aNameRegional, 0, 4, aDescription, aTextures);
}
- public GT_MetaTileEntity_Boiler(
- int aID, String aName, String aNameRegional, String[] aDescription, ITexture... aTextures) {
+ public GT_MetaTileEntity_Boiler(int aID, String aName, String aNameRegional, String[] aDescription,
+ ITexture... aTextures) {
super(aID, aName, aNameRegional, 0, 4, aDescription, aTextures);
}
@@ -67,17 +70,12 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- ITexture[] tmp =
- mTextures[aSide >= 2 ? aSide != aFacing ? 2 : ((byte) (aActive ? 4 : 3)) : aSide][aColorIndex + 1];
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ ITexture[] tmp = mTextures[aSide >= 2 ? aSide != aFacing ? 2 : ((byte) (aActive ? 4 : 3)) : aSide][aColorIndex
+ + 1];
if (aSide != aFacing && tmp.length == 2) {
- tmp = new ITexture[] {tmp[0]};
+ tmp = new ITexture[] { tmp[0] };
}
return tmp;
}
@@ -214,8 +212,7 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
}
try {
aNBT.setTag("mSteam", this.mSteam.writeToNBT(new NBTTagCompound()));
- } catch (Throwable ignored) {
- }
+ } catch (Throwable ignored) {}
}
@Override
@@ -275,8 +272,7 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
}
private void calculateHeatUp(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
- if ((this.mTemperature < getMaxTemperature())
- && (this.mProcessingEnergy > 0)
+ if ((this.mTemperature < getMaxTemperature()) && (this.mProcessingEnergy > 0)
&& (aTick % getHeatUpRate() == 0L)) {
this.mProcessingEnergy -= getEnergyConsumption();
this.mTemperature += getHeatUpAmount();
@@ -325,11 +321,10 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
protected final void pushSteamToSide(IGregTechTileEntity aBaseMetaTileEntity, int aSide) {
IFluidHandler tTileEntity = aBaseMetaTileEntity.getITankContainerAtSide((byte) aSide);
if (tTileEntity == null) return;
- FluidStack tDrained = aBaseMetaTileEntity.drain(
- ForgeDirection.getOrientation(aSide), Math.max(1, this.mSteam.amount / 2), false);
+ FluidStack tDrained = aBaseMetaTileEntity
+ .drain(ForgeDirection.getOrientation(aSide), Math.max(1, this.mSteam.amount / 2), false);
if (tDrained == null) return;
- int tFilledAmount =
- tTileEntity.fill(ForgeDirection.getOrientation(aSide).getOpposite(), tDrained, false);
+ int tFilledAmount = tTileEntity.fill(ForgeDirection.getOrientation(aSide).getOpposite(), tDrained, false);
if (tFilledAmount <= 0) return;
tTileEntity.fill(
ForgeDirection.getOrientation(aSide).getOpposite(),
@@ -370,13 +365,13 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
if (aIndex == GT_MetaTileEntity_Boiler.SOUND_EVENT_LET_OFF_EXCESS_STEAM) {
GT_Utility.doSoundAtClient(SoundResource.RANDOM_FIZZ, 2, 1.0F, aX, aY, aZ);
- new ParticleEventBuilder()
- .setIdentifier(ParticleFX.CLOUD)
- .setWorld(getBaseMetaTileEntity().getWorld())
- .setMotion(0D, 0D, 0D)
- .<ParticleEventBuilder>times(8, x -> x.setPosition(
- aX - 0.5D + XSTR_INSTANCE.nextFloat(), aY, aZ - 0.5D + XSTR_INSTANCE.nextFloat())
- .run());
+ new ParticleEventBuilder().setIdentifier(ParticleFX.CLOUD).setWorld(getBaseMetaTileEntity().getWorld())
+ .setMotion(0D, 0D, 0D).<ParticleEventBuilder>times(
+ 8,
+ x -> x.setPosition(
+ aX - 0.5D + XSTR_INSTANCE.nextFloat(),
+ aY,
+ aZ - 0.5D + XSTR_INSTANCE.nextFloat()).run());
}
}
@@ -420,15 +415,13 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
}
protected IDrawable[] getFuelSlotBackground() {
- return new IDrawable[] {
- getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_COAL_STEAM.get(getSteamVariant())
- };
+ return new IDrawable[] { getGUITextureSet().getItemSlot(),
+ GT_UITextures.OVERLAY_SLOT_COAL_STEAM.get(getSteamVariant()) };
}
protected IDrawable[] getAshSlotBackground() {
- return new IDrawable[] {
- getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant())
- };
+ return new IDrawable[] { getGUITextureSet().getItemSlot(),
+ GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant()) };
}
@Override
@@ -438,44 +431,41 @@ public abstract class GT_MetaTileEntity_Boiler extends GT_MetaTileEntity_BasicTa
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new SlotWidget(inventoryHandler, 0)
- .setPos(43, 25)
+ builder.widget(
+ new SlotWidget(inventoryHandler, 0).setPos(43, 25)
.setBackground(getGUITextureSet().getItemSlot(), getOverlaySlotIn()))
- .widget(new SlotWidget(inventoryHandler, 1)
- .setPos(43, 61)
- .setBackground(getGUITextureSet().getItemSlot(), getOverlaySlotOut()))
- .widget(createFuelSlot())
- .widget(createAshSlot())
- .widget(new ProgressBar()
- .setProgress(() -> mSteam == null ? 0 : (float) mSteam.amount / getCapacity())
- .setTexture(getProgressbarEmpty(), GT_UITextures.PROGRESSBAR_BOILER_STEAM, 10)
- .setDirection(ProgressBar.Direction.UP)
- .setPos(70, 25)
- .setSize(10, 54))
- .widget(new ProgressBar()
- .setProgress(() -> mFluid == null ? 0 : (float) mFluid.amount / getCapacity())
- .setTexture(getProgressbarEmpty(), GT_UITextures.PROGRESSBAR_BOILER_WATER, 10)
- .setDirection(ProgressBar.Direction.UP)
- .setPos(83, 25)
- .setSize(10, 54))
- .widget(new ProgressBar()
- .setProgress(() -> (float) mTemperature / maxProgresstime())
- .setTexture(getProgressbarEmpty(), GT_UITextures.PROGRESSBAR_BOILER_HEAT, 10)
- .setDirection(ProgressBar.Direction.UP)
- .setPos(96, 25)
- .setSize(10, 54))
- .widget(new ProgressBar()
- // cap minimum so that one can easily see there's fuel remaining
- .setProgress(
- () -> mProcessingEnergy > 0 ? Math.max((float) mProcessingEnergy / 1000, 1f / 5) : 0)
- .setTexture(getProgressbarFuel(), 14)
- .setDirection(ProgressBar.Direction.UP)
- .setPos(116, 45)
- .setSize(14, 14))
- .widget(new DrawableWidget()
- .setDrawable(getOverlaySlotCanister())
- .setPos(43, 43)
- .setSize(18, 18));
+ .widget(
+ new SlotWidget(inventoryHandler, 1).setPos(
+ 43,
+ 61).setBackground(
+ getGUITextureSet().getItemSlot(),
+ getOverlaySlotOut()))
+ .widget(createFuelSlot()).widget(
+ createAshSlot())
+ .widget(
+ new ProgressBar().setProgress(() -> mSteam == null ? 0 : (float) mSteam.amount / getCapacity())
+ .setTexture(
+ getProgressbarEmpty(),
+ GT_UITextures.PROGRESSBAR_BOILER_STEAM,
+ 10)
+ .setDirection(ProgressBar.Direction.UP).setPos(70, 25).setSize(10, 54))
+ .widget(
+ new ProgressBar().setProgress(() -> mFluid == null ? 0 : (float) mFluid.amount / getCapacity())
+ .setTexture(getProgressbarEmpty(), GT_UITextures.PROGRESSBAR_BOILER_WATER, 10)
+ .setDirection(ProgressBar.Direction.UP).setPos(83, 25).setSize(10, 54))
+ .widget(
+ new ProgressBar().setProgress(() -> (float) mTemperature / maxProgresstime())
+ .setTexture(getProgressbarEmpty(), GT_UITextures.PROGRESSBAR_BOILER_HEAT, 10)
+ .setDirection(ProgressBar.Direction.UP).setPos(96, 25).setSize(10, 54))
+ .widget(
+ new ProgressBar()
+ // cap minimum so that one can easily see there's fuel remaining
+ .setProgress(
+ () -> mProcessingEnergy > 0 ? Math.max((float) mProcessingEnergy / 1000, 1f / 5)
+ : 0)
+ .setTexture(getProgressbarFuel(), 14).setDirection(ProgressBar.Direction.UP)
+ .setPos(116, 45).setSize(14, 14))
+ .widget(new DrawableWidget().setDrawable(getOverlaySlotCanister()).setPos(43, 43).setSize(18, 18));
}
protected SlotWidget createFuelSlot() {
diff --git a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Bronze.java b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Bronze.java
index ef343d24f2..e88a35c617 100644
--- a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Bronze.java
@@ -10,6 +10,10 @@ import static gregtech.api.enums.Textures.BlockIcons.MACHINE_BRONZEBRICKS_TOP;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPE;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.block.Block;
+import net.minecraft.tileentity.TileEntityFurnace;
+import net.minecraftforge.common.util.ForgeDirection;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.GT_Mod;
@@ -26,17 +30,17 @@ import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
import gregtech.common.GT_Pollution;
-import net.minecraft.block.Block;
-import net.minecraft.tileentity.TileEntityFurnace;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
+
public GT_MetaTileEntity_Boiler_Bronze(int aID, String aName, String aNameRegional) {
- super(aID, aName, aNameRegional, new String[] {
- "An early way to get Steam Power",
- "Produces 120L of Steam per second",
- "Causes " + GT_Mod.gregtechproxy.mPollutionSmallCoalBoilerPerSecond + " Pollution per second"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ new String[] { "An early way to get Steam Power", "Produces 120L of Steam per second",
+ "Causes " + GT_Mod.gregtechproxy.mPollutionSmallCoalBoilerPerSecond
+ + " Pollution per second" });
}
public GT_MetaTileEntity_Boiler_Bronze(int aID, String aName, String aNameRegional, String[] aDescription) {
@@ -54,27 +58,13 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
@Override
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[5][17][];
- final ITexture[] texBottom = {TextureFactory.of(MACHINE_BRONZEBRICKS_BOTTOM)},
- texTop = {TextureFactory.of(MACHINE_BRONZEBRICKS_TOP), TextureFactory.of(OVERLAY_PIPE)},
- texSide = {TextureFactory.of(MACHINE_BRONZEBRICKS_SIDE), TextureFactory.of(OVERLAY_PIPE)},
- texFront =
- {
- TextureFactory.of(MACHINE_BRONZEBRICKS_SIDE),
- TextureFactory.of(BOILER_FRONT),
- TextureFactory.builder()
- .addIcon(BOILER_FRONT_GLOW)
- .glow()
- .build()
- },
- texFrontActive =
- {
- TextureFactory.of(MACHINE_BRONZEBRICKS_SIDE),
- TextureFactory.of(BOILER_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(BOILER_FRONT_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ final ITexture[] texBottom = { TextureFactory.of(MACHINE_BRONZEBRICKS_BOTTOM) },
+ texTop = { TextureFactory.of(MACHINE_BRONZEBRICKS_TOP), TextureFactory.of(OVERLAY_PIPE) },
+ texSide = { TextureFactory.of(MACHINE_BRONZEBRICKS_SIDE), TextureFactory.of(OVERLAY_PIPE) },
+ texFront = { TextureFactory.of(MACHINE_BRONZEBRICKS_SIDE), TextureFactory.of(BOILER_FRONT),
+ TextureFactory.builder().addIcon(BOILER_FRONT_GLOW).glow().build() },
+ texFrontActive = { TextureFactory.of(MACHINE_BRONZEBRICKS_SIDE), TextureFactory.of(BOILER_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(BOILER_FRONT_ACTIVE_GLOW).glow().build() };
for (int i = 0; i < 17; i++) {
rTextures[0][i] = texBottom;
rTextures[1][i] = texTop;
@@ -107,8 +97,7 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
final byte frontFacing = aBaseMetaTileEntity.getFrontFacing();
- if (frontFacing > 1
- && aBaseMetaTileEntity.getCoverIDAtSide(frontFacing) == 0
+ if (frontFacing > 1 && aBaseMetaTileEntity.getCoverIDAtSide(frontFacing) == 0
&& !aBaseMetaTileEntity.getOpacityAtSide(frontFacing)) {
final double oX = aBaseMetaTileEntity.getOffsetX(frontFacing, 1) + 8D / 16D;
@@ -136,10 +125,8 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
z = oZ + offset;
}
- ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder())
- .setMotion(0D, 0D, 0D)
- .setPosition(x, y, z)
- .setWorld(getBaseMetaTileEntity().getWorld());
+ ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder()).setMotion(0D, 0D, 0D)
+ .setPosition(x, y, z).setWorld(getBaseMetaTileEntity().getWorld());
particleEventBuilder.setIdentifier(ParticleFX.SMOKE).run();
particleEventBuilder.setIdentifier(ParticleFX.FLAME).run();
}
@@ -149,8 +136,7 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
@Override
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
super.onPostTick(aBaseMetaTileEntity, aTick);
- if ((aBaseMetaTileEntity.isServerSide())
- && (aTick > 20L)
+ if ((aBaseMetaTileEntity.isServerSide()) && (aTick > 20L)
&& this.mProcessingEnergy > 0
&& (aTick % 20L == 0L)) {
GT_Pollution.addPollution(getBaseMetaTileEntity(), getPollution());
@@ -186,7 +172,7 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
protected void updateFuel(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
if (this.mInventory[2] == null) return;
if ((GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Coal)
- && !GT_Utility.isPartOfOrePrefix(this.mInventory[2], OrePrefixes.block))
+ && !GT_Utility.isPartOfOrePrefix(this.mInventory[2], OrePrefixes.block))
|| (GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Charcoal)
&& !GT_Utility.isPartOfOrePrefix(this.mInventory[2], OrePrefixes.block))
|| (GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Lignite)
@@ -202,9 +188,8 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
this.mProcessingEnergy += (TileEntityFurnace.getItemBurnTime(this.mInventory[2]) / 10);
aBaseMetaTileEntity.decrStackSize(2, 1);
if (XSTR.XSTR_INSTANCE.nextInt(
- GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Coal)
- || GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Charcoal)
- ? 3
+ GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Coal)
+ || GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Charcoal) ? 3
: GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Lignite) ? 8 : 2)
== 0) {
aBaseMetaTileEntity.addStackToSlot(
@@ -212,99 +197,93 @@ public class GT_MetaTileEntity_Boiler_Bronze extends GT_MetaTileEntity_Boiler {
GT_OreDictUnificator.get(
OrePrefixes.dustTiny,
(GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Lignite)
- || GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Coal))
- ? Materials.DarkAsh
- : Materials.Ash,
+ || GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Coal))
+ ? Materials.DarkAsh
+ : Materials.Ash,
1L));
}
}
} else if (
// If its a block of the following materials
GT_OreDictUnificator.isItemStackInstanceOf(this.mInventory[2], OrePrefixes.block.get(Materials.Coal))
- || GT_OreDictUnificator.isItemStackInstanceOf(
- this.mInventory[2], OrePrefixes.block.get(Materials.Lignite))
- || GT_OreDictUnificator.isItemStackInstanceOf(
- this.mInventory[2], OrePrefixes.block.get(Materials.Charcoal))
- || GT_OreDictUnificator.isItemStackInstanceOf(
- this.mInventory[2], OrePrefixes.block.get(Materials.Diamond))
+ || GT_OreDictUnificator
+ .isItemStackInstanceOf(this.mInventory[2], OrePrefixes.block.get(Materials.Lignite))
+ || GT_OreDictUnificator
+ .isItemStackInstanceOf(this.mInventory[2], OrePrefixes.block.get(Materials.Charcoal))
+ || GT_OreDictUnificator
+ .isItemStackInstanceOf(this.mInventory[2], OrePrefixes.block.get(Materials.Diamond))
||
// if its either a Railcraft Coke Block or a custom GTNH compressed Coal/charcoal/lignite/coke block
- (Block.getBlockFromItem(this.mInventory[2].getItem()) != null
- && // check if the block exists
- (Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("tile")
- && // check if the block is a tile -> block
+ (Block.getBlockFromItem(this.mInventory[2].getItem()) != null && // check if the block exists
+ (Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName().toLowerCase()
+ .contains("tile") && // check if the block is a tile -> block
(
// If the name of the block contains these names
- Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("charcoal")
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("coal")
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("diamond")
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("coke")
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("railcraft.cube")
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("lignite"))))) {
- // try to add 10% of the burnvalue as Processing energy, no boost for coal coke here
- if ((TileEntityFurnace.getItemBurnTime(this.mInventory[2]) / 10) > 0) {
- this.mProcessingEnergy += (TileEntityFurnace.getItemBurnTime(this.mInventory[2]) / 10);
- aBaseMetaTileEntity.decrStackSize(2, 1);
- aBaseMetaTileEntity.addStackToSlot(
- 3,
- GT_OreDictUnificator.get(
- OrePrefixes.dust,
- (GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Lignite)
- || GT_Utility.isPartOfMaterials(this.mInventory[2], Materials.Coal)
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("coal")
- || Block.getBlockFromItem(this.mInventory[2].getItem())
- .getUnlocalizedName()
- .toLowerCase()
- .contains("lignite"))
- ? Materials.DarkAsh
- : Materials.Ash,
- 1L));
- }
- // enables every other fuel with at least 2000 burntime as a fuel, i.e. peat, Magic/Solid Super Fuel, Coal
- // Singularities, Nitor, while bucket of creosite should be blocked same goes for lava
- } else if ((TileEntityFurnace.getItemBurnTime(this.mInventory[2])) >= 2000
- && !(this.mInventory[2].getUnlocalizedName().toLowerCase().contains("bucket")
- || this.mInventory[2].getUnlocalizedName().toLowerCase().contains("cell"))) {
- this.mProcessingEnergy += (TileEntityFurnace.getItemBurnTime(this.mInventory[2]) / 10);
- aBaseMetaTileEntity.decrStackSize(2, 1);
- // adds tiny pile of ash for burntime under 10k, small pile for under 100k and pile for bigger values
- if (XSTR.XSTR_INSTANCE.nextInt(2) == 0)
- aBaseMetaTileEntity.addStackToSlot(
- 3,
- GT_OreDictUnificator.get(
- (TileEntityFurnace.getItemBurnTime(this.mInventory[2]) >= 10000
- ? TileEntityFurnace.getItemBurnTime(this.mInventory[2]) >= 100000
- ? OrePrefixes.dust
- : OrePrefixes.dustSmall
- : OrePrefixes.dustTiny),
- Materials.Ash,
- 1L));
- }
+ Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName().toLowerCase()
+ .contains("charcoal")
+ || Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName()
+ .toLowerCase().contains("coal")
+ || Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName()
+ .toLowerCase().contains("diamond")
+ || Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName()
+ .toLowerCase().contains("coke")
+ || Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName()
+ .toLowerCase().contains("railcraft.cube")
+ || Block.getBlockFromItem(this.mInventory[2].getItem()).getUnlocalizedName()
+ .toLowerCase().contains("lignite"))))) {
+ // try to add 10% of the burnvalue as Processing energy, no boost
+ // for coal coke here
+ if ((TileEntityFurnace.getItemBurnTime(this.mInventory[2]) / 10)
+ > 0) {
+ this.mProcessingEnergy += (TileEntityFurnace
+ .getItemBurnTime(this.mInventory[2]) / 10);
+ aBaseMetaTileEntity.decrStackSize(2, 1);
+ aBaseMetaTileEntity.addStackToSlot(
+ 3,
+ GT_OreDictUnificator.get(
+ OrePrefixes.dust,
+ (GT_Utility.isPartOfMaterials(
+ this.mInventory[2],
+ Materials.Lignite)
+ || GT_Utility.isPartOfMaterials(
+ this.mInventory[2],
+ Materials.Coal)
+ || Block.getBlockFromItem(
+ this.mInventory[2].getItem())
+ .getUnlocalizedName()
+ .toLowerCase().contains("coal")
+ || Block.getBlockFromItem(
+ this.mInventory[2].getItem())
+ .getUnlocalizedName()
+ .toLowerCase()
+ .contains("lignite"))
+ ? Materials.DarkAsh
+ : Materials.Ash,
+ 1L));
+ }
+ // enables every other fuel with at least 2000 burntime as a fuel,
+ // i.e. peat, Magic/Solid Super Fuel, Coal
+ // Singularities, Nitor, while bucket of creosite should be blocked
+ // same goes for lava
+ } else
+ if ((TileEntityFurnace.getItemBurnTime(this.mInventory[2])) >= 2000
+ && !(this.mInventory[2].getUnlocalizedName().toLowerCase().contains("bucket")
+ || this.mInventory[2].getUnlocalizedName().toLowerCase().contains("cell"))) {
+ this.mProcessingEnergy += (TileEntityFurnace.getItemBurnTime(this.mInventory[2]) / 10);
+ aBaseMetaTileEntity.decrStackSize(2, 1);
+ // adds tiny pile of ash for burntime under 10k, small pile for under 100k and pile for
+ // bigger values
+ if (XSTR.XSTR_INSTANCE.nextInt(2) == 0) aBaseMetaTileEntity.addStackToSlot(
+ 3,
+ GT_OreDictUnificator.get(
+ (TileEntityFurnace.getItemBurnTime(this.mInventory[2]) >= 10000
+ ? TileEntityFurnace.getItemBurnTime(this.mInventory[2])
+ >= 100000 ? OrePrefixes.dust : OrePrefixes.dustSmall
+ : OrePrefixes.dustTiny),
+ Materials.Ash,
+ 1L));
+ }
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Lava.java b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Lava.java
index 14a2833549..6a1ad39195 100644
--- a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Lava.java
+++ b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Lava.java
@@ -9,6 +9,8 @@ import static gregtech.api.enums.Textures.BlockIcons.MACHINE_STEELBRICKS_SIDE;
import static gregtech.api.enums.Textures.BlockIcons.MACHINE_STEELBRICKS_TOP;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPE;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.GT_Mod;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
@@ -19,7 +21,6 @@ import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_OreDictUnificator;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_Boiler_Lava extends GT_MetaTileEntity_Boiler {
@@ -29,14 +30,18 @@ public class GT_MetaTileEntity_Boiler_Lava extends GT_MetaTileEntity_Boiler {
public static final int PRODUCTION_PER_SECOND = 600;
public GT_MetaTileEntity_Boiler_Lava(int aID, String aName, String aNameRegional) {
- super(aID, aName, aNameRegional, new String[] {
- "A Boiler running off Lava",
- "Produces " + PRODUCTION_PER_SECOND + "L of Steam per second",
- "Causes " + Integer.toString(GT_Mod.gregtechproxy.mPollutionHighPressureLavaBoilerPerSecond)
- + " Pollution per second",
- "Consumes " + ((double) CONSUMPTION_PER_HEATUP / ENERGY_PER_LAVA) + "L of Lava every " + COOLDOWN_INTERVAL
- + " ticks when fully heat up"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ new String[] { "A Boiler running off Lava",
+ "Produces " + PRODUCTION_PER_SECOND + "L of Steam per second",
+ "Causes " + Integer.toString(GT_Mod.gregtechproxy.mPollutionHighPressureLavaBoilerPerSecond)
+ + " Pollution per second",
+ "Consumes " + ((double) CONSUMPTION_PER_HEATUP / ENERGY_PER_LAVA)
+ + "L of Lava every "
+ + COOLDOWN_INTERVAL
+ + " ticks when fully heat up" });
}
public GT_MetaTileEntity_Boiler_Lava(String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
@@ -50,24 +55,14 @@ public class GT_MetaTileEntity_Boiler_Lava extends GT_MetaTileEntity_Boiler {
@Override
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[5][17][];
- final ITexture[] texBottom = {TextureFactory.of(MACHINE_STEELBRICKS_BOTTOM)},
- texTop = {TextureFactory.of(MACHINE_STEELBRICKS_TOP), TextureFactory.of(OVERLAY_PIPE)},
- texSide = {TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(OVERLAY_PIPE)},
- texFront =
- {
- TextureFactory.of(MACHINE_STEELBRICKS_SIDE),
- TextureFactory.of(BOILER_LAVA_FRONT),
- TextureFactory.of(BOILER_LAVA_FRONT_GLOW)
- },
- texFrontActive =
- {
- TextureFactory.of(MACHINE_STEELBRICKS_SIDE),
- TextureFactory.of(BOILER_LAVA_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(BOILER_LAVA_FRONT_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ final ITexture[] texBottom = { TextureFactory.of(MACHINE_STEELBRICKS_BOTTOM) },
+ texTop = { TextureFactory.of(MACHINE_STEELBRICKS_TOP), TextureFactory.of(OVERLAY_PIPE) },
+ texSide = { TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(OVERLAY_PIPE) },
+ texFront = { TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(BOILER_LAVA_FRONT),
+ TextureFactory.of(BOILER_LAVA_FRONT_GLOW) },
+ texFrontActive = { TextureFactory.of(MACHINE_STEELBRICKS_SIDE),
+ TextureFactory.of(BOILER_LAVA_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(BOILER_LAVA_FRONT_ACTIVE_GLOW).glow().build() };
for (byte i = 0; i < 17; i++) {
rTextures[0][i] = texBottom;
rTextures[1][i] = texTop;
@@ -124,12 +119,12 @@ public class GT_MetaTileEntity_Boiler_Lava extends GT_MetaTileEntity_Boiler {
this.mProcessingEnergy += 1000 * ENERGY_PER_LAVA;
aBaseMetaTileEntity.decrStackSize(2, 1);
aBaseMetaTileEntity.addStackToSlot(3, GT_OreDictUnificator.get(OrePrefixes.bucket, Materials.Empty, 1L));
- } else if (GT_OreDictUnificator.isItemStackInstanceOf(
- this.mInventory[2], OrePrefixes.bucketClay.get(Materials.Lava))) {
- this.mProcessingEnergy += 1000 * ENERGY_PER_LAVA;
- aBaseMetaTileEntity.decrStackSize(2, 1);
- // Clay lava buckets break, so you don't get it back.
- }
+ } else if (GT_OreDictUnificator
+ .isItemStackInstanceOf(this.mInventory[2], OrePrefixes.bucketClay.get(Materials.Lava))) {
+ this.mProcessingEnergy += 1000 * ENERGY_PER_LAVA;
+ aBaseMetaTileEntity.decrStackSize(2, 1);
+ // Clay lava buckets break, so you don't get it back.
+ }
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar.java b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar.java
index 978e70e5ab..746f0602d6 100644
--- a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar.java
+++ b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar.java
@@ -5,8 +5,22 @@ import static gregtech.api.enums.ConfigCategories.machineconfig;
import static mcp.mobius.waila.api.SpecialChars.GOLD;
import static mcp.mobius.waila.api.SpecialChars.RESET;
+import java.util.List;
+
+import mcp.mobius.waila.api.IWailaConfigHandler;
+import mcp.mobius.waila.api.IWailaDataAccessor;
+
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
+
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
import gregtech.api.enums.Dyes;
import gregtech.api.enums.SteamVariant;
import gregtech.api.enums.Textures.BlockIcons;
@@ -18,18 +32,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_LanguageManager;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Utility;
-import java.util.List;
-import mcp.mobius.waila.api.IWailaConfigHandler;
-import mcp.mobius.waila.api.IWailaDataAccessor;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
+
public static final String LPS_FMT = "%s L/s";
private static final String localizedDescFormat = GT_LanguageManager.addStringLocalization(
"gt.blockmachines.boiler.solar.desc.format",
@@ -55,8 +60,8 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
mConfig = createConfig();
}
- protected GT_MetaTileEntity_Boiler_Solar(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures, Config aConfig) {
+ protected GT_MetaTileEntity_Boiler_Solar(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ Config aConfig) {
super(aName, aTier, aDescription, aTextures);
mConfig = aConfig;
}
@@ -93,10 +98,9 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
@Override
public String[] getDescription() {
return String.format(
- localizedDescFormat,
- GT_Utility.formatNumbers(getMaxOutputPerSecond()),
- GT_Utility.formatNumbers(getMinOutputPerSecond()))
- .split("\\R");
+ localizedDescFormat,
+ GT_Utility.formatNumbers(getMaxOutputPerSecond()),
+ GT_Utility.formatNumbers(getMinOutputPerSecond())).split("\\R");
}
public int getMinOutputPerSecond() {
@@ -109,29 +113,21 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
for (int color = -1; color < 16; color++) {
int i = color + 1;
short[] colorModulation = Dyes.getModulation(color, Dyes._NULL.mRGBa);
- rTextures[0][i] =
- new ITexture[] {TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_BOTTOM, colorModulation)};
- rTextures[1][i] = new ITexture[] {
- TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_TOP, colorModulation),
- TextureFactory.of(BlockIcons.BOILER_SOLAR)
- };
- rTextures[2][i] = new ITexture[] {TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_SIDE, colorModulation)};
- rTextures[3][i] = new ITexture[] {
- TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_SIDE, colorModulation),
- TextureFactory.of(BlockIcons.OVERLAY_PIPE)
- };
+ rTextures[0][i] = new ITexture[] {
+ TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_BOTTOM, colorModulation) };
+ rTextures[1][i] = new ITexture[] { TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_TOP, colorModulation),
+ TextureFactory.of(BlockIcons.BOILER_SOLAR) };
+ rTextures[2][i] = new ITexture[] {
+ TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_SIDE, colorModulation) };
+ rTextures[3][i] = new ITexture[] { TextureFactory.of(BlockIcons.MACHINE_BRONZEBRICKS_SIDE, colorModulation),
+ TextureFactory.of(BlockIcons.OVERLAY_PIPE) };
}
return rTextures;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
int i = aColorIndex + 1;
if (aSide >= 2) {
if (aSide != aFacing) return mTextures[2][i];
@@ -187,12 +183,12 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
if (mRunTimeTicks > mConfig.getMaxRuntimeTicks()) {
return mConfig.getMinOutputPerSecond();
} else if (mRunTimeTicks > mConfig.getCalcificationTicks()) {
- /* When reaching calcification ticks; discount the proportion of run-time spent on calcification
- * from the maximum output per second, and return this or the minimum output per second
+ /*
+ * When reaching calcification ticks; discount the proportion of run-time spent on calcification from the
+ * maximum output per second, and return this or the minimum output per second
*/
return mConfig.getMaxOutputPerSecond()
- - mConfig.getMaxOutputPerSecond()
- * (mRunTimeTicks - mConfig.getCalcificationTicks())
+ - mConfig.getMaxOutputPerSecond() * (mRunTimeTicks - mConfig.getCalcificationTicks())
/ mConfig.getCalcificationTicks();
} else {
return mConfig.getMaxOutputPerSecond();
@@ -257,19 +253,32 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
@Override
public String[] getInfoData() {
return String.format(
- "Heat Capacity: " + EnumChatFormatting.GREEN + "%s %%" + EnumChatFormatting.RESET
- + " Hot time: "
- + EnumChatFormatting.RED + "%s s" + EnumChatFormatting.RESET + "%n" + "Min output: "
- + EnumChatFormatting.RED + LPS_FMT + EnumChatFormatting.RESET + " Max output: "
- + EnumChatFormatting.RED + LPS_FMT + EnumChatFormatting.RESET + "%n"
- + "Current Output: "
- + EnumChatFormatting.YELLOW + LPS_FMT + EnumChatFormatting.RESET,
- GT_Utility.formatNumbers(getHeatCapacityPercent()),
- GT_Utility.formatNumbers(getHotTimeSeconds()),
- GT_Utility.formatNumbers(getMinOutputPerSecond()),
- GT_Utility.formatNumbers(getMaxOutputPerSecond()),
- GT_Utility.formatNumbers(getProductionPerSecond()))
- .split("\\R");
+ "Heat Capacity: " + EnumChatFormatting.GREEN
+ + "%s %%"
+ + EnumChatFormatting.RESET
+ + " Hot time: "
+ + EnumChatFormatting.RED
+ + "%s s"
+ + EnumChatFormatting.RESET
+ + "%n"
+ + "Min output: "
+ + EnumChatFormatting.RED
+ + LPS_FMT
+ + EnumChatFormatting.RESET
+ + " Max output: "
+ + EnumChatFormatting.RED
+ + LPS_FMT
+ + EnumChatFormatting.RESET
+ + "%n"
+ + "Current Output: "
+ + EnumChatFormatting.YELLOW
+ + LPS_FMT
+ + EnumChatFormatting.RESET,
+ GT_Utility.formatNumbers(getHeatCapacityPercent()),
+ GT_Utility.formatNumbers(getHotTimeSeconds()),
+ GT_Utility.formatNumbers(getMinOutputPerSecond()),
+ GT_Utility.formatNumbers(getMaxOutputPerSecond()),
+ GT_Utility.formatNumbers(getProductionPerSecond())).split("\\R");
}
public int getHeatCapacityPercent() {
@@ -287,12 +296,12 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
@Override
protected IDrawable[] getFuelSlotBackground() {
- return new IDrawable[] {GT_UITextures.TRANSPARENT};
+ return new IDrawable[] { GT_UITextures.TRANSPARENT };
}
@Override
protected IDrawable[] getAshSlotBackground() {
- return new IDrawable[] {GT_UITextures.TRANSPARENT};
+ return new IDrawable[] { GT_UITextures.TRANSPARENT };
}
@Override
@@ -308,38 +317,36 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
}
@Override
- public void getWailaBody(
- ItemStack itemStack, List<String> currentTip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
+ public void getWailaBody(ItemStack itemStack, List<String> currentTip, IWailaDataAccessor accessor,
+ IWailaConfigHandler config) {
final NBTTagCompound tag = accessor.getNBTData();
- currentTip.add(String.format(
- (GOLD + "Solar Boiler Output: " + RESET + "%d/%d L/s"),
- tag.getInteger("calcificationOutput"),
- tag.getInteger("maxCalcificationOutput")));
+ currentTip.add(
+ String.format(
+ (GOLD + "Solar Boiler Output: " + RESET + "%d/%d L/s"),
+ tag.getInteger("calcificationOutput"),
+ tag.getInteger("maxCalcificationOutput")));
super.getWailaBody(itemStack, currentTip, accessor, config);
}
@Override
- public void getWailaNBTData(
- EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y, int z) {
+ public void getWailaNBTData(EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y,
+ int z) {
super.getWailaNBTData(player, tile, tag, world, x, y, z);
tag.setInteger("calcificationOutput", (getProductionPerSecond()));
tag.setInteger("maxCalcificationOutput", (getMaxOutputPerSecond()));
}
protected static class Config {
+
private final int calcificationTicks;
private final int minOutputPerSecond;
private final int maxOutputPerSecond;
private final int coolDownTicks;
private final int maxRuntimeTicks;
- public Config(
- String aCategory,
- int aDefaultCalcificationTicks,
- int aDefaultMinOutputPerSecond,
- int aDefaultMaxOutputPerSecond,
- int aDefaultCoolDownTicks) {
+ public Config(String aCategory, int aDefaultCalcificationTicks, int aDefaultMinOutputPerSecond,
+ int aDefaultMaxOutputPerSecond, int aDefaultCoolDownTicks) {
calcificationTicks = get(
aCategory,
"CalcificationTicks",
@@ -348,24 +355,22 @@ public class GT_MetaTileEntity_Boiler_Solar extends GT_MetaTileEntity_Boiler {
"100% calcification and minimal output will be reached at 2 times this.");
minOutputPerSecond = get(aCategory, "MinOutputPerSecond", aDefaultMinOutputPerSecond);
maxOutputPerSecond = get(aCategory, "MaxOutputPerSecond", aDefaultMaxOutputPerSecond);
- coolDownTicks =
- get(aCategory, "CoolDownTicks", aDefaultCoolDownTicks, "Number of ticks it takes to lose 1°C.");
+ coolDownTicks = get(
+ aCategory,
+ "CoolDownTicks",
+ aDefaultCoolDownTicks,
+ "Number of ticks it takes to lose 1°C.");
// After which min output is reached.
- maxRuntimeTicks = (getMaxOutputPerSecond() - getMinOutputPerSecond())
- * getCalcificationTicks()
- / getMaxOutputPerSecond()
- + getCalcificationTicks();
+ maxRuntimeTicks = (getMaxOutputPerSecond() - getMinOutputPerSecond()) * getCalcificationTicks()
+ / getMaxOutputPerSecond() + getCalcificationTicks();
}
- protected int get(
- final String aCategory, final String aKey, final int aDefaultValue, final String... aComments) {
+ protected int get(final String aCategory, final String aKey, final int aDefaultValue,
+ final String... aComments) {
final StringBuilder tCommentBuilder = new StringBuilder();
for (String tComment : aComments) tCommentBuilder.append(tComment).append('\n');
tCommentBuilder.append("Default: ").append(aDefaultValue);
- return sMachineFile
- .mConfig
- .get(aCategory, aKey, aDefaultValue, tCommentBuilder.toString())
- .getInt();
+ return sMachineFile.mConfig.get(aCategory, aKey, aDefaultValue, tCommentBuilder.toString()).getInt();
}
public int getCalcificationTicks() {
diff --git a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar_Steel.java b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar_Steel.java
index 997ca33df5..45e22c29fb 100644
--- a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Solar_Steel.java
@@ -11,22 +11,23 @@ import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_Boiler_Solar_Steel extends GT_MetaTileEntity_Boiler_Solar {
+
public GT_MetaTileEntity_Boiler_Solar_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
- public GT_MetaTileEntity_Boiler_Solar_Steel(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Boiler_Solar_Steel(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
- public GT_MetaTileEntity_Boiler_Solar_Steel(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Boiler_Solar_Steel(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
- public GT_MetaTileEntity_Boiler_Solar_Steel(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures, Config aConfig) {
+ public GT_MetaTileEntity_Boiler_Solar_Steel(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures, Config aConfig) {
super(aName, aTier, aDescription, aTextures, aConfig);
}
@@ -42,17 +43,14 @@ public class GT_MetaTileEntity_Boiler_Solar_Steel extends GT_MetaTileEntity_Boil
for (int color = -1; color < 16; color++) {
int i = color + 1;
short[] colorModulation = Dyes.getModulation(color, Dyes._NULL.mRGBa);
- rTextures[0][i] =
- new ITexture[] {TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_BOTTOM, colorModulation)};
- rTextures[1][i] = new ITexture[] {
- TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_TOP, colorModulation),
- TextureFactory.of(BlockIcons.BOILER_SOLAR)
- };
- rTextures[2][i] = new ITexture[] {TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_SIDE, colorModulation)};
- rTextures[3][i] = new ITexture[] {
- TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_SIDE, colorModulation),
- TextureFactory.of(BlockIcons.OVERLAY_PIPE)
- };
+ rTextures[0][i] = new ITexture[] {
+ TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_BOTTOM, colorModulation) };
+ rTextures[1][i] = new ITexture[] { TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_TOP, colorModulation),
+ TextureFactory.of(BlockIcons.BOILER_SOLAR) };
+ rTextures[2][i] = new ITexture[] {
+ TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_SIDE, colorModulation) };
+ rTextures[3][i] = new ITexture[] { TextureFactory.of(BlockIcons.MACHINE_STEELBRICKS_SIDE, colorModulation),
+ TextureFactory.of(BlockIcons.OVERLAY_PIPE) };
}
return rTextures;
}
@@ -70,6 +68,10 @@ public class GT_MetaTileEntity_Boiler_Solar_Steel extends GT_MetaTileEntity_Boil
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Boiler_Solar_Steel(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mConfig);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mConfig);
}
}
diff --git a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Steel.java b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Steel.java
index 0ae425f792..719fd13317 100644
--- a/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/boilers/GT_MetaTileEntity_Boiler_Steel.java
@@ -19,12 +19,13 @@ import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_Boiler_Steel extends GT_MetaTileEntity_Boiler_Bronze {
public GT_MetaTileEntity_Boiler_Steel(int aID, String aName, String aNameRegional) {
- super(aID, aName, aNameRegional, new String[] {
- "Faster than the Bronze Boiler",
- "Produces 300L of Steam per second",
- "Causes " + Integer.toString(GT_Mod.gregtechproxy.mPollutionHighPressureCoalBoilerPerSecond)
- + " Pollution per second"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ new String[] { "Faster than the Bronze Boiler", "Produces 300L of Steam per second",
+ "Causes " + Integer.toString(GT_Mod.gregtechproxy.mPollutionHighPressureCoalBoilerPerSecond)
+ + " Pollution per second" });
}
public GT_MetaTileEntity_Boiler_Steel(String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
@@ -38,27 +39,13 @@ public class GT_MetaTileEntity_Boiler_Steel extends GT_MetaTileEntity_Boiler_Bro
@Override
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[5][17][];
- final ITexture[] texBottom = {TextureFactory.of(MACHINE_STEELBRICKS_BOTTOM)},
- texTop = {TextureFactory.of(MACHINE_STEELBRICKS_TOP), TextureFactory.of(OVERLAY_PIPE)},
- texSide = {TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(OVERLAY_PIPE)},
- texFront =
- {
- TextureFactory.of(MACHINE_STEELBRICKS_SIDE),
- TextureFactory.of(BOILER_FRONT),
- TextureFactory.builder()
- .addIcon(BOILER_FRONT_GLOW)
- .glow()
- .build()
- },
- texFrontActive =
- {
- TextureFactory.of(MACHINE_STEELBRICKS_SIDE),
- TextureFactory.of(BOILER_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(BOILER_FRONT_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ final ITexture[] texBottom = { TextureFactory.of(MACHINE_STEELBRICKS_BOTTOM) },
+ texTop = { TextureFactory.of(MACHINE_STEELBRICKS_TOP), TextureFactory.of(OVERLAY_PIPE) },
+ texSide = { TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(OVERLAY_PIPE) },
+ texFront = { TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(BOILER_FRONT),
+ TextureFactory.builder().addIcon(BOILER_FRONT_GLOW).glow().build() },
+ texFrontActive = { TextureFactory.of(MACHINE_STEELBRICKS_SIDE), TextureFactory.of(BOILER_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(BOILER_FRONT_ACTIVE_GLOW).glow().build() };
for (int i = 0; i < 17; i++) {
rTextures[0][i] = texBottom;
rTextures[1][i] = texTop;
diff --git a/src/main/java/gregtech/common/tileentities/debug/GT_MetaTileEntity_AdvDebugStructureWriter.java b/src/main/java/gregtech/common/tileentities/debug/GT_MetaTileEntity_AdvDebugStructureWriter.java
index 663b7ed326..fbc2e4af14 100644
--- a/src/main/java/gregtech/common/tileentities/debug/GT_MetaTileEntity_AdvDebugStructureWriter.java
+++ b/src/main/java/gregtech/common/tileentities/debug/GT_MetaTileEntity_AdvDebugStructureWriter.java
@@ -3,6 +3,20 @@ package gregtech.common.tileentities.debug;
import static gregtech.GT_Mod.GT_FML_LOGGER;
import static net.minecraft.util.StatCollector.translateToLocal;
+import java.util.HashMap;
+
+import net.minecraft.client.Minecraft;
+import net.minecraft.client.entity.EntityPlayerSP;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.ChatComponentTranslation;
+import net.minecraftforge.client.event.RenderWorldLastEvent;
+import net.minecraftforge.common.MinecraftForge;
+import net.minecraftforge.common.util.ForgeDirection;
+
+import org.lwjgl.opengl.GL11;
+
import com.gtnewhorizon.structurelib.alignment.enumerable.ExtendedFacing;
import com.gtnewhorizon.structurelib.structure.StructureUtility;
import com.gtnewhorizon.structurelib.util.Vec3Impl;
@@ -14,6 +28,7 @@ import com.gtnewhorizons.modularui.common.widget.CycleButtonWidget;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.MultiChildWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@@ -28,34 +43,24 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_TieredMachineBlock;
import gregtech.api.render.TextureFactory;
-import java.util.HashMap;
-import net.minecraft.client.Minecraft;
-import net.minecraft.client.entity.EntityPlayerSP;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.ChatComponentTranslation;
-import net.minecraftforge.client.event.RenderWorldLastEvent;
-import net.minecraftforge.common.MinecraftForge;
-import net.minecraftforge.common.util.ForgeDirection;
-import org.lwjgl.opengl.GL11;
public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity_TieredMachineBlock
implements IAddGregtechLogo, IAddUIWidgets {
- private static final HashMap<GT_MetaTileEntity_AdvDebugStructureWriter, BoundHighlighter> bondingBoxes =
- new HashMap<>(1);
+
+ private static final HashMap<GT_MetaTileEntity_AdvDebugStructureWriter, BoundHighlighter> bondingBoxes = new HashMap<>(
+ 1);
private final BoundHighlighter boundingBox = new BoundHighlighter();
private final short[] numbers = new short[6];
private boolean transpose = false;
private boolean showHighlightBox = true;
- private String[] result = new String[] {"Undefined"};
+ private String[] result = new String[] { "Undefined" };
public GT_MetaTileEntity_AdvDebugStructureWriter(int aID, String aName, String aNameRegional, int aTier) {
super(aID, aName, aNameRegional, aTier, 0, "");
}
- public GT_MetaTileEntity_AdvDebugStructureWriter(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_AdvDebugStructureWriter(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, 0, aDescription, aTextures);
}
@@ -65,25 +70,13 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- Textures.BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
- aSide != aFacing
- ? TextureFactory.of(TextureFactory.builder()
- .addIcon(Textures.BlockIcons.OVERLAY_TELEPORTER_ACTIVE)
- .glow()
- .build())
- : TextureFactory.of(TextureFactory.builder()
- .addIcon(Textures.BlockIcons.STRUCTURE_MARK)
- .glow()
- .build())
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { Textures.BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
+ aSide != aFacing ? TextureFactory.of(
+ TextureFactory.builder().addIcon(Textures.BlockIcons.OVERLAY_TELEPORTER_ACTIVE).glow().build())
+ : TextureFactory.of(
+ TextureFactory.builder().addIcon(Textures.BlockIcons.STRUCTURE_MARK).glow().build()) };
}
@Override
@@ -133,8 +126,8 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
@Override
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
if (aBaseMetaTileEntity.isServerSide()) {
- ExtendedFacing writerFacing =
- ExtendedFacing.of(ForgeDirection.getOrientation(aBaseMetaTileEntity.getFrontFacing()));
+ ExtendedFacing writerFacing = ExtendedFacing
+ .of(ForgeDirection.getOrientation(aBaseMetaTileEntity.getFrontFacing()));
double[] abc = new double[3];
double[] xyz = new double[3];
boundingBox.dim = aBaseMetaTileEntity.getWorld().provider.dimensionId;
@@ -215,11 +208,10 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
@Override
public String[] getDescription() {
- return new String[] {
- translateToLocal("GT5U.machines.advdebugstructurewriter.tooltip"), // Scans Blocks Around
- translateToLocal(
- "GT5U.machines.advdebugstructurewriter.tooltip.1"), // Prints Multiblock NonTE structure check code
- translateToLocal("GT5U.machines.advdebugstructurewriter.tooltip.2") // ABC axes aligned to machine front
+ return new String[] { translateToLocal("GT5U.machines.advdebugstructurewriter.tooltip"), // Scans Blocks Around
+ translateToLocal("GT5U.machines.advdebugstructurewriter.tooltip.1"), // Prints Multiblock NonTE
+ // structure check code
+ translateToLocal("GT5U.machines.advdebugstructurewriter.tooltip.2") // ABC axes aligned to machine front
};
}
@@ -240,76 +232,73 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK)
- .setSize(90, 112)
- .setPos(43, 4))
- .widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> {
- if (getBaseMetaTileEntity().isServerSide()) {
- printStructure(widget.getContext().getPlayer());
- }
- })
- .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_PRINT)
- .setSize(18, 18)
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK).setSize(90, 112).setPos(43, 4))
+ .widget(new ButtonWidget().setOnClick((clickData, widget) -> {
+ if (getBaseMetaTileEntity().isServerSide()) {
+ printStructure(widget.getContext().getPlayer());
+ }
+ }).setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_PRINT).setSize(18, 18)
.setPos(11, 128)
.addTooltip(translateToLocal("GT5U.machines.advdebugstructurewriter.gui.print.tooltip")))
- .widget(new CycleButtonWidget()
- .setToggle(() -> transpose, aBoolean -> transpose = aBoolean)
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
- .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_TRANSPOSE)
- .setSize(18, 18)
- .setPos(32, 128)
- .addTooltip(translateToLocal("GT5U.machines.advdebugstructurewriter.gui.transpose.tooltip")))
- .widget(new CycleButtonWidget()
- .setToggle(() -> showHighlightBox, aBoolean -> showHighlightBox = aBoolean)
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
- .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BOUNDING_BOX)
- .setSize(18, 18)
- .setPos(53, 128)
- .addTooltip(translateToLocal("GT5U.machines.advdebugstructurewriter.gui.highlight.tooltip")))
- .widget(new MultiChildWidget()
- .addChild(new TextWidget(translateToLocal("GT5U.machines.advdebugstructurewriter.gui.origin"))
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 0))
- .addChild(TextWidget.dynamicString(() -> "A: " + numbers[0])
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 10))
- .addChild(TextWidget.dynamicString(() -> "B: " + numbers[1])
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 18))
- .addChild(TextWidget.dynamicString(() -> "C: " + numbers[2])
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 26))
- .addChild(new TextWidget(translateToLocal("GT5U.machines.advdebugstructurewriter.gui.size"))
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 52))
- .addChild(TextWidget.dynamicString(() -> "A: " + numbers[3])
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 62))
- .addChild(TextWidget.dynamicString(() -> "B: " + numbers[4])
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 70))
- .addChild(TextWidget.dynamicString(() -> "C: " + numbers[5])
- .setDefaultColor(0xf0f0ff)
- .setPos(0, 78))
- .setPos(46, 8));
+ .widget(
+ new CycleButtonWidget().setToggle(() -> transpose, aBoolean -> transpose = aBoolean)
+ .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_TRANSPOSE).setSize(18, 18)
+ .setPos(32, 128).addTooltip(
+ translateToLocal(
+ "GT5U.machines.advdebugstructurewriter.gui.transpose.tooltip")))
+ .widget(
+ new CycleButtonWidget()
+ .setToggle(() -> showHighlightBox, aBoolean -> showHighlightBox = aBoolean)
+ .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setStaticTexture(GT_UITextures.OVERLAY_BUTTON_BOUNDING_BOX).setSize(18, 18)
+ .setPos(53, 128).addTooltip(
+ translateToLocal(
+ "GT5U.machines.advdebugstructurewriter.gui.highlight.tooltip")))
+ .widget(
+ new MultiChildWidget().addChild(
+ new TextWidget(translateToLocal("GT5U.machines.advdebugstructurewriter.gui.origin"))
+ .setDefaultColor(0xf0f0ff).setPos(0, 0))
+ .addChild(
+ TextWidget.dynamicString(() -> "A: " + numbers[0]).setDefaultColor(0xf0f0ff)
+ .setPos(0, 10))
+ .addChild(
+ TextWidget.dynamicString(() -> "B: " + numbers[1]).setDefaultColor(0xf0f0ff)
+ .setPos(0, 18))
+ .addChild(
+ TextWidget.dynamicString(() -> "C: " + numbers[2]).setDefaultColor(0xf0f0ff)
+ .setPos(0, 26))
+ .addChild(
+ new TextWidget(
+ translateToLocal("GT5U.machines.advdebugstructurewriter.gui.size"))
+ .setDefaultColor(0xf0f0ff).setPos(0, 52))
+ .addChild(
+ TextWidget.dynamicString(() -> "A: " + numbers[3]).setDefaultColor(0xf0f0ff)
+ .setPos(0, 62))
+ .addChild(
+ TextWidget.dynamicString(() -> "B: " + numbers[4]).setDefaultColor(0xf0f0ff)
+ .setPos(0, 70))
+ .addChild(
+ TextWidget.dynamicString(() -> "C: " + numbers[5]).setDefaultColor(0xf0f0ff)
+ .setPos(0, 78))
+ .setPos(46, 8));
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE, -512, -64, 7);
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_MINUS_SMALL, -16, -1, 25);
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_SMALL, 16, 1, 133);
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_LARGE, 512, 64, 151);
}
- private void addChangeNumberButtons(
- ModularWindow.Builder builder, IDrawable overlay, int addNumberShift, int addNumber, int xPos) {
- int[] yPos = new int[] {4, 22, 40, 62, 80, 98};
+ private void addChangeNumberButtons(ModularWindow.Builder builder, IDrawable overlay, int addNumberShift,
+ int addNumber, int xPos) {
+ int[] yPos = new int[] { 4, 22, 40, 62, 80, 98 };
for (int i = 0; i < yPos.length; i++) {
final int index = i; // needed for lambda
- builder.widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> numbers[index] += clickData.shift ? addNumberShift : addNumber)
- .setBackground(GT_UITextures.BUTTON_STANDARD, overlay)
- .setSize(18, 18)
- .setPos(xPos, yPos[index]));
+ builder.widget(
+ new ButtonWidget().setOnClick(
+ (clickData, widget) -> numbers[index] += clickData.shift ? addNumberShift : addNumber)
+ .setBackground(GT_UITextures.BUTTON_STANDARD, overlay).setSize(18, 18)
+ .setPos(xPos, yPos[index]));
}
}
@@ -320,10 +309,8 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
@Override
public void addGregTechLogo(ModularWindow.Builder builder) {
- builder.widget(new DrawableWidget()
- .setDrawable(getGUITextureSet().getGregTechLogo())
- .setSize(17, 17)
- .setPos(113, 96));
+ builder.widget(
+ new DrawableWidget().setDrawable(getGUITextureSet().getGregTechLogo()).setSize(17, 17).setPos(113, 96));
}
@Override
@@ -332,6 +319,7 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
}
public static class ForgeEventHandler {
+
public ForgeEventHandler() {
MinecraftForge.EVENT_BUS.register(this);
}
@@ -347,6 +335,7 @@ public class GT_MetaTileEntity_AdvDebugStructureWriter extends GT_MetaTileEntity
}
private static class BoundHighlighter {
+
public Vec3Impl pos1;
public Vec3Impl pos2;
public boolean showHighlightBox;
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_DieselGenerator.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_DieselGenerator.java
index 1b53de5b42..d2304cc948 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_DieselGenerator.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_DieselGenerator.java
@@ -3,6 +3,10 @@ package gregtech.common.tileentities.generators;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+
import cpw.mods.fml.common.registry.GameRegistry;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@@ -20,22 +24,22 @@ import gregtech.api.util.GT_Log;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_DieselGenerator extends GT_MetaTileEntity_BasicGenerator {
public int mEfficiency;
public GT_MetaTileEntity_DieselGenerator(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, new String[] {
- "Requires liquid Fuel",
- "Causes "
- + (int) (GT_Mod.gregtechproxy.mPollutionBaseDieselGeneratorPerSecond
- * GT_Mod.gregtechproxy.mPollutionDieselGeneratorReleasedByTier[aTier])
- + " Pollution per second"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ new String[] { "Requires liquid Fuel",
+ "Causes "
+ + (int) (GT_Mod.gregtechproxy.mPollutionBaseDieselGeneratorPerSecond
+ * GT_Mod.gregtechproxy.mPollutionDieselGeneratorReleasedByTier[aTier])
+ + " Pollution per second" });
onConfigLoad();
}
@@ -98,8 +102,13 @@ public class GT_MetaTileEntity_DieselGenerator extends GT_MetaTileEntity_BasicGe
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
if (aTick % 100 == 0 && mFluid != null && mFluid.amount > this.getCapacity()) {
GT_Log.err.println(
- "Dupe Abuse: " + aBaseMetaTileEntity.getOwnerName() + " Coords: " + aBaseMetaTileEntity.getXCoord()
- + " " + aBaseMetaTileEntity.getYCoord() + " " + aBaseMetaTileEntity.getZCoord());
+ "Dupe Abuse: " + aBaseMetaTileEntity.getOwnerName()
+ + " Coords: "
+ + aBaseMetaTileEntity.getXCoord()
+ + " "
+ + aBaseMetaTileEntity.getYCoord()
+ + " "
+ + aBaseMetaTileEntity.getZCoord());
aBaseMetaTileEntity.setToFire();
}
super.onPostTick(aBaseMetaTileEntity, aTick);
@@ -120,152 +129,98 @@ public class GT_MetaTileEntity_DieselGenerator extends GT_MetaTileEntity_BasicGe
if (aBaseMetaTileEntity.getCoverIDAtSide(topFacing) == 0
&& !aBaseMetaTileEntity.getOpacityAtSide(topFacing)) {
- final double x =
- aBaseMetaTileEntity.getOffsetX(topFacing, 1) + 2D / 16D + XSTR_INSTANCE.nextFloat() * 14D / 16D;
+ final double x = aBaseMetaTileEntity.getOffsetX(topFacing, 1) + 2D / 16D
+ + XSTR_INSTANCE.nextFloat() * 14D / 16D;
final double y = aBaseMetaTileEntity.getOffsetY(topFacing, 1) + 1D / 32D;
- final double z =
- aBaseMetaTileEntity.getOffsetZ(topFacing, 1) + 2D / 16D + XSTR_INSTANCE.nextFloat() * 14D / 16D;
-
- new ParticleEventBuilder()
- .setMotion(0D, 0D, 0D)
- .setPosition(x, y, z)
- .setWorld(getBaseMetaTileEntity().getWorld())
- .setIdentifier(ParticleFX.SMOKE)
- .run();
+ final double z = aBaseMetaTileEntity.getOffsetZ(topFacing, 1) + 2D / 16D
+ + XSTR_INSTANCE.nextFloat() * 14D / 16D;
+
+ new ParticleEventBuilder().setMotion(0D, 0D, 0D).setPosition(x, y, z)
+ .setWorld(getBaseMetaTileEntity().getWorld()).setIdentifier(ParticleFX.SMOKE).run();
}
}
}
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_FRONT),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_FRONT_GLOW)
- .glow()
- .build()),
- OVERLAYS_ENERGY_OUT[this.mTier]
- };
+ return new ITexture[] { super.getFront(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_FRONT),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_FRONT_GLOW).glow().build()),
+ OVERLAYS_ENERGY_OUT[this.mTier] };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {
- super.getBack(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_BACK),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_BACK_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBack(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_BACK),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_BACK_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {
- super.getBottom(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_BOTTOM),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_BOTTOM_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottom(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_BOTTOM),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_BOTTOM_GLOW).glow().build()) };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {
- super.getTop(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_TOP),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_TOP_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTop(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_TOP),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_TOP_GLOW).glow().build()) };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {
- super.getSides(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_SIDE),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_SIDE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSides(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_SIDE),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_SIDE_GLOW).glow().build()) };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_FRONT_ACTIVE_GLOW)
- .glow()
- .build()),
- OVERLAYS_ENERGY_OUT[this.mTier]
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_FRONT_ACTIVE_GLOW).glow().build()),
+ OVERLAYS_ENERGY_OUT[this.mTier] };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_BACK_ACTIVE),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_BACK_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBackActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_BACK_ACTIVE),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_BACK_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_BOTTOM_ACTIVE),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_BOTTOM_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_BOTTOM_ACTIVE),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_BOTTOM_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_TOP_ACTIVE),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_TOP_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTopActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_TOP_ACTIVE),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_TOP_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(DIESEL_GENERATOR_SIDE_ACTIVE),
- TextureFactory.builder()
- .addIcon(DIESEL_GENERATOR_SIDE_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(DIESEL_GENERATOR_SIDE_ACTIVE),
+ TextureFactory.builder().addIcon(DIESEL_GENERATOR_SIDE_ACTIVE_GLOW).glow().build()) };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_GasTurbine.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_GasTurbine.java
index b085d82bab..90b076abaa 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_GasTurbine.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_GasTurbine.java
@@ -18,25 +18,31 @@ public class GT_MetaTileEntity_GasTurbine extends GT_MetaTileEntity_BasicGenerat
@Deprecated
public GT_MetaTileEntity_GasTurbine(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, new String[] {
- "Requires flammable Gasses",
- "Causes "
- + (int) (GT_Mod.gregtechproxy.mPollutionBaseGasTurbinePerSecond
- * GT_Mod.gregtechproxy.mPollutionGasTurbineReleasedByTier[aTier])
- + " Pollution per second"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ new String[] { "Requires flammable Gasses",
+ "Causes "
+ + (int) (GT_Mod.gregtechproxy.mPollutionBaseGasTurbinePerSecond
+ * GT_Mod.gregtechproxy.mPollutionGasTurbineReleasedByTier[aTier])
+ + " Pollution per second" });
this.mEfficiency = 100 - aTier * 5;
onConfigLoad();
}
public GT_MetaTileEntity_GasTurbine(int aID, String aName, String aNameRegional, int aTier, int mEfficiency) {
- super(aID, aName, aNameRegional, aTier, new String[] {
- "Requires flammable Gasses",
- "Causes "
- + (int) (GT_Mod.gregtechproxy.mPollutionBaseGasTurbinePerSecond
- * GT_Mod.gregtechproxy.mPollutionGasTurbineReleasedByTier[aTier])
- + " Pollution per second"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ new String[] { "Requires flammable Gasses",
+ "Causes "
+ + (int) (GT_Mod.gregtechproxy.mPollutionBaseGasTurbinePerSecond
+ * GT_Mod.gregtechproxy.mPollutionGasTurbineReleasedByTier[aTier])
+ + " Pollution per second" });
this.mEfficiency = mEfficiency;
onConfigLoad();
}
@@ -55,8 +61,8 @@ public class GT_MetaTileEntity_GasTurbine extends GT_MetaTileEntity_BasicGenerat
onConfigLoad();
}
- public GT_MetaTileEntity_GasTurbine(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures, int mEfficiency) {
+ public GT_MetaTileEntity_GasTurbine(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ int mEfficiency) {
super(aName, aTier, aDescription, aTextures);
this.mEfficiency = mEfficiency;
onConfigLoad();
@@ -70,7 +76,11 @@ public class GT_MetaTileEntity_GasTurbine extends GT_MetaTileEntity_BasicGenerat
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_GasTurbine(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mEfficiency);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mEfficiency);
}
@Override
@@ -84,8 +94,8 @@ public class GT_MetaTileEntity_GasTurbine extends GT_MetaTileEntity_BasicGenerat
}
public void onConfigLoad() {
- this.mEfficiency = GregTech_API.sMachineFile.get(
- ConfigCategories.machineconfig, "GasTurbine.efficiency.tier." + this.mTier, this.mEfficiency);
+ this.mEfficiency = GregTech_API.sMachineFile
+ .get(ConfigCategories.machineconfig, "GasTurbine.efficiency.tier." + this.mTier, this.mEfficiency);
}
@Override
@@ -95,134 +105,84 @@ public class GT_MetaTileEntity_GasTurbine extends GT_MetaTileEntity_BasicGenerat
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_FRONT),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_FRONT_GLOW)
- .glow()
- .build()),
- OVERLAYS_ENERGY_OUT[this.mTier]
- };
+ return new ITexture[] { super.getFront(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_FRONT),
+ TextureFactory.builder().addIcon(GAS_TURBINE_FRONT_GLOW).glow().build()),
+ OVERLAYS_ENERGY_OUT[this.mTier] };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {
- super.getBack(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_BACK),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_BACK_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBack(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_BACK),
+ TextureFactory.builder().addIcon(GAS_TURBINE_BACK_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {
- super.getBottom(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_BOTTOM),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_BOTTOM_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottom(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_BOTTOM),
+ TextureFactory.builder().addIcon(GAS_TURBINE_BOTTOM_GLOW).glow().build()) };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {
- super.getTop(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_TOP),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_TOP_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTop(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_TOP),
+ TextureFactory.builder().addIcon(GAS_TURBINE_TOP_GLOW).glow().build()) };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {
- super.getSides(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_SIDE),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_SIDE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSides(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_SIDE),
+ TextureFactory.builder().addIcon(GAS_TURBINE_SIDE_GLOW).glow().build()) };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_FRONT_ACTIVE_GLOW)
- .glow()
- .build()),
- OVERLAYS_ENERGY_OUT[this.mTier]
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(GAS_TURBINE_FRONT_ACTIVE_GLOW).glow().build()),
+ OVERLAYS_ENERGY_OUT[this.mTier] };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_BACK_ACTIVE),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_BACK_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBackActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_BACK_ACTIVE),
+ TextureFactory.builder().addIcon(GAS_TURBINE_BACK_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_BOTTOM_ACTIVE),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_BOTTOM_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_BOTTOM_ACTIVE),
+ TextureFactory.builder().addIcon(GAS_TURBINE_BOTTOM_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_TOP_ACTIVE),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_TOP_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTopActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_TOP_ACTIVE),
+ TextureFactory.builder().addIcon(GAS_TURBINE_TOP_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(GAS_TURBINE_SIDE_ACTIVE),
- TextureFactory.builder()
- .addIcon(GAS_TURBINE_SIDE_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(GAS_TURBINE_SIDE_ACTIVE),
+ TextureFactory.builder().addIcon(GAS_TURBINE_SIDE_ACTIVE_GLOW).glow().build()) };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_LightningRod.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_LightningRod.java
index dbb8931848..2436beba77 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_LightningRod.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_LightningRod.java
@@ -2,6 +2,13 @@ package gregtech.common.tileentities.generators;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.entity.effect.EntityLightningBolt;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
+
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.Textures.BlockIcons;
import gregtech.api.interfaces.ITexture;
@@ -9,54 +16,35 @@ import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_TieredMachineBlock;
import gregtech.api.render.TextureFactory;
-import net.minecraft.entity.effect.EntityLightningBolt;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_LightningRod extends GT_MetaTileEntity_TieredMachineBlock {
+
public GT_MetaTileEntity_LightningRod(int aID, String aName, String aNameRegional, int aTier) {
super(aID, aName, aNameRegional, aTier, 0, "Generates EU From Lightning Bolts");
}
- public GT_MetaTileEntity_LightningRod(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_LightningRod(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_LightningRod(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_LightningRod(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide != ForgeDirection.UP.ordinal()) {
- return new ITexture[] {
- BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1], BlockIcons.OVERLAYS_ENERGY_OUT_POWER[mTier]
- };
+ return new ITexture[] { BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
+ BlockIcons.OVERLAYS_ENERGY_OUT_POWER[mTier] };
}
- if (!aActive)
- return new ITexture[] {
- BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(BlockIcons.MACHINE_CASING_FUSION_GLASS)
- };
- return new ITexture[] {
- BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW),
- TextureFactory.builder()
- .addIcon(BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .glow()
- .build()
- };
+ if (!aActive) return new ITexture[] { BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
+ TextureFactory.of(BlockIcons.MACHINE_CASING_FUSION_GLASS) };
+ return new ITexture[] { BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
+ TextureFactory.of(BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW),
+ TextureFactory.builder().addIcon(BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).glow().build() };
}
@Override
@@ -67,7 +55,11 @@ public class GT_MetaTileEntity_LightningRod extends GT_MetaTileEntity_TieredMach
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_LightningRod(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
@@ -90,10 +82,7 @@ public class GT_MetaTileEntity_LightningRod extends GT_MetaTileEntity_TieredMach
for (int i = aBaseMetaTileEntity.getYCoord() + 1; i < aWorld.getHeight() - 1; i++) {
if (isRodValid
- && aBaseMetaTileEntity
- .getBlock(aX, i, aZ)
- .getUnlocalizedName()
- .equals("blockFenceIron")) {
+ && aBaseMetaTileEntity.getBlock(aX, i, aZ).getUnlocalizedName().equals("blockFenceIron")) {
aRodValue++;
} else {
isRodValid = false;
@@ -105,8 +94,8 @@ public class GT_MetaTileEntity_LightningRod extends GT_MetaTileEntity_TieredMach
}
if (!aWorld.isThundering() && ((aY + aRodValue) < 128)) aRodValue = 0;
if (XSTR_INSTANCE.nextInt(4 * aWorld.getHeight()) < (aRodValue * (aY + aRodValue))) {
- aBaseMetaTileEntity.increaseStoredEnergyUnits(
- maxEUStore() - aBaseMetaTileEntity.getStoredEU(), false);
+ aBaseMetaTileEntity
+ .increaseStoredEnergyUnits(maxEUStore() - aBaseMetaTileEntity.getStoredEU(), false);
aWorld.addWeatherEffect(new EntityLightningBolt(aWorld, aX, aY + aRodValue, aZ));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicEnergyConverter.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicEnergyConverter.java
index 2e1bfd655f..6bc904d384 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicEnergyConverter.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicEnergyConverter.java
@@ -20,6 +20,7 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Recipe;
public class GT_MetaTileEntity_MagicEnergyConverter extends GT_MetaTileEntity_BasicGenerator {
+
public int mEfficiency;
public GT_MetaTileEntity_MagicEnergyConverter(int aID, String aName, String aNameRegional, int aTier) {
@@ -27,14 +28,14 @@ public class GT_MetaTileEntity_MagicEnergyConverter extends GT_MetaTileEntity_Ba
onConfigLoad();
}
- public GT_MetaTileEntity_MagicEnergyConverter(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_MagicEnergyConverter(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
onConfigLoad();
}
- public GT_MetaTileEntity_MagicEnergyConverter(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_MagicEnergyConverter(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
onConfigLoad();
}
@@ -47,7 +48,10 @@ public class GT_MetaTileEntity_MagicEnergyConverter extends GT_MetaTileEntity_Ba
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_MagicEnergyConverter(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
@@ -74,112 +78,64 @@ public class GT_MetaTileEntity_MagicEnergyConverter extends GT_MetaTileEntity_Ba
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build(),
- OVERLAYS_ENERGY_OUT[mTier]
- };
+ return new ITexture[] { super.getFront(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build(),
+ OVERLAYS_ENERGY_OUT[mTier] };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {
- super.getBack(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_FRONT),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_FRONT_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBack(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_FRONT),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_FRONT_GLOW).glow().build() };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {
- super.getBottom(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build()
- };
+ return new ITexture[] { super.getBottom(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build() };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {
- super.getTop(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build()
- };
+ return new ITexture[] { super.getTop(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build() };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {
- super.getSides(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build()
- };
+ return new ITexture[] { super.getSides(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build(),
- OVERLAYS_ENERGY_OUT[mTier]
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build(),
+ OVERLAYS_ENERGY_OUT[mTier] };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_FRONT_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBackActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_FRONT_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build() };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicalEnergyAbsorber.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicalEnergyAbsorber.java
index 210483cbe8..c92cf8b699 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicalEnergyAbsorber.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_MagicalEnergyAbsorber.java
@@ -12,24 +12,6 @@ import static net.minecraft.util.EnumChatFormatting.RESET;
import static net.minecraft.util.EnumChatFormatting.UNDERLINE;
import static net.minecraft.util.EnumChatFormatting.YELLOW;
-import com.google.common.base.Enums;
-import cpw.mods.fml.common.Loader;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.ParticleFX;
-import gregtech.api.enums.TC_Aspects;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.metatileentity.MetaTileEntity;
-import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicGenerator;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_Config;
-import gregtech.api.util.GT_LanguageManager;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_Recipe;
-import gregtech.api.util.GT_Utility;
-import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
@@ -38,6 +20,7 @@ import java.util.Map;
import java.util.Set;
import java.util.UUID;
import java.util.concurrent.ConcurrentHashMap;
+
import net.minecraft.block.Block;
import net.minecraft.block.BlockDragonEgg;
import net.minecraft.enchantment.Enchantment;
@@ -54,13 +37,35 @@ import net.minecraft.util.AxisAlignedBB;
import net.minecraft.world.World;
import net.minecraft.world.chunk.Chunk;
import net.minecraftforge.common.util.ForgeDirection;
+
import thaumcraft.api.aspects.Aspect;
import thaumcraft.api.aspects.AspectList;
import thaumcraft.api.aspects.AspectSourceHelper;
import thaumcraft.api.aspects.IAspectContainer;
import thaumcraft.api.visnet.VisNetHandler;
+import com.google.common.base.Enums;
+
+import cpw.mods.fml.common.Loader;
+import cpw.mods.fml.relauncher.Side;
+import cpw.mods.fml.relauncher.SideOnly;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.ParticleFX;
+import gregtech.api.enums.TC_Aspects;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.metatileentity.MetaTileEntity;
+import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicGenerator;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_Config;
+import gregtech.api.util.GT_LanguageManager;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_Recipe;
+import gregtech.api.util.GT_Utility;
+import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
+
interface MagicalEnergyBBListener {
+
void onMagicalEnergyBBUpdate();
}
@@ -68,10 +73,10 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
implements MagicalEnergyBBListener {
private static final boolean THAUMCRAFT_LOADED = Loader.isModLoaded(MOD_ID_TC);
- private static final ConcurrentHashMap<UUID, GT_MetaTileEntity_MagicalEnergyAbsorber> sSubscribedCrystals =
- new ConcurrentHashMap<>(4);
- private static final List<Aspect> sPrimalAspects =
- (THAUMCRAFT_LOADED) ? Aspect.getPrimalAspects() : new ArrayList<>();
+ private static final ConcurrentHashMap<UUID, GT_MetaTileEntity_MagicalEnergyAbsorber> sSubscribedCrystals = new ConcurrentHashMap<>(
+ 4);
+ private static final List<Aspect> sPrimalAspects = (THAUMCRAFT_LOADED) ? Aspect.getPrimalAspects()
+ : new ArrayList<>();
private static final Map<Aspect, Integer> sAspectsEnergy = new HashMap<>();
private static boolean sAllowMultipleEggs = false;
private static GT_MetaTileEntity_MagicalEnergyAbsorber sActiveSiphon = null;
@@ -92,8 +97,8 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
onConfigLoad(GregTech_API.sMachineFile);
}
- private GT_MetaTileEntity_MagicalEnergyAbsorber(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ private GT_MetaTileEntity_MagicalEnergyAbsorber(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
onConfigLoad(GregTech_API.sMachineFile);
}
@@ -112,13 +117,11 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
sEnergyFromVis = aConfig.get(machineconfig, "MagicEnergyAbsorber.EnergyPerVis", 20);
sEnergyPerEssentia = aConfig.get(machineconfig, "MagicEnergyAbsorber.EnergyPerEssentia", 320);
for (Aspect tAspect : Aspect.aspects.values()) {
- //noinspection UnstableApiUsage
+ // noinspection UnstableApiUsage
sAspectsEnergy.put(
tAspect,
Enums.getIfPresent(TC_Aspects.class, tAspect.getTag().toUpperCase(Locale.ENGLISH))
- .or(TC_Aspects.AER)
- .mValue
- * sEnergyPerEssentia);
+ .or(TC_Aspects.AER).mValue * sEnergyPerEssentia);
}
}
}
@@ -131,8 +134,10 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
public void onConfigLoad(GT_Config aConfig) {
sharedConfigLoad(aConfig);
mEfficiency = aConfig.get(machineconfig, "MagicEnergyAbsorber.efficiency.tier." + mTier, 100 - mTier * 10);
- mMaxVisPerDrain = (int) Math.round(Math.sqrt(
- (double) (V[mTier] * 10000) / (sEnergyFromVis * (getEfficiency() != 0 ? getEfficiency() : 100))));
+ mMaxVisPerDrain = (int) Math.round(
+ Math.sqrt(
+ (double) (V[mTier] * 10000)
+ / (sEnergyFromVis * (getEfficiency() != 0 ? getEfficiency() : 100))));
if (Math.pow(mMaxVisPerDrain, 2) * sEnergyFromVis * (getEfficiency() != 0 ? getEfficiency() : 100) < V[mTier]) {
mMaxVisPerDrain += 1;
}
@@ -203,15 +208,26 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
List<String> description = new ArrayList<>();
description.add(
UNDERLINE + "Feasts on " + LIGHT_PURPLE + UNDERLINE + "magic" + GRAY + UNDERLINE + " close to it:");
- description.add(LI + (sAllowMultipleEggs ? "A " : "An " + YELLOW + UNDERLINE + "EXCLUSIVE" + RESET) + GRAY + " "
- + LIGHT_PURPLE + "Dragon Egg" + GRAY + " atop");
+ description.add(
+ LI + (sAllowMultipleEggs ? "A " : "An " + YELLOW + UNDERLINE + "EXCLUSIVE" + RESET)
+ + GRAY
+ + " "
+ + LIGHT_PURPLE
+ + "Dragon Egg"
+ + GRAY
+ + " atop");
if (sEnergyPerEndercrystal > 0) {
description.add(LI + sEnergyPerEndercrystal + EU_PER + LIGHT_PURPLE + "Ender Crystal" + GRAY + " in range");
}
if (THAUMCRAFT_LOADED) {
description.add(LI + mMaxVisPerDrain + "%%%CV/t from an " + LIGHT_PURPLE + "Energised Node" + GRAY);
- description.add(LI + (sEnergyPerEssentia * getEfficiency()) / 100 + EU_PER + LIGHT_PURPLE + "Essentia"
- + GRAY + " Aspect-Value from containers in range");
+ description.add(
+ LI + (sEnergyPerEssentia * getEfficiency()) / 100
+ + EU_PER
+ + LIGHT_PURPLE
+ + "Essentia"
+ + GRAY
+ + " Aspect-Value from containers in range");
}
description.add(" ");
description.add(UNDERLINE + "Lookup range (Use Screwdriver to change):");
@@ -220,8 +236,13 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
description.add(" ");
description.add(
UNDERLINE + "Fuels on " + LIGHT_PURPLE + UNDERLINE + "enchantments" + GRAY + UNDERLINE + " input:");
- description.add("- Item:%%%" + (10000 * getEfficiency()) / 100 + EU_PER + LIGHT_PURPLE + "enchant" + GRAY
- + " weight × level / max");
+ description.add(
+ "- Item:%%%" + (10000 * getEfficiency()) / 100
+ + EU_PER
+ + LIGHT_PURPLE
+ + "enchant"
+ + GRAY
+ + " weight × level / max");
description.add("- Book:%%%" + 10000 + EU_PER + LIGHT_PURPLE + "enchant" + GRAY + " weight × level / max");
description.add(" ");
description.add("Efficiency:%%%" + GREEN + getEfficiency() + "%");
@@ -230,108 +251,63 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build(),
- OVERLAYS_ENERGY_OUT[mTier]
- };
+ return new ITexture[] { super.getFront(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build(),
+ OVERLAYS_ENERGY_OUT[mTier] };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {
- super.getBack(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_FRONT),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_FRONT_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBack(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_FRONT),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_FRONT_GLOW).glow().build() };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {
- super.getBottom(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build()
- };
+ return new ITexture[] { super.getBottom(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build() };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {super.getTop(aColor)[0], TextureFactory.of(MACHINE_CASING_DRAGONEGG)};
+ return new ITexture[] { super.getTop(aColor)[0], TextureFactory.of(MACHINE_CASING_DRAGONEGG) };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {
- super.getSides(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC),
- TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build()
- };
+ return new ITexture[] { super.getSides(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build(),
- OVERLAYS_ENERGY_OUT[mTier]
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build(),
+ OVERLAYS_ENERGY_OUT[mTier] };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_FRONT_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBackActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_FRONT_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_DRAGONEGG),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_DRAGONEGG_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopActive(aColor)[0], TextureFactory.of(MACHINE_CASING_DRAGONEGG),
+ TextureFactory.builder().addIcon(MACHINE_CASING_DRAGONEGG_GLOW).glow().build() };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0], TextureFactory.of(MACHINE_CASING_MAGIC_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_CASING_MAGIC_ACTIVE_GLOW).glow().build() };
}
@Override
@@ -373,8 +349,9 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
mNextGenerateTickRate = 20;
}
aBaseMetaTileEntity.increaseStoredEnergyUnits(tGeneratedEU, true);
- aBaseMetaTileEntity.setActive(aBaseMetaTileEntity.isAllowedToWork()
- && aBaseMetaTileEntity.getUniversalEnergyStored() >= maxEUOutput() + getMinimumStoredEU());
+ aBaseMetaTileEntity.setActive(
+ aBaseMetaTileEntity.isAllowedToWork()
+ && aBaseMetaTileEntity.getUniversalEnergyStored() >= maxEUOutput() + getMinimumStoredEU());
}
}
@@ -398,8 +375,7 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
final double oZ = aBaseMetaTileEntity.getZCoord() + 8D / 16D;
final ParticleEventBuilder particleEventBuilder = new ParticleEventBuilder()
- .setWorld(getBaseMetaTileEntity().getWorld())
- .setIdentifier(ParticleFX.PORTAL);
+ .setWorld(getBaseMetaTileEntity().getWorld()).setIdentifier(ParticleFX.PORTAL);
for (int i = 0; i < 9; i++) {
final double dX = (XSTR_INSTANCE.nextFloat() - 0.5D) / 2D;
@@ -415,10 +391,7 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
final double mY = -(dXZ * dY) / 4D;
final double mZ = dZ * 4D;
- particleEventBuilder
- .setMotion(mX, mY, mZ)
- .setPosition(x, y, z)
- .run();
+ particleEventBuilder.setMotion(mX, mY, mZ).setPosition(x, y, z).run();
}
}
}
@@ -498,8 +471,7 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
}
// Only consume input when it can store EU and push output
- if ((getBaseMetaTileEntity().getStoredEU() + tEU)
- < getBaseMetaTileEntity().getEUCapacity()
+ if ((getBaseMetaTileEntity().getStoredEU() + tEU) < getBaseMetaTileEntity().getEUCapacity()
&& getBaseMetaTileEntity().addStackToSlot(getOutputSlot(), tOutputStack)) {
decrStackSize(getInputSlot(), 1);
} else {
@@ -516,8 +488,7 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
private long absorbFromEgg() {
if (!hasEgg()) return 0;
if (!sAllowMultipleEggs) {
- if (sActiveSiphon != null
- && sActiveSiphon != this
+ if (sActiveSiphon != null && sActiveSiphon != this
&& sActiveSiphon.getBaseMetaTileEntity() != null
&& !sActiveSiphon.getBaseMetaTileEntity().isInvalidTileEntity()
&& sActiveSiphon.isChunkLoaded()
@@ -575,20 +546,18 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
long tEU = 0;
- long tEUtoGen = getBaseMetaTileEntity().getEUCapacity()
- - getBaseMetaTileEntity().getUniversalEnergyStored();
+ long tEUtoGen = getBaseMetaTileEntity().getEUCapacity() - getBaseMetaTileEntity().getUniversalEnergyStored();
List<Aspect> mAvailableEssentiaAspects = mMagicalEnergyBB.getAvailableAspects();
// try to drain 1 of whatever aspect available in containers within RANGE
for (int i = mAvailableEssentiaAspects.size() - 1; i >= 0 && tEUtoGen > 0; i--) {
Aspect aspect = mAvailableEssentiaAspects.get(i);
long tAspectEU = ((long) sAspectsEnergy.get(aspect) * getEfficiency()) / 100;
- if (tAspectEU <= tEUtoGen
- && AspectSourceHelper.drainEssentia(
- (TileEntity) getBaseMetaTileEntity(),
- aspect,
- ForgeDirection.UNKNOWN,
- mMagicalEnergyBB.getRange())) {
+ if (tAspectEU <= tEUtoGen && AspectSourceHelper.drainEssentia(
+ (TileEntity) getBaseMetaTileEntity(),
+ aspect,
+ ForgeDirection.UNKNOWN,
+ mMagicalEnergyBB.getRange())) {
tEUtoGen -= tAspectEU;
tEU += tAspectEU;
}
@@ -634,6 +603,7 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
* Handles Bounding Box ranged operations for Magic sources
*/
static class MagicalEnergyBB {
+
private final GT_MetaTileEntity_MagicalEnergyAbsorber mAbsorber;
private final MagicalEnergyBBListener mListener;
private final int mDefaultTier;
@@ -709,8 +679,8 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
double tX = tBaseMetaTileEntity.getXCoord();
double tY = tBaseMetaTileEntity.getYCoord();
double tZ = tBaseMetaTileEntity.getZCoord();
- return AxisAlignedBB.getBoundingBox(
- tX - tRange, tY - tRange, tZ - tRange, tX + tRange, tY + tRange, tZ + tRange);
+ return AxisAlignedBB
+ .getBoundingBox(tX - tRange, tY - tRange, tZ - tRange, tX + tRange, tY + tRange, tZ + tRange);
}
private void scanLivingCrystals() {
@@ -788,8 +758,7 @@ public class GT_MetaTileEntity_MagicalEnergyAbsorber extends GT_MetaTileEntity_B
}
/**
- * Change the Bounding Box tier relatively to offset
- * with wrapping at tier limits
+ * Change the Bounding Box tier relatively to offset with wrapping at tier limits
*
* @param aOffset relative tier change
*/
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_NaquadahReactor.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_NaquadahReactor.java
index 6ca6da874f..5fe5107dc4 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_NaquadahReactor.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_NaquadahReactor.java
@@ -15,8 +15,8 @@ public class GT_MetaTileEntity_NaquadahReactor extends GT_MetaTileEntity_BasicGe
private int mEfficiency;
- public GT_MetaTileEntity_NaquadahReactor(
- int aID, String aName, String[] aDescription, String aNameRegional, int aTier) {
+ public GT_MetaTileEntity_NaquadahReactor(int aID, String aName, String[] aDescription, String aNameRegional,
+ int aTier) {
super(aID, aName, aNameRegional, aTier, aDescription);
if (aTier > 8 || aTier < 4) {
new Exception("Tier without Recipe Map!").printStackTrace();
@@ -34,8 +34,7 @@ public class GT_MetaTileEntity_NaquadahReactor extends GT_MetaTileEntity_BasicGe
@Override
public boolean isOutputFacing(byte aSide) {
- return (aSide > 1)
- && (aSide != getBaseMetaTileEntity().getFrontFacing())
+ return (aSide > 1) && (aSide != getBaseMetaTileEntity().getFrontFacing())
&& (aSide != getBaseMetaTileEntity().getBackFacing());
}
@@ -91,133 +90,79 @@ public class GT_MetaTileEntity_NaquadahReactor extends GT_MetaTileEntity_BasicGe
}
public int onConfigLoad() {
- return mEfficiency = GregTech_API.sMachineFile.get(
- ConfigCategories.machineconfig, "SolidNaquadah.efficiency.tier." + mTier, getBaseEff());
+ return mEfficiency = GregTech_API.sMachineFile
+ .get(ConfigCategories.machineconfig, "SolidNaquadah.efficiency.tier." + mTier, getBaseEff());
}
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_FRONT),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_FRONT_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getFront(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(NAQUADAH_REACTOR_SOLID_FRONT),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_FRONT_GLOW).glow().build()) };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {
- super.getBack(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_BACK),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_BACK_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBack(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(NAQUADAH_REACTOR_SOLID_BACK),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_BACK_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {
- super.getBottom(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_BOTTOM),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_BOTTOM_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottom(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(NAQUADAH_REACTOR_SOLID_BOTTOM),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_BOTTOM_GLOW).glow().build()) };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {
- super.getTop(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_TOP),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_TOP_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTop(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(NAQUADAH_REACTOR_SOLID_TOP),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_TOP_GLOW).glow().build()) };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {
- super.getSides(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_SIDE),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_SIDE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSides(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(NAQUADAH_REACTOR_SOLID_SIDE),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_SIDE_GLOW).glow().build()) };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_FRONT_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0], TextureFactory.of(NAQUADAH_REACTOR_SOLID_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_FRONT_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_BACK_ACTIVE),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_BACK_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBackActive(aColor)[0], TextureFactory.of(NAQUADAH_REACTOR_SOLID_BACK_ACTIVE),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_BACK_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_BOTTOM_ACTIVE),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_BOTTOM_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0],
+ TextureFactory.of(NAQUADAH_REACTOR_SOLID_BOTTOM_ACTIVE),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_BOTTOM_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_TOP_ACTIVE),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_TOP_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopActive(aColor)[0], TextureFactory.of(NAQUADAH_REACTOR_SOLID_TOP_ACTIVE),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_TOP_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(NAQUADAH_REACTOR_SOLID_SIDE_ACTIVE),
- TextureFactory.builder()
- .addIcon(NAQUADAH_REACTOR_SOLID_SIDE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0], TextureFactory.of(NAQUADAH_REACTOR_SOLID_SIDE_ACTIVE),
+ TextureFactory.builder().addIcon(NAQUADAH_REACTOR_SOLID_SIDE_ACTIVE_GLOW).glow().build() };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_PlasmaGenerator.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_PlasmaGenerator.java
index 4e0b428fa4..6fbdf73189 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_PlasmaGenerator.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_PlasmaGenerator.java
@@ -35,90 +35,59 @@ public class GT_MetaTileEntity_PlasmaGenerator extends GT_MetaTileEntity_BasicGe
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS), OVERLAYS_ENERGY_OUT[mTier]
- };
+ return new ITexture[] { super.getFront(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS),
+ OVERLAYS_ENERGY_OUT[mTier] };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {super.getBack(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS)};
+ return new ITexture[] { super.getBack(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS) };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {super.getBottom(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS)};
+ return new ITexture[] { super.getBottom(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS) };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {super.getTop(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS)};
+ return new ITexture[] { super.getTop(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS) };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {super.getSides(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS)};
+ return new ITexture[] { super.getSides(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS) };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .glow()
- .build(),
- OVERLAYS_ENERGY_OUT[mTier]
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).glow().build(),
+ OVERLAYS_ENERGY_OUT[mTier] };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBackActive(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).glow().build() };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopActive(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).glow().build() };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0], TextureFactory.of(MACHINE_CASING_FUSION_GLASS_YELLOW),
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).glow().build() };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_SteamTurbine.java b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_SteamTurbine.java
index bec1b90ad1..bf0e913ce7 100644
--- a/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_SteamTurbine.java
+++ b/src/main/java/gregtech/common/tileentities/generators/GT_MetaTileEntity_SteamTurbine.java
@@ -2,6 +2,8 @@ package gregtech.common.tileentities.generators;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.ConfigCategories;
import gregtech.api.interfaces.ITexture;
@@ -11,15 +13,18 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicGenera
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Recipe;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_SteamTurbine extends GT_MetaTileEntity_BasicGenerator {
public int mEfficiency;
public GT_MetaTileEntity_SteamTurbine(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, new String[] {"Converts Steam into EU", "Base rate: 2L of Steam -> 1 EU"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ new String[] { "Converts Steam into EU", "Base rate: 2L of Steam -> 1 EU" });
onConfigLoad();
}
@@ -65,8 +70,8 @@ public class GT_MetaTileEntity_SteamTurbine extends GT_MetaTileEntity_BasicGener
}
public void onConfigLoad() {
- this.mEfficiency = GregTech_API.sMachineFile.get(
- ConfigCategories.machineconfig, "SteamTurbine.efficiency.tier." + this.mTier, 6 + this.mTier);
+ this.mEfficiency = GregTech_API.sMachineFile
+ .get(ConfigCategories.machineconfig, "SteamTurbine.efficiency.tier." + this.mTier, 6 + this.mTier);
}
@Override
@@ -87,134 +92,84 @@ public class GT_MetaTileEntity_SteamTurbine extends GT_MetaTileEntity_BasicGener
@Override
public ITexture[] getFront(byte aColor) {
- return new ITexture[] {
- super.getFront(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_FRONT),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_FRONT_GLOW)
- .glow()
- .build()),
- OVERLAYS_ENERGY_OUT[this.mTier]
- };
+ return new ITexture[] { super.getFront(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_FRONT),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_FRONT_GLOW).glow().build()),
+ OVERLAYS_ENERGY_OUT[this.mTier] };
}
@Override
public ITexture[] getBack(byte aColor) {
- return new ITexture[] {
- super.getBack(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_BACK),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_BACK_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBack(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_BACK),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_BACK_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottom(byte aColor) {
- return new ITexture[] {
- super.getBottom(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_BOTTOM),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_BOTTOM_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottom(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_BOTTOM),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_BOTTOM_GLOW).glow().build()) };
}
@Override
public ITexture[] getTop(byte aColor) {
- return new ITexture[] {
- super.getTop(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_TOP),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_TOP_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTop(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_TOP),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_TOP_GLOW).glow().build()) };
}
@Override
public ITexture[] getSides(byte aColor) {
- return new ITexture[] {
- super.getSides(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_SIDE),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_SIDE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSides(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_SIDE),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_SIDE_GLOW).glow().build()) };
}
@Override
public ITexture[] getFrontActive(byte aColor) {
- return new ITexture[] {
- super.getFrontActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_FRONT_ACTIVE),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_FRONT_ACTIVE_GLOW)
- .glow()
- .build()),
- OVERLAYS_ENERGY_OUT[this.mTier]
- };
+ return new ITexture[] { super.getFrontActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_FRONT_ACTIVE),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_FRONT_ACTIVE_GLOW).glow().build()),
+ OVERLAYS_ENERGY_OUT[this.mTier] };
}
@Override
public ITexture[] getBackActive(byte aColor) {
- return new ITexture[] {
- super.getBackActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_BACK_ACTIVE),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_BACK_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBackActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_BACK_ACTIVE),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_BACK_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getBottomActive(byte aColor) {
- return new ITexture[] {
- super.getBottomActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_BOTTOM_ACTIVE),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_BOTTOM_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottomActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_BOTTOM_ACTIVE),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_BOTTOM_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getTopActive(byte aColor) {
- return new ITexture[] {
- super.getTopActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_TOP_ACTIVE),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_TOP_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getTopActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_TOP_ACTIVE),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_TOP_ACTIVE_GLOW).glow().build()) };
}
@Override
public ITexture[] getSidesActive(byte aColor) {
- return new ITexture[] {
- super.getSidesActive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(STEAM_TURBINE_SIDE_ACTIVE),
- TextureFactory.builder()
- .addIcon(STEAM_TURBINE_SIDE_ACTIVE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getSidesActive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(STEAM_TURBINE_SIDE_ACTIVE),
+ TextureFactory.builder().addIcon(STEAM_TURBINE_SIDE_ACTIVE_GLOW).glow().build()) };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Bronze.java
index b3da47ae89..4a5cb72be9 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Bronze.java
@@ -9,8 +9,9 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicHull_N
import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_BasicHull_Bronze extends GT_MetaTileEntity_BasicHull_NonElectric {
- public GT_MetaTileEntity_BasicHull_Bronze(
- int aID, String aName, String aNameRegional, int aTier, String aDescription) {
+
+ public GT_MetaTileEntity_BasicHull_Bronze(int aID, String aName, String aNameRegional, int aTier,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aDescription);
}
@@ -18,8 +19,8 @@ public class GT_MetaTileEntity_BasicHull_Bronze extends GT_MetaTileEntity_BasicH
super(aName, aTier, aDescription, aTextures);
}
- public GT_MetaTileEntity_BasicHull_Bronze(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_BasicHull_Bronze(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
@@ -32,15 +33,12 @@ public class GT_MetaTileEntity_BasicHull_Bronze extends GT_MetaTileEntity_BasicH
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[3][17][];
for (byte i = -1; i < 16; i = (byte) (i + 1)) {
- rTextures[0][(i + 1)] = new ITexture[] {
- TextureFactory.of(Textures.BlockIcons.MACHINE_BRONZE_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
- rTextures[1][(i + 1)] = new ITexture[] {
- TextureFactory.of(Textures.BlockIcons.MACHINE_BRONZE_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
- rTextures[2][(i + 1)] = new ITexture[] {
- TextureFactory.of(Textures.BlockIcons.MACHINE_BRONZE_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ rTextures[0][(i + 1)] = new ITexture[] { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_BRONZE_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
+ rTextures[1][(i + 1)] = new ITexture[] { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_BRONZE_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
+ rTextures[2][(i + 1)] = new ITexture[] { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_BRONZE_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
}
return rTextures;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_BronzeBricks.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_BronzeBricks.java
index 0589f8f236..85e3218f9e 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_BronzeBricks.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_BronzeBricks.java
@@ -9,44 +9,43 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicHull_N
import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_BasicHull_BronzeBricks extends GT_MetaTileEntity_BasicHull_NonElectric {
- public GT_MetaTileEntity_BasicHull_BronzeBricks(
- int aID, String aName, String aNameRegional, int aTier, String aDescription) {
+
+ public GT_MetaTileEntity_BasicHull_BronzeBricks(int aID, String aName, String aNameRegional, int aTier,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aDescription);
}
- public GT_MetaTileEntity_BasicHull_BronzeBricks(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_BasicHull_BronzeBricks(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
- public GT_MetaTileEntity_BasicHull_BronzeBricks(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_BasicHull_BronzeBricks(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_BasicHull_BronzeBricks(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[3][17][];
for (byte i = -1; i < 16; i = (byte) (i + 1)) {
- ITexture[] tmp0 = {
- TextureFactory.of(
- Textures.BlockIcons.MACHINE_BRONZEBRICKS_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp0 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_BRONZEBRICKS_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[0][(i + 1)] = tmp0;
- ITexture[] tmp1 = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_BRONZEBRICKS_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp1 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_BRONZEBRICKS_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[1][(i + 1)] = tmp1;
- ITexture[] tmp2 = {
- TextureFactory.of(
- Textures.BlockIcons.MACHINE_BRONZEBRICKS_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp2 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_BRONZEBRICKS_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[2][(i + 1)] = tmp2;
}
return rTextures;
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Steel.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Steel.java
index d8d8cfed63..2ec1d32e36 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_Steel.java
@@ -9,8 +9,9 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicHull_N
import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_BasicHull_Steel extends GT_MetaTileEntity_BasicHull_NonElectric {
- public GT_MetaTileEntity_BasicHull_Steel(
- int aID, String aName, String aNameRegional, int aTier, String aDescription) {
+
+ public GT_MetaTileEntity_BasicHull_Steel(int aID, String aName, String aNameRegional, int aTier,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aDescription);
}
@@ -31,17 +32,14 @@ public class GT_MetaTileEntity_BasicHull_Steel extends GT_MetaTileEntity_BasicHu
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[3][17][];
for (byte i = -1; i < 16; i = (byte) (i + 1)) {
- ITexture[] tmp0 = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_STEEL_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp0 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_STEEL_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[0][(i + 1)] = tmp0;
ITexture[] tmp1 = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_STEEL_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ TextureFactory.of(Textures.BlockIcons.MACHINE_STEEL_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[1][(i + 1)] = tmp1;
- ITexture[] tmp2 = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_STEEL_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp2 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_STEEL_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[2][(i + 1)] = tmp2;
}
return rTextures;
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_SteelBricks.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_SteelBricks.java
index 2a0827e278..e31e793f03 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_SteelBricks.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_BasicHull_SteelBricks.java
@@ -9,43 +9,43 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicHull_N
import gregtech.api.render.TextureFactory;
public class GT_MetaTileEntity_BasicHull_SteelBricks extends GT_MetaTileEntity_BasicHull_NonElectric {
- public GT_MetaTileEntity_BasicHull_SteelBricks(
- int aID, String aName, String aNameRegional, int aTier, String aDescription) {
+
+ public GT_MetaTileEntity_BasicHull_SteelBricks(int aID, String aName, String aNameRegional, int aTier,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aDescription);
}
- public GT_MetaTileEntity_BasicHull_SteelBricks(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_BasicHull_SteelBricks(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
- public GT_MetaTileEntity_BasicHull_SteelBricks(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_BasicHull_SteelBricks(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_BasicHull_SteelBricks(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[3][17][];
for (byte i = -1; i < 16; i = (byte) (i + 1)) {
- ITexture[] tmp0 = {
- TextureFactory.of(
- Textures.BlockIcons.MACHINE_STEELBRICKS_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp0 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_STEELBRICKS_BOTTOM, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[0][(i + 1)] = tmp0;
- ITexture[] tmp1 = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_STEELBRICKS_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp1 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_STEELBRICKS_TOP, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[1][(i + 1)] = tmp1;
- ITexture[] tmp2 = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_STEELBRICKS_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa))
- };
+ ITexture[] tmp2 = { TextureFactory
+ .of(Textures.BlockIcons.MACHINE_STEELBRICKS_SIDE, Dyes.getModulation(i, Dyes._NULL.mRGBa)) };
rTextures[2][(i + 1)] = tmp2;
}
return rTextures;
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_InputBus_ME.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_InputBus_ME.java
index f8bc564ab4..cac1ef936e 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_InputBus_ME.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_InputBus_ME.java
@@ -3,6 +3,12 @@ package gregtech.common.tileentities.machines;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_ME_INPUT_HATCH;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_ME_INPUT_HATCH_ACTIVE;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraftforge.common.util.ForgeDirection;
+
import appeng.api.config.Actionable;
import appeng.api.config.PowerMultiplier;
import appeng.api.implementations.IPowerChannelState;
@@ -17,11 +23,13 @@ import appeng.me.GridAccessException;
import appeng.me.helpers.AENetworkProxy;
import appeng.me.helpers.IGridProxyable;
import appeng.util.item.AEItemStack;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.SlotGroup;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
import cpw.mods.fml.common.Optional;
import gregtech.api.GregTech_API;
import gregtech.api.enums.ItemList;
@@ -36,15 +44,11 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_Input
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
import gregtech.common.gui.modularui.widget.AESlotWidget;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraftforge.common.util.ForgeDirection;
@Optional.Interface(iface = "appeng.api.implementations.IPowerChannelState", modid = "appliedenergistics2")
public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch_InputBus
implements IConfigurationCircuitSupport, IAddGregtechLogo, IAddUIWidgets, IPowerChannelState {
+
private static final int SLOT_COUNT = 16;
private BaseActionSource requestSource = null;
private AENetworkProxy gridProxy = null;
@@ -53,14 +57,19 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
private boolean processingRecipe = false;
public GT_MetaTileEntity_Hatch_InputBus_ME(int aID, String aName, String aNameRegional) {
- super(aID, aName, aNameRegional, 1, SLOT_COUNT * 2 + 1, new String[] {
- "Advanced item input for Multiblocks", "Retrieves directly from ME", "Keeps 16 item types in stock"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ 1,
+ SLOT_COUNT * 2 + 1,
+ new String[] { "Advanced item input for Multiblocks", "Retrieves directly from ME",
+ "Keeps 16 item types in stock" });
disableSort = true;
}
- public GT_MetaTileEntity_Hatch_InputBus_ME(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Hatch_InputBus_ME(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, SLOT_COUNT * 2 + 1, aDescription, aTextures);
disableSort = true;
}
@@ -72,12 +81,12 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
@Override
public ITexture[] getTexturesActive(ITexture aBaseTexture) {
- return new ITexture[] {aBaseTexture, TextureFactory.of(OVERLAY_ME_INPUT_HATCH_ACTIVE)};
+ return new ITexture[] { aBaseTexture, TextureFactory.of(OVERLAY_ME_INPUT_HATCH_ACTIVE) };
}
@Override
public ITexture[] getTexturesInactive(ITexture aBaseTexture) {
- return new ITexture[] {aBaseTexture, TextureFactory.of(OVERLAY_ME_INPUT_HATCH)};
+ return new ITexture[] { aBaseTexture, TextureFactory.of(OVERLAY_ME_INPUT_HATCH) };
}
@Override
@@ -98,12 +107,14 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
if (gridProxy == null) {
if (getBaseMetaTileEntity() instanceof IGridProxyable) {
gridProxy = new AENetworkProxy(
- (IGridProxyable) getBaseMetaTileEntity(), "proxy", ItemList.Hatch_Output_Bus_ME.get(1), true);
+ (IGridProxyable) getBaseMetaTileEntity(),
+ "proxy",
+ ItemList.Hatch_Output_Bus_ME.get(1),
+ true);
gridProxy.setFlags(GridFlags.REQUIRE_CHANNEL);
- if (getBaseMetaTileEntity().getWorld() != null)
- gridProxy.setOwner(getBaseMetaTileEntity()
- .getWorld()
- .getPlayerEntityByName(getBaseMetaTileEntity().getOwnerName()));
+ if (getBaseMetaTileEntity().getWorld() != null) gridProxy.setOwner(
+ getBaseMetaTileEntity().getWorld()
+ .getPlayerEntityByName(getBaseMetaTileEntity().getOwnerName()));
}
}
return this.gridProxy;
@@ -165,12 +176,10 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
public String[] getInfoData() {
if (GregTech_API.mAE2) {
return new String[] {
- "The bus is "
- + ((getProxy() != null && getProxy().isActive())
- ? EnumChatFormatting.GREEN + "online"
- : EnumChatFormatting.RED + "offline" + getAEDiagnostics())
- + EnumChatFormatting.RESET
- };
+ "The bus is "
+ + ((getProxy() != null && getProxy().isActive()) ? EnumChatFormatting.GREEN + "online"
+ : EnumChatFormatting.RED + "offline" + getAEDiagnostics())
+ + EnumChatFormatting.RESET };
} else return new String[] {};
}
@@ -238,8 +247,7 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
this.setInventorySlotContents(aIndex + SLOT_COUNT, null);
return null;
}
- } catch (final GridAccessException ignored) {
- }
+ } catch (final GridAccessException ignored) {}
return null;
} else {
// AE available but no items requested
@@ -279,12 +287,12 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
IAEItemStack request = AEItemStack.create(mInventory[i]);
request.setStackSize(savedStackSizes[i] - (oldStack == null ? 0 : oldStack.stackSize));
sg.extractItems(request, Actionable.MODULATE, getRequestSource());
- proxy.getEnergy()
- .extractAEPower(
- request.getStackSize(), Actionable.MODULATE, PowerMultiplier.CONFIG);
+ proxy.getEnergy().extractAEPower(
+ request.getStackSize(),
+ Actionable.MODULATE,
+ PowerMultiplier.CONFIG);
setInventorySlotContents(i + SLOT_COUNT, oldStack);
- } catch (final GridAccessException ignored) {
- }
+ } catch (final GridAccessException ignored) {}
}
savedStackSizes[i] = 0;
shadowInventory[i] = null;
@@ -312,8 +320,7 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
ItemStack s = (result != null) ? result.getItemStack() : null;
setInventorySlotContents(aIndex + SLOT_COUNT, s);
return s;
- } catch (final GridAccessException ignored) {
- }
+ } catch (final GridAccessException ignored) {}
}
}
return null;
@@ -327,12 +334,11 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
final SlotWidget[] aeSlotWidgets = new SlotWidget[16];
- builder.widget(SlotGroup.ofItemHandler(inventoryHandler, 4)
- .startFromSlot(0)
- .endAtSlot(15)
- .phantom(true)
+ builder.widget(
+ SlotGroup.ofItemHandler(inventoryHandler, 4).startFromSlot(0).endAtSlot(15).phantom(true)
.background(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_ARROW_ME)
.widgetCreator(slot -> new SlotWidget(slot) {
+
@Override
protected void phantomClick(ClickData clickData, ItemStack cursorStack) {
if (clickData.mouseButton != 0) return;
@@ -345,9 +351,7 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
}
if (getBaseMetaTileEntity().isServerSide()) {
final ItemStack newInfo = updateInformationSlot(aSlotIndex, cursorStack);
- aeSlotWidgets[getMcSlot().getSlotIndex()]
- .getMcSlot()
- .putStack(newInfo);
+ aeSlotWidgets[getMcSlot().getSlotIndex()].getMcSlot().putStack(newInfo);
}
}
@@ -357,29 +361,22 @@ public class GT_MetaTileEntity_Hatch_InputBus_ME extends GT_MetaTileEntity_Hatch
}
return false;
}
- })
- .build()
- .setPos(7, 9))
- .widget(SlotGroup.ofItemHandler(inventoryHandler, 4)
- .startFromSlot(16)
- .endAtSlot(31)
- .phantom(true)
- .background(GT_UITextures.SLOT_DARK_GRAY)
- .widgetCreator(slot ->
- aeSlotWidgets[slot.getSlotIndex() - 16] = new AESlotWidget(slot).disableInteraction())
- .build()
- .setPos(97, 9))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_ARROW_DOUBLE)
- .setPos(82, 40)
- .setSize(12, 12));
+ }).build().setPos(7, 9))
+ .widget(
+ SlotGroup.ofItemHandler(inventoryHandler, 4).startFromSlot(16).endAtSlot(31).phantom(true)
+ .background(GT_UITextures.SLOT_DARK_GRAY)
+ .widgetCreator(
+ slot -> aeSlotWidgets[slot.getSlotIndex() - 16] = new AESlotWidget(slot)
+ .disableInteraction())
+ .build().setPos(97, 9))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_ARROW_DOUBLE).setPos(82, 40)
+ .setSize(12, 12));
}
@Override
public void addGregTechLogo(ModularWindow.Builder builder) {
- builder.widget(new DrawableWidget()
- .setDrawable(getGUITextureSet().getGregTechLogo())
- .setSize(17, 17)
- .setPos(80, 63));
+ builder.widget(
+ new DrawableWidget().setDrawable(getGUITextureSet().getGregTechLogo()).setSize(17, 17).setPos(80, 63));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_OutputBus_ME.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_OutputBus_ME.java
index e52ff2796b..6099473660 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_OutputBus_ME.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_OutputBus_ME.java
@@ -3,6 +3,18 @@ package gregtech.common.tileentities.machines;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_ME_HATCH;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_ME_HATCH_ACTIVE;
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.nbt.NBTTagList;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.common.util.ForgeDirection;
+
import appeng.api.AEApi;
import appeng.api.implementations.IPowerChannelState;
import appeng.api.networking.GridFlags;
@@ -30,24 +42,14 @@ import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_OutputBus;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.List;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.nbt.NBTTagList;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.common.util.ForgeDirection;
@Optional.Interface(iface = "appeng.api.implementations.IPowerChannelState", modid = "appliedenergistics2")
public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatch_OutputBus
implements IPowerChannelState {
+
private BaseActionSource requestSource = null;
private AENetworkProxy gridProxy = null;
- IItemList<IAEItemStack> itemCache =
- GregTech_API.mAE2 ? AEApi.instance().storage().createItemList() : null;
+ IItemList<IAEItemStack> itemCache = GregTech_API.mAE2 ? AEApi.instance().storage().createItemList() : null;
long lastOutputTick = 0;
long tickCounter = 0;
boolean lastOutputFailed = false;
@@ -59,14 +61,12 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
aName,
aNameRegional,
1,
- new String[] {
- "Item Output for Multiblocks", "Stores directly into ME",
- },
+ new String[] { "Item Output for Multiblocks", "Stores directly into ME", },
0);
}
- public GT_MetaTileEntity_Hatch_OutputBus_ME(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_Hatch_OutputBus_ME(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, 0, aDescription, aTextures);
}
@@ -77,12 +77,12 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
@Override
public ITexture[] getTexturesActive(ITexture aBaseTexture) {
- return new ITexture[] {aBaseTexture, TextureFactory.of(OVERLAY_ME_HATCH_ACTIVE)};
+ return new ITexture[] { aBaseTexture, TextureFactory.of(OVERLAY_ME_HATCH_ACTIVE) };
}
@Override
public ITexture[] getTexturesInactive(ITexture aBaseTexture) {
- return new ITexture[] {aBaseTexture, TextureFactory.of(OVERLAY_ME_HATCH)};
+ return new ITexture[] { aBaseTexture, TextureFactory.of(OVERLAY_ME_HATCH) };
}
@Override
@@ -101,7 +101,7 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
/**
* Attempt to store items in connected ME network. Returns how many items did not fit (if the network was down e.g.)
*
- * @param stack input stack
+ * @param stack input stack
* @return amount of items left over
*/
@Optional.Method(modid = "appliedenergistics2")
@@ -132,8 +132,8 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
public void onScrewdriverRightClick(byte aSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (!getBaseMetaTileEntity().getCoverInfoAtSide(aSide).isGUIClickable()) return;
infiniteCache = !infiniteCache;
- GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocal("GT5U.hatch.infiniteCache." + infiniteCache));
+ GT_Utility
+ .sendChatToPlayer(aPlayer, StatCollector.translateToLocal("GT5U.hatch.infiniteCache." + infiniteCache));
}
@Override
@@ -142,12 +142,14 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
if (gridProxy == null) {
if (getBaseMetaTileEntity() instanceof IGridProxyable) {
gridProxy = new AENetworkProxy(
- (IGridProxyable) getBaseMetaTileEntity(), "proxy", ItemList.Hatch_Output_Bus_ME.get(1), true);
+ (IGridProxyable) getBaseMetaTileEntity(),
+ "proxy",
+ ItemList.Hatch_Output_Bus_ME.get(1),
+ true);
gridProxy.setFlags(GridFlags.REQUIRE_CHANNEL);
- if (getBaseMetaTileEntity().getWorld() != null)
- gridProxy.setOwner(getBaseMetaTileEntity()
- .getWorld()
- .getPlayerEntityByName(getBaseMetaTileEntity().getOwnerName()));
+ if (getBaseMetaTileEntity().getWorld() != null) gridProxy.setOwner(
+ getBaseMetaTileEntity().getWorld()
+ .getPlayerEntityByName(getBaseMetaTileEntity().getOwnerName()));
}
}
return this.gridProxy;
@@ -243,8 +245,8 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
continue;
}
NBTTagCompound tagItemStack = tag.getCompoundTag("itemStack");
- final IAEItemStack s =
- AEApi.instance().storage().createItemStack(GT_Utility.loadItem(tagItemStack));
+ final IAEItemStack s = AEApi.instance().storage()
+ .createItemStack(GT_Utility.loadItem(tagItemStack));
if (s != null) {
s.setStackSize(tag.getLong("size"));
itemCache.add(s);
@@ -271,11 +273,9 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
public String[] getInfoData() {
if (!GregTech_API.mAE2) return new String[] {};
List<String> ss = new ArrayList<>();
- ss.add("The bus is "
- + ((getProxy() != null && getProxy().isActive())
- ? EnumChatFormatting.GREEN + "online"
- : EnumChatFormatting.RED + "offline" + getAEDiagnostics())
- + EnumChatFormatting.RESET);
+ ss.add(
+ "The bus is " + ((getProxy() != null && getProxy().isActive()) ? EnumChatFormatting.GREEN + "online"
+ : EnumChatFormatting.RED + "offline" + getAEDiagnostics()) + EnumChatFormatting.RESET);
if (itemCache.isEmpty()) {
ss.add("The bus has no cached items");
} else {
@@ -283,8 +283,11 @@ public class GT_MetaTileEntity_Hatch_OutputBus_ME extends GT_MetaTileEntity_Hatc
ss.add(String.format("The bus contains %d cached stacks: ", itemCache.size()));
int counter = 0;
for (IAEItemStack s : itemCache) {
- ss.add(s.getItem().getItemStackDisplayName(s.getItemStack()) + ": " + EnumChatFormatting.GOLD
- + nc.toWideReadableForm(s.getStackSize()) + EnumChatFormatting.RESET);
+ ss.add(
+ s.getItem().getItemStackDisplayName(s.getItemStack()) + ": "
+ + EnumChatFormatting.GOLD
+ + nc.toWideReadableForm(s.getStackSize())
+ + EnumChatFormatting.RESET);
if (++counter > 100) break;
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_Output_ME.java b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_Output_ME.java
index 6fbcbe4681..e60dec5c51 100644
--- a/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_Output_ME.java
+++ b/src/main/java/gregtech/common/tileentities/machines/GT_MetaTileEntity_Hatch_Output_ME.java
@@ -3,6 +3,18 @@ package gregtech.common.tileentities.machines;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_ME_FLUID_HATCH;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_ME_FLUID_HATCH_ACTIVE;
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.nbt.NBTBase;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.nbt.NBTTagList;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import appeng.api.AEApi;
import appeng.api.config.Actionable;
import appeng.api.config.PowerMultiplier;
@@ -35,23 +47,13 @@ import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_Output;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.List;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.nbt.NBTBase;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.nbt.NBTTagList;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
@Optional.Interface(iface = "appeng.api.implementations.IPowerChannelState", modid = "appliedenergistics2")
public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_Output implements IPowerChannelState {
+
private BaseActionSource requestSource = null;
private AENetworkProxy gridProxy = null;
- IItemList<IAEFluidStack> fluidCache =
- GregTech_API.mAE2 ? AEApi.instance().storage().createFluidList() : null;
+ IItemList<IAEFluidStack> fluidCache = GregTech_API.mAE2 ? AEApi.instance().storage().createFluidList() : null;
long lastOutputTick = 0;
long tickCounter = 0;
boolean lastOutputFailed = false;
@@ -63,9 +65,7 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
aName,
aNameRegional,
1,
- new String[] {
- "Fluid Output for Multiblocks", "Stores directly into ME",
- },
+ new String[] { "Fluid Output for Multiblocks", "Stores directly into ME", },
0);
}
@@ -80,12 +80,12 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
@Override
public ITexture[] getTexturesActive(ITexture aBaseTexture) {
- return new ITexture[] {aBaseTexture, TextureFactory.of(OVERLAY_ME_FLUID_HATCH)};
+ return new ITexture[] { aBaseTexture, TextureFactory.of(OVERLAY_ME_FLUID_HATCH) };
}
@Override
public ITexture[] getTexturesInactive(ITexture aBaseTexture) {
- return new ITexture[] {aBaseTexture, TextureFactory.of(OVERLAY_ME_FLUID_HATCH_ACTIVE)};
+ return new ITexture[] { aBaseTexture, TextureFactory.of(OVERLAY_ME_FLUID_HATCH_ACTIVE) };
}
@Override
@@ -108,7 +108,7 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
/**
* Attempt to store fluid in connected ME network. Returns how much fluid is accepted (if the network was down e.g.)
*
- * @param aFluid input fluid
+ * @param aFluid input fluid
* @return amount of fluid filled
*/
@Optional.Method(modid = "appliedenergistics2")
@@ -154,7 +154,8 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
if (!getBaseMetaTileEntity().getCoverInfoAtSide(aSide).isGUIClickable()) return;
infiniteCache = !infiniteCache;
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocal("GT5U.hatch.infiniteCacheFluid." + infiniteCache));
+ aPlayer,
+ StatCollector.translateToLocal("GT5U.hatch.infiniteCacheFluid." + infiniteCache));
}
@Override
@@ -163,12 +164,14 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
if (gridProxy == null) {
if (getBaseMetaTileEntity() instanceof IGridProxyable) {
gridProxy = new AENetworkProxy(
- (IGridProxyable) getBaseMetaTileEntity(), "proxy", ItemList.Hatch_Output_ME.get(1), true);
+ (IGridProxyable) getBaseMetaTileEntity(),
+ "proxy",
+ ItemList.Hatch_Output_ME.get(1),
+ true);
gridProxy.setFlags(GridFlags.REQUIRE_CHANNEL);
- if (getBaseMetaTileEntity().getWorld() != null)
- gridProxy.setOwner(getBaseMetaTileEntity()
- .getWorld()
- .getPlayerEntityByName(getBaseMetaTileEntity().getOwnerName()));
+ if (getBaseMetaTileEntity().getWorld() != null) gridProxy.setOwner(
+ getBaseMetaTileEntity().getWorld()
+ .getPlayerEntityByName(getBaseMetaTileEntity().getOwnerName()));
}
}
return this.gridProxy;
@@ -254,8 +257,8 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
for (int i = 0; i < l.tagCount(); ++i) {
NBTTagCompound tag = l.getCompoundTagAt(i);
NBTTagCompound tagFluidStack = tag.getCompoundTag("fluidStack");
- final IAEFluidStack s =
- AEApi.instance().storage().createFluidStack(GT_Utility.loadFluid(tagFluidStack));
+ final IAEFluidStack s = AEApi.instance().storage()
+ .createFluidStack(GT_Utility.loadFluid(tagFluidStack));
if (s != null) {
s.setStackSize(tag.getLong("size"));
fluidCache.add(s);
@@ -282,11 +285,9 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
public String[] getInfoData() {
if (!GregTech_API.mAE2) return new String[] {};
List<String> ss = new ArrayList<>();
- ss.add("The hatch is "
- + ((getProxy() != null && getProxy().isActive())
- ? EnumChatFormatting.GREEN + "online"
- : EnumChatFormatting.RED + "offline" + getAEDiagnostics())
- + EnumChatFormatting.RESET);
+ ss.add(
+ "The hatch is " + ((getProxy() != null && getProxy().isActive()) ? EnumChatFormatting.GREEN + "online"
+ : EnumChatFormatting.RED + "offline" + getAEDiagnostics()) + EnumChatFormatting.RESET);
if (fluidCache.isEmpty()) {
ss.add("The bus has no cached fluids");
} else {
@@ -294,8 +295,12 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
ss.add(String.format("The hatch contains %d cached fluids: ", fluidCache.size()));
int counter = 0;
for (IAEFluidStack s : fluidCache) {
- ss.add(s.getFluidStack().getLocalizedName() + ": " + EnumChatFormatting.GOLD
- + nc.toWideReadableForm(s.getStackSize()) + " mB" + EnumChatFormatting.RESET);
+ ss.add(
+ s.getFluidStack().getLocalizedName() + ": "
+ + EnumChatFormatting.GOLD
+ + nc.toWideReadableForm(s.getStackSize())
+ + " mB"
+ + EnumChatFormatting.RESET);
if (++counter > 100) break;
}
}
@@ -303,11 +308,8 @@ public class GT_MetaTileEntity_Hatch_Output_ME extends GT_MetaTileEntity_Hatch_O
}
@Optional.Method(modid = "appliedenergistics2")
- public static IAEFluidStack fluidAEInsert(
- final IEnergySource energy,
- final IMEInventory<IAEFluidStack> cell,
- final IAEFluidStack input,
- final BaseActionSource src) {
+ public static IAEFluidStack fluidAEInsert(final IEnergySource energy, final IMEInventory<IAEFluidStack> cell,
+ final IAEFluidStack input, final BaseActionSource src) {
final IAEFluidStack possible = cell.injectItems(input.copy(), Actionable.SIMULATE, src);
long stored = input.getStackSize();
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_AdvSeismicProspector.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_AdvSeismicProspector.java
index ee2ddcdfed..34589d2c1c 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_AdvSeismicProspector.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_AdvSeismicProspector.java
@@ -3,6 +3,21 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.common.GT_UndergroundOil.undergroundOilReadInformation;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.LinkedHashMap;
+import java.util.Map;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.ChunkCoordIntPair;
+import net.minecraft.world.chunk.Chunk;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Materials;
@@ -17,29 +32,17 @@ import gregtech.api.util.GT_Utility;
import gregtech.common.blocks.GT_Block_Ores_Abstract;
import gregtech.common.blocks.GT_TileEntity_Ores;
import ic2.core.Ic2Items;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.LinkedHashMap;
-import java.util.Map;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.ChunkCoordIntPair;
-import net.minecraft.world.chunk.Chunk;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_AdvSeismicProspector extends GT_MetaTileEntity_BasicMachine {
+
boolean ready = false;
int radius;
int step;
int cX;
int cZ;
- public GT_MetaTileEntity_AdvSeismicProspector(
- int aID, String aName, String aNameRegional, int aTier, int aRadius, int aStep) {
+ public GT_MetaTileEntity_AdvSeismicProspector(int aID, String aName, String aNameRegional, int aTier, int aRadius,
+ int aStep) {
super(
aID,
aName,
@@ -53,76 +56,43 @@ public class GT_MetaTileEntity_AdvSeismicProspector extends GT_MetaTileEntity_Ba
"", // NEI name
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_GLOW).glow().build()));
radius = aRadius;
step = aStep;
}
@Override
public String[] getDescription() {
- return new String[] {
- "Place, activate with explosives",
- "2 Powderbarrels, " + "4 Glyceryl Trinitrate, " + "16 TNT, or " + "8 ITNT",
- "Use Data Stick, Scan Data Stick, Print Data Stick, Bind Pages into Book",
- "Ore prospecting area = " + radius * 2 + "x" + radius * 2 + " ONLY blocks below prospector",
- "Oil prospecting area 3x3 oilfields, each is 8x8 chunks"
- };
+ return new String[] { "Place, activate with explosives",
+ "2 Powderbarrels, " + "4 Glyceryl Trinitrate, " + "16 TNT, or " + "8 ITNT",
+ "Use Data Stick, Scan Data Stick, Print Data Stick, Bind Pages into Book",
+ "Ore prospecting area = " + radius * 2 + "x" + radius * 2 + " ONLY blocks below prospector",
+ "Oil prospecting area 3x3 oilfields, each is 8x8 chunks" };
}
- protected GT_MetaTileEntity_AdvSeismicProspector(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName,
- int aRadius,
- int aStep) {
+ protected GT_MetaTileEntity_AdvSeismicProspector(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures, String aGUIName, String aNEIName, int aRadius, int aStep) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
radius = aRadius;
step = aStep;
@@ -146,42 +116,40 @@ public class GT_MetaTileEntity_AdvSeismicProspector extends GT_MetaTileEntity_Ba
if (aBaseMetaTileEntity.isServerSide()) {
ItemStack aStack = aPlayer.getCurrentEquippedItem();
- if (!ready
- && (GT_Utility.consumeItems(aPlayer, aStack, Item.getItemFromBlock(Blocks.tnt), 16)
- || GT_Utility.consumeItems(aPlayer, aStack, Ic2Items.industrialTnt.getItem(), 8)
- || GT_Utility.consumeItems(aPlayer, aStack, Materials.Glyceryl, 4)
- || GT_Utility.consumeItems(aPlayer, aStack, ItemList.Block_Powderbarrel.getItem(), 2))) {
+ if (!ready && (GT_Utility.consumeItems(aPlayer, aStack, Item.getItemFromBlock(Blocks.tnt), 16)
+ || GT_Utility.consumeItems(aPlayer, aStack, Ic2Items.industrialTnt.getItem(), 8)
+ || GT_Utility.consumeItems(aPlayer, aStack, Materials.Glyceryl, 4)
+ || GT_Utility.consumeItems(aPlayer, aStack, ItemList.Block_Powderbarrel.getItem(), 2))) {
this.ready = true;
this.mMaxProgresstime = (aPlayer.capabilities.isCreativeMode ? 20 : 800);
- } else if (ready
- && mMaxProgresstime == 0
+ } else if (ready && mMaxProgresstime == 0
&& aStack != null
&& aStack.stackSize == 1
&& aStack.getItem() == ItemList.Tool_DataStick.getItem()) {
- this.ready = false;
-
- // prospecting ores
- HashMap<String, Integer> tOres = new HashMap<>(36);
-
- prospectOres(tOres);
-
- // prospecting oils
- ArrayList<String> tOils = new ArrayList<>();
- prospectOils(tOils);
-
- GT_Utility.ItemNBT.setAdvancedProspectionData(
- mTier,
- aStack,
- this.getBaseMetaTileEntity().getXCoord(),
- this.getBaseMetaTileEntity().getYCoord(),
- this.getBaseMetaTileEntity().getZCoord(),
- this.getBaseMetaTileEntity().getWorld().provider.dimensionId,
- tOils,
- GT_Utility.sortByValueToList(tOres),
- radius);
- }
+ this.ready = false;
+
+ // prospecting ores
+ HashMap<String, Integer> tOres = new HashMap<>(36);
+
+ prospectOres(tOres);
+
+ // prospecting oils
+ ArrayList<String> tOils = new ArrayList<>();
+ prospectOils(tOils);
+
+ GT_Utility.ItemNBT.setAdvancedProspectionData(
+ mTier,
+ aStack,
+ this.getBaseMetaTileEntity().getXCoord(),
+ this.getBaseMetaTileEntity().getYCoord(),
+ this.getBaseMetaTileEntity().getZCoord(),
+ this.getBaseMetaTileEntity().getWorld().provider.dimensionId,
+ tOils,
+ GT_Utility.sortByValueToList(tOres),
+ radius);
+ }
}
return true;
@@ -205,10 +173,9 @@ public class GT_MetaTileEntity_AdvSeismicProspector extends GT_MetaTileEntity_Ba
for (int i = 0; i < oilfieldSize; i++) {
for (int j = 0; j < oilfieldSize; j++) {
- Chunk tChunk = getBaseMetaTileEntity()
- .getWorld()
- .getChunkFromChunkCoords(
- xChunk + i + x * oilfieldSize, zChunk + j + z * oilfieldSize);
+ Chunk tChunk = getBaseMetaTileEntity().getWorld().getChunkFromChunkCoords(
+ xChunk + i + x * oilfieldSize,
+ zChunk + j + z * oilfieldSize);
FluidStack tFluid = undergroundOilReadInformation(tChunk);
if (tFluid != null) {
if (tFluid.amount > max) max = tFluid.amount;
@@ -220,12 +187,10 @@ public class GT_MetaTileEntity_AdvSeismicProspector extends GT_MetaTileEntity_Ba
}
}
- aOils.add(++oilFieldCount + "," + min + "-" + max + ","
- + tFluids.get(cInts).getLocalizedName());
+ aOils.add(++oilFieldCount + "," + min + "-" + max + "," + tFluids.get(cInts).getLocalizedName());
}
}
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
private void prospectOres(Map<String, Integer> aOres) {
@@ -264,10 +229,11 @@ public class GT_MetaTileEntity_AdvSeismicProspector extends GT_MetaTileEntity_Ba
if (tBlock instanceof GT_Block_Ores_Abstract) {
TileEntity tTileEntity = getBaseMetaTileEntity().getWorld().getTileEntity(x, y, z);
- if ((tTileEntity instanceof GT_TileEntity_Ores)
- && (((GT_TileEntity_Ores) tTileEntity).mMetaData < 16000)) { // Filtering small ores
- Materials tMaterial =
- GregTech_API.sGeneratedMaterials[((GT_TileEntity_Ores) tTileEntity).mMetaData % 1000];
+ if ((tTileEntity instanceof GT_TileEntity_Ores) && (((GT_TileEntity_Ores) tTileEntity).mMetaData < 16000)) { // Filtering
+ // small
+ // ores
+ Materials tMaterial = GregTech_API.sGeneratedMaterials[((GT_TileEntity_Ores) tTileEntity).mMetaData
+ % 1000];
if ((tMaterial != null) && (tMaterial != Materials._NULL)) return tMaterial.mDefaultLocalName;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Boxinator.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Boxinator.java
index e718fe0a2d..f94b8404fa 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Boxinator.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Boxinator.java
@@ -2,6 +2,8 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.ItemList;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
@@ -11,9 +13,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine {
+
ItemStack aInputCache;
ItemStack aOutputCache;
int aTypeCache = 0;
@@ -32,73 +34,49 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_BOXINATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_BOXINATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_BOXINATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_BOXINATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_BOXINATOR_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_BOXINATOR_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_BOXINATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_BOXINATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_BOXINATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_BOXINATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_BOXINATOR_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_BOXINATOR_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_BOXINATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_BOXINATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_BOXINATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_BOXINATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_BOXINATOR_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_BOXINATOR_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_BOXINATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_BOXINATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_BOXINATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_BOXINATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_BOXINATOR_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_BOXINATOR_GLOW).glow().build()));
}
- public GT_MetaTileEntity_Boxinator(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Boxinator(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 2, 1, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_Boxinator(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_Boxinator(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 2, 1, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Boxinator(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -107,11 +85,11 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
}
private boolean hasValidCache(ItemStack mItem, int mType, boolean mClearOnFailure) {
- if (aInputCache != null
- && aOutputCache != null
+ if (aInputCache != null && aOutputCache != null
&& aTypeCache == mType
&& aInputCache.isItemEqual(mItem)
- && ItemStack.areItemStackTagsEqual(mItem, aInputCache)) return true;
+ && ItemStack.areItemStackTagsEqual(mItem, aInputCache))
+ return true;
// clear cache if it was invalid
if (mClearOnFailure) {
aInputCache = null;
@@ -135,8 +113,7 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
}
ItemStack tSlot0 = getInputAt(0);
ItemStack tSlot1 = getInputAt(1);
- if ((GT_Utility.isStackValid(tSlot0))
- && (GT_Utility.isStackValid(tSlot1))
+ if ((GT_Utility.isStackValid(tSlot0)) && (GT_Utility.isStackValid(tSlot1))
&& (GT_Utility.getContainerItem(tSlot0, true) == null)) {
if ((ItemList.Schematic_1by1.isStackEqual(tSlot1)) && (tSlot0.stackSize >= 1)) {
boolean tIsCached = hasValidCache(tSlot0, 1, true);
@@ -156,8 +133,7 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
}
if ((ItemList.Schematic_2by2.isStackEqual(tSlot1)) && (getInputAt(0).stackSize >= 4)) {
boolean tIsCached = hasValidCache(tSlot0, 2, true);
- this.mOutputItems[0] = tIsCached
- ? aOutputCache.copy()
+ this.mOutputItems[0] = tIsCached ? aOutputCache.copy()
: GT_ModHandler.getRecipeOutput(tSlot0, tSlot0, null, tSlot0, tSlot0);
if (this.mOutputItems[0] != null) {
if (canOutput(this.mOutputItems[0])) {
@@ -174,10 +150,17 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
}
if ((ItemList.Schematic_3by3.isStackEqual(tSlot1)) && (getInputAt(0).stackSize >= 9)) {
boolean tIsCached = hasValidCache(tSlot0, 3, true);
- this.mOutputItems[0] = tIsCached
- ? aOutputCache.copy()
+ this.mOutputItems[0] = tIsCached ? aOutputCache.copy()
: GT_ModHandler.getRecipeOutput(
- tSlot0, tSlot0, tSlot0, tSlot0, tSlot0, tSlot0, tSlot0, tSlot0, tSlot0);
+ tSlot0,
+ tSlot0,
+ tSlot0,
+ tSlot0,
+ tSlot0,
+ tSlot0,
+ tSlot0,
+ tSlot0,
+ tSlot0);
if (this.mOutputItems[0] != null) {
if (canOutput(this.mOutputItems[0])) {
getInputAt(0).stackSize -= 9;
@@ -196,24 +179,22 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
if (!super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)) {
return false;
}
ItemStack tInput1 = getInputAt(1);
- if ((ItemList.Schematic_1by1.isStackEqual(tInput1))
- || (ItemList.Schematic_2by2.isStackEqual(tInput1))
+ if ((ItemList.Schematic_1by1.isStackEqual(tInput1)) || (ItemList.Schematic_2by2.isStackEqual(tInput1))
|| (ItemList.Schematic_3by3.isStackEqual(tInput1))) {
if (hasValidCache(aStack, aTypeCache, false)) return true;
if (GT_Recipe.GT_Recipe_Map.sBoxinatorRecipes.findRecipe(
- getBaseMetaTileEntity(),
- true,
- gregtech.api.enums.GT_Values.V[mTier],
- null,
- GT_Utility.copyAmount(64L, aStack),
- tInput1)
- != null) {
+ getBaseMetaTileEntity(),
+ true,
+ gregtech.api.enums.GT_Values.V[mTier],
+ null,
+ GT_Utility.copyAmount(64L, aStack),
+ tInput1) != null) {
return true;
}
if (ItemList.Schematic_1by1.isStackEqual(getInputAt(1)) && GT_ModHandler.getRecipeOutput(aStack) != null)
@@ -222,10 +203,8 @@ public class GT_MetaTileEntity_Boxinator extends GT_MetaTileEntity_BasicMachine
&& GT_ModHandler.getRecipeOutput(aStack, aStack, null, aStack, aStack) != null) {
return true;
}
- return ItemList.Schematic_3by3.isStackEqual(getInputAt(1))
- && (GT_ModHandler.getRecipeOutput(
- aStack, aStack, aStack, aStack, aStack, aStack, aStack, aStack, aStack)
- != null);
+ return ItemList.Schematic_3by3.isStackEqual(getInputAt(1)) && (GT_ModHandler
+ .getRecipeOutput(aStack, aStack, aStack, aStack, aStack, aStack, aStack, aStack, aStack) != null);
} else {
return GT_Recipe.GT_Recipe_Map.sBoxinatorRecipes.containsInput(aStack);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Charger.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Charger.java
index f6223a4a0d..28caaef181 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Charger.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Charger.java
@@ -13,18 +13,18 @@ import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_Charger extends GT_MetaTileEntity_BasicBatteryBuffer {
- public GT_MetaTileEntity_Charger(
- int aID, String aName, String aNameRegional, int aTier, String aDescription, int aSlotCount) {
+ public GT_MetaTileEntity_Charger(int aID, String aName, String aNameRegional, int aTier, String aDescription,
+ int aSlotCount) {
super(aID, aName, aNameRegional, aTier, aDescription, aSlotCount);
}
- public GT_MetaTileEntity_Charger(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, int aSlotCount) {
+ public GT_MetaTileEntity_Charger(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ int aSlotCount) {
super(aName, aTier, aDescription, aTextures, aSlotCount);
}
- public GT_MetaTileEntity_Charger(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures, int aSlotCount) {
+ public GT_MetaTileEntity_Charger(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ int aSlotCount) {
super(aName, aTier, aDescription, aTextures, aSlotCount);
}
@@ -65,18 +65,17 @@ public class GT_MetaTileEntity_Charger extends GT_MetaTileEntity_BasicBatteryBuf
if (mMetaTileEntity.dechargerSlotCount() > 0
&& mBaseMetaTileEntity.getStoredEU() < mBaseMetaTileEntity.getEUCapacity()) {
for (int i = mMetaTileEntity.dechargerSlotStartIndex(),
- k = mMetaTileEntity.dechargerSlotCount() + i;
- i < k;
- i++) {
+ k = mMetaTileEntity.dechargerSlotCount() + i; i < k; i++) {
if (mMetaTileEntity.mInventory[i] != null
&& mBaseMetaTileEntity.getStoredEU() < mBaseMetaTileEntity.getEUCapacity()) {
mBaseMetaTileEntity.increaseStoredEnergyUnits(
GT_ModHandler.dischargeElectricItem(
mMetaTileEntity.mInventory[i],
- GT_Utility.safeInt(Math.min(
- V[mTier] * 15,
- mBaseMetaTileEntity.getEUCapacity()
- - mBaseMetaTileEntity.getStoredEU())),
+ GT_Utility.safeInt(
+ Math.min(
+ V[mTier] * 15,
+ mBaseMetaTileEntity.getEUCapacity()
+ - mBaseMetaTileEntity.getStoredEU())),
(int) Math.min(Integer.MAX_VALUE, mMetaTileEntity.getInputTier()),
true,
false,
@@ -88,9 +87,7 @@ public class GT_MetaTileEntity_Charger extends GT_MetaTileEntity_BasicBatteryBuf
}
if (mMetaTileEntity.rechargerSlotCount() > 0 && mBaseMetaTileEntity.getStoredEU() > 0) {
for (int i = mMetaTileEntity.rechargerSlotStartIndex(),
- k = mMetaTileEntity.rechargerSlotCount() + i;
- i < k;
- i++) {
+ k = mMetaTileEntity.rechargerSlotCount() + i; i < k; i++) {
if (mBaseMetaTileEntity.getStoredEU() > 0 && mMetaTileEntity.mInventory[i] != null) {
mBaseMetaTileEntity.decreaseStoredEU(
GT_ModHandler.chargeElectricItem(
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_CuringOven.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_CuringOven.java
index 3dc9fd7b63..2cab223249 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_CuringOven.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_CuringOven.java
@@ -1,7 +1,12 @@
package gregtech.common.tileentities.machines.basic;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
+
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.ITexture;
@@ -11,9 +16,6 @@ import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicMachine;
import gregtech.api.render.TextureFactory;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_CuringOven extends GT_MetaTileEntity_BasicMachine implements IAddUIWidgets {
@@ -29,43 +31,43 @@ public class GT_MetaTileEntity_CuringOven extends GT_MetaTileEntity_BasicMachine
1,
"E_Oven.png",
"",
- TextureFactory.of(
- new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_SIDE_ACTIVE")),
+ TextureFactory
+ .of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_SIDE_ACTIVE")),
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_SIDE")),
- TextureFactory.of(
- new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_FRONT_ACTIVE")),
+ TextureFactory
+ .of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_FRONT_ACTIVE")),
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_FRONT")),
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_TOP_ACTIVE")),
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_TOP")),
- TextureFactory.of(
- new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_BOTTOM_ACTIVE")),
+ TextureFactory
+ .of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_BOTTOM_ACTIVE")),
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/ELECTRIC_OVEN/OVERLAY_BOTTOM")));
}
- public GT_MetaTileEntity_CuringOven(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_CuringOven(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_CuringOven(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_CuringOven(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_CuringOven(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return (super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack))
&& ItemList.Cell_Empty.isStackEqual(aStack);
}
@@ -78,36 +80,34 @@ public class GT_MetaTileEntity_CuringOven extends GT_MetaTileEntity_BasicMachine
@Override
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
if (aBaseMetaTileEntity.isServerSide()) {
- for (ItemStack tStack : mInventory)
- if (tStack != null
- && tStack.getItem() instanceof GT_MetaGenerated_Tool
- && getBaseMetaTileEntity().getStoredEU() > 0) {
- getBaseMetaTileEntity().decreaseStoredEnergyUnits(24, true);
- NBTTagCompound aNBT = tStack.getTagCompound();
- if (aNBT != null) {
- int tHeat = 300;
- long tWorldTime = getBaseMetaTileEntity().getWorld().getTotalWorldTime();
- aNBT = aNBT.getCompoundTag("GT.ToolStats");
- if (aNBT != null && aNBT.hasKey("Heat")) {
- tHeat = aNBT.getInteger("Heat");
- if (aNBT.hasKey("HeatTime")) {
- long tHeatTime = aNBT.getLong("HeatTime");
- if (tWorldTime > (tHeatTime + 10)) {
- tHeat = (int) (tHeat - ((tWorldTime - tHeatTime) / 10));
- if (tHeat < 300) tHeat = 300;
+ for (ItemStack tStack : mInventory) if (tStack != null && tStack.getItem() instanceof GT_MetaGenerated_Tool
+ && getBaseMetaTileEntity().getStoredEU() > 0) {
+ getBaseMetaTileEntity().decreaseStoredEnergyUnits(24, true);
+ NBTTagCompound aNBT = tStack.getTagCompound();
+ if (aNBT != null) {
+ int tHeat = 300;
+ long tWorldTime = getBaseMetaTileEntity().getWorld().getTotalWorldTime();
+ aNBT = aNBT.getCompoundTag("GT.ToolStats");
+ if (aNBT != null && aNBT.hasKey("Heat")) {
+ tHeat = aNBT.getInteger("Heat");
+ if (aNBT.hasKey("HeatTime")) {
+ long tHeatTime = aNBT.getLong("HeatTime");
+ if (tWorldTime > (tHeatTime + 10)) {
+ tHeat = (int) (tHeat - ((tWorldTime - tHeatTime) / 10));
+ if (tHeat < 300) tHeat = 300;
+ }
}
}
- }
- tHeat++;
- if (aNBT != null) {
- aNBT.setInteger("Heat", tHeat);
- aNBT.setLong("HeatTime", tWorldTime);
- }
- if (tHeat > GT_MetaGenerated_Tool.getPrimaryMaterial(tStack).mMeltingPoint) {
- mInventory[0] = null;
+ tHeat++;
+ if (aNBT != null) {
+ aNBT.setInteger("Heat", tHeat);
+ aNBT.setLong("HeatTime", tWorldTime);
+ }
+ if (tHeat > GT_MetaGenerated_Tool.getPrimaryMaterial(tStack).mMeltingPoint) {
+ mInventory[0] = null;
+ }
}
}
- }
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Disassembler.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Disassembler.java
index ff46aada64..bc6f50fde6 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Disassembler.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Disassembler.java
@@ -3,7 +3,19 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.GT_Values.MOD_ID_RC;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.*;
+import java.util.concurrent.atomic.AtomicInteger;
+import java.util.concurrent.atomic.AtomicReference;
+import java.util.stream.Collectors;
+import java.util.stream.IntStream;
+
+import net.minecraft.init.Blocks;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.oredict.OreDictionary;
+
import com.google.common.collect.ArrayListMultimap;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.ItemList;
@@ -25,15 +37,6 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.extensions.ArrayExt;
import ic2.api.item.IC2Items;
-import java.util.*;
-import java.util.concurrent.atomic.AtomicInteger;
-import java.util.concurrent.atomic.AtomicReference;
-import java.util.stream.Collectors;
-import java.util.stream.IntStream;
-import net.minecraft.init.Blocks;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.oredict.OreDictionary;
public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachine {
@@ -45,9 +48,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
aTier,
1,
new String[] {
- "Disassembles Machines up to " + GT_Values.TIER_COLORS[aTier] + GT_Values.VOLTAGE_NAMES[aTier],
- "Can also disassemble most assembler recipes!"
- },
+ "Disassembles Machines up to " + GT_Values.TIER_COLORS[aTier] + GT_Values.VOLTAGE_NAMES[aTier],
+ "Can also disassemble most assembler recipes!" },
1,
9,
"Disassembler.png",
@@ -56,101 +58,65 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
// Textures
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_DISASSEMBLER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_DISASSEMBLER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_DISASSEMBLER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_DISASSEMBLER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_DISASSEMBLER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_DISASSEMBLER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_DISASSEMBLER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DISASSEMBLER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DISASSEMBLER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_DISASSEMBLER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DISASSEMBLER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DISASSEMBLER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_DISASSEMBLER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_DISASSEMBLER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_DISASSEMBLER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_DISASSEMBLER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_DISASSEMBLER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_DISASSEMBLER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_DISASSEMBLER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_DISASSEMBLER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_DISASSEMBLER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_DISASSEMBLER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_DISASSEMBLER_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_DISASSEMBLER_GLOW).glow().build()));
}
- public GT_MetaTileEntity_Disassembler(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Disassembler(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 9, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_Disassembler(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_Disassembler(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 9, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Disassembler(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
- private static final ItemStack[][] alwaysReplace = {
- {
+ private static final ItemStack[][] alwaysReplace = { {
// ItemStack to look for
- new ItemStack(Blocks.trapped_chest, 1, OreDictionary.WILDCARD_VALUE)
- },
- {
- // ItemStack to replace
- new ItemStack(Blocks.chest)
- }
- };
+ new ItemStack(Blocks.trapped_chest, 1, OreDictionary.WILDCARD_VALUE) },
+ {
+ // ItemStack to replace
+ new ItemStack(Blocks.chest) } };
- private static final Object[][] OreDictionaryOverride = {
- {
+ private static final Object[][] OreDictionaryOverride = { {
// String to look for
- "plankWood", "stoneCobble", "gemDiamond", "logWood", "stickWood", "treeSapling"
- },
- {
- // ItemStack to replace
- new ItemStack(Blocks.planks),
- new ItemStack(Blocks.cobblestone),
- new ItemStack(Items.diamond),
- new ItemStack(Blocks.log),
- new ItemStack(Items.stick),
- new ItemStack(Blocks.sapling)
- }
- };
+ "plankWood", "stoneCobble", "gemDiamond", "logWood", "stickWood", "treeSapling" },
+ {
+ // ItemStack to replace
+ new ItemStack(Blocks.planks), new ItemStack(Blocks.cobblestone), new ItemStack(Items.diamond),
+ new ItemStack(Blocks.log), new ItemStack(Items.stick), new ItemStack(Blocks.sapling) } };
public static ArrayListMultimap<GT_ItemStack, ItemStack> getOutputHardOverrides() {
return outputHardOverrides;
@@ -215,10 +181,10 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
if (GT_Utility.isStackInvalid(is)) return DID_NOT_FIND_RECIPE;
- if (is.getItem() instanceof GT_MetaGenerated_Tool
- || isCircuit(is)
+ if (is.getItem() instanceof GT_MetaGenerated_Tool || isCircuit(is)
|| blackList.stream().anyMatch(t -> GT_Utility.areStacksEqual(t.toStack(), is, true))
- || compareToUnpacker(is)) return DID_NOT_FIND_RECIPE;
+ || compareToUnpacker(is))
+ return DID_NOT_FIND_RECIPE;
Integer handleHardOverride = handleHardOverride(is);
if (handleHardOverride != null) return handleHardOverride;
@@ -270,8 +236,7 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
}
- return setOutputsAndTime(recipe.inputs, recipe.stackSize)
- ? FOUND_AND_SUCCESSFULLY_USED_RECIPE
+ return setOutputsAndTime(recipe.inputs, recipe.stackSize) ? FOUND_AND_SUCCESSFULLY_USED_RECIPE
: FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
}
@@ -283,8 +248,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
}
private int checkRecipeMap() {
- GT_Recipe gt_recipe = GT_Recipe.GT_Recipe_Map.sDisassemblerRecipes.findRecipe(
- this.getBaseMetaTileEntity(), true, this.maxEUInput(), null, this.getAllInputs());
+ GT_Recipe gt_recipe = GT_Recipe.GT_Recipe_Map.sDisassemblerRecipes
+ .findRecipe(this.getBaseMetaTileEntity(), true, this.maxEUInput(), null, this.getAllInputs());
if (gt_recipe == null) return DID_NOT_FIND_RECIPE;
if (gt_recipe.isRecipeInputEqual(false, null, this.getAllInputs())) {
if (gt_recipe.mSpecialValue == -100) {
@@ -323,8 +288,7 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
ItemStack[] output = new ItemStack[inputs.length];
List<GT_Recipe> recipesColl = null;
- if (recipes.size() > 1)
- recipesColl = recipes.stream().skip(1).map(x -> x.recipe).collect(Collectors.toList());
+ if (recipes.size() > 1) recipesColl = recipes.stream().skip(1).map(x -> x.recipe).collect(Collectors.toList());
handleRecipeTransformation(inputs, output, recipesColl);
@@ -335,8 +299,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
EUt);
}
- private static void handleRecipeTransformation(
- ItemStack[] inputs, ItemStack[] output, List<? extends GT_Recipe> recipesColl) {
+ private static void handleRecipeTransformation(ItemStack[] inputs, ItemStack[] output,
+ List<? extends GT_Recipe> recipesColl) {
for (int i = 0, inputsLength = inputs.length; i < inputsLength; i++) {
Set<ItemStack[]> inputsStacks = null;
if (recipesColl != null)
@@ -349,15 +313,15 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
/**
* Public Interface for ReverseRecipes, do not call inside of this class.
*/
- public static void handleRecipeTransformation(
- ItemStack[] inputs, ItemStack[] output, Set<ItemStack[]> inputsStacks) {
+ public static void handleRecipeTransformation(ItemStack[] inputs, ItemStack[] output,
+ Set<ItemStack[]> inputsStacks) {
for (int i = 0, inputsLength = inputs.length; i < inputsLength; i++)
handleRecipeTransformationInternal(inputs, output, inputsStacks, i);
addOthersAndHandleAlwaysReplace(inputs, output);
}
- private static void handleRecipeTransformationInternal(
- ItemStack[] inputs, ItemStack[] output, Set<ItemStack[]> inputsStacks, int i) {
+ private static void handleRecipeTransformationInternal(ItemStack[] inputs, ItemStack[] output,
+ Set<ItemStack[]> inputsStacks, int i) {
ItemStack input = inputs[i];
ItemData data = GT_OreDictUnificator.getItemData(input);
if (data == null || data.mMaterial == null || data.mMaterial.mMaterial == null || data.mPrefix == null) {
@@ -405,9 +369,7 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
}
private static ItemStack handleWildcard(ItemStack stack) {
- if (stack != null
- && stack.getItemDamage() == OreDictionary.WILDCARD_VALUE
- && !stack.getItem().isDamageable()) {
+ if (stack != null && stack.getItemDamage() == OreDictionary.WILDCARD_VALUE && !stack.getItem().isDamageable()) {
stack.setItemDamage(0);
}
return stack;
@@ -420,8 +382,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
return stack;
}
- private static void handleReplacement(
- Set<ItemStack[]> inputsStacks, ItemData data, ItemStack[] output, ItemStack input, int i) {
+ private static void handleReplacement(Set<ItemStack[]> inputsStacks, ItemData data, ItemStack[] output,
+ ItemStack input, int i) {
AtomicReference<Materials> toRpl = new AtomicReference<>();
Materials first = data.mMaterial.mMaterial;
if (inputsStacks != null) {
@@ -440,17 +402,12 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
}
}
- private static void handleInputStacks(
- Set<ItemStack[]> inputsStacks,
- AtomicReference<? super Materials> toRpl,
- ItemData data,
- Materials first,
- int i) {
+ private static void handleInputStacks(Set<ItemStack[]> inputsStacks, AtomicReference<? super Materials> toRpl,
+ ItemData data, Materials first, int i) {
final int finalIndex = i;
inputsStacks.forEach(stackArray -> {
ItemData dataAgainst = GT_OreDictUnificator.getItemData(stackArray[finalIndex]);
- if (dataAgainst == null
- || dataAgainst.mMaterial == null
+ if (dataAgainst == null || dataAgainst.mMaterial == null
|| dataAgainst.mMaterial.mMaterial == null
|| dataAgainst.mPrefix == null
|| dataAgainst.mPrefix != data.mPrefix) {
@@ -473,8 +430,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
toRpl.set(Materials.Rubber);
}
- private static void handleDifferentMaterialsOnRecipes(
- Materials first, Materials second, AtomicReference<? super Materials> toRpl) {
+ private static void handleDifferentMaterialsOnRecipes(Materials first, Materials second,
+ AtomicReference<? super Materials> toRpl) {
if (!first.equals(second))
if (first.equals(Materials.Aluminium) && second.equals(Materials.Iron)) toRpl.set(second);
else if (first.equals(Materials.Steel) && second.equals(Materials.Iron)) toRpl.set(second);
@@ -488,7 +445,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
else if (first.equals(Materials.Polystyrene) && second.equals(Materials.Plastic)) toRpl.set(second);
else if (first.equals(Materials.Silicone) && second.equals(Materials.Plastic)) toRpl.set(second);
else if (first.equals(Materials.NetherQuartz)
- || first.equals(Materials.CertusQuartz) && second.equals(Materials.Quartzite)) toRpl.set(second);
+ || first.equals(Materials.CertusQuartz) && second.equals(Materials.Quartzite))
+ toRpl.set(second);
else if (first.equals(Materials.Plastic) && second.equals(Materials.Wood)) toRpl.set(second);
else if (first.equals(Materials.Diamond) && second.equals(Materials.Glass)) toRpl.set(second);
}
@@ -523,6 +481,7 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
}
static class DissassembleReference {
+
final int stackSize;
ItemStack[] inputs;
final GT_Recipe recipe;
@@ -560,9 +519,7 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
boolean isDone = GT_Utility.areStacksEqual(y, out, true) && y.stackSize <= is.stackSize;
if (isDone) stacksize.set(y.stackSize);
return isDone;
- }))
- .map(x -> new DissassembleReference(stacksize.get(), x.mInputs, x))
- .collect(Collectors.toList());
+ })).map(x -> new DissassembleReference(stacksize.get(), x.mInputs, x)).collect(Collectors.toList());
// Is there only one way to create it?
if (possibleRecipes.size() == 1) return possibleRecipes;
@@ -575,21 +532,15 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
}
private static double getCheaperInputs(GT_MetaTileEntity_Disassembler.DissassembleReference x) {
- double fluidInputValueRaw = Arrays.stream(x.recipe.mFluidInputs)
- .flatMapToInt(f -> IntStream.of(f.amount))
+ double fluidInputValueRaw = Arrays.stream(x.recipe.mFluidInputs).flatMapToInt(f -> IntStream.of(f.amount))
.sum();
fluidInputValueRaw = fluidInputValueRaw > 0 ? fluidInputValueRaw : 144D;
- double inputValue = Arrays.stream(x.inputs)
- .flatMapToInt(f -> IntStream.of(f.stackSize))
- .sum()
+ double inputValue = Arrays.stream(x.inputs).flatMapToInt(f -> IntStream.of(f.stackSize)).sum()
+ (fluidInputValueRaw / 144D);
- double fluidOutputValueRaw = Arrays.stream(x.recipe.mFluidOutputs)
- .flatMapToInt(f -> IntStream.of(f.amount))
+ double fluidOutputValueRaw = Arrays.stream(x.recipe.mFluidOutputs).flatMapToInt(f -> IntStream.of(f.amount))
.sum();
fluidOutputValueRaw = fluidOutputValueRaw > 0 ? fluidOutputValueRaw : 144D;
- double outputValue = Arrays.stream(x.recipe.mOutputs)
- .flatMapToInt(f -> IntStream.of(f.stackSize))
- .sum()
+ double outputValue = Arrays.stream(x.recipe.mOutputs).flatMapToInt(f -> IntStream.of(f.stackSize)).sum()
+ (fluidOutputValueRaw / 144D);
return outputValue / inputValue;
}
@@ -599,8 +550,8 @@ public class GT_MetaTileEntity_Disassembler extends GT_MetaTileEntity_BasicMachi
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& aStack.getTagCompound() != null
&& aStack.getTagCompound().getCompoundTag("GT.CraftingComponents") != null;
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java
index 516d2dda66..a75876b82d 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_IndustrialApiary.java
@@ -8,6 +8,27 @@ import static gregtech.api.metatileentity.BaseTileEntity.STALLED_STUTTERING_TOOL
import static gregtech.api.metatileentity.BaseTileEntity.TOOLTIP_DELAY;
import static gregtech.api.util.GT_Utility.moveMultipleItemStacks;
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.io.IOException;
+import java.lang.reflect.Field;
+import java.util.*;
+import java.util.stream.Collectors;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.inventory.Slot;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.ChunkCoordinates;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraft.util.Vec3;
+import net.minecraft.world.World;
+import net.minecraft.world.biome.BiomeGenBase;
+
import com.google.common.collect.ImmutableSet;
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
import com.gtnewhorizons.modularui.api.forge.IItemHandlerModifiable;
@@ -27,6 +48,7 @@ import com.gtnewhorizons.modularui.common.widget.SlotGroup;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
import com.mojang.authlib.GameProfile;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import forestry.api.apiculture.*;
@@ -52,25 +74,6 @@ import gregtech.api.util.GT_ApiaryModifier;
import gregtech.api.util.GT_ApiaryUpgrade;
import gregtech.api.util.GT_Utility;
import gregtech.common.GT_Client;
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.lang.reflect.Field;
-import java.util.*;
-import java.util.stream.Collectors;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.inventory.Slot;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ChunkCoordinates;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraft.util.Vec3;
-import net.minecraft.world.World;
-import net.minecraft.world.biome.BiomeGenBase;
public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicMachine
implements IBeeHousing, IBeeHousingInventory, IErrorLogic, IBeeModifier, IBeeListener, IAddUIWidgets {
@@ -97,80 +100,56 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
aNameRegional,
aTier,
4,
- new String[] {"BEES GOES BRRRR", EnumChatFormatting.GRAY + AuthorKuba},
+ new String[] { "BEES GOES BRRRR", EnumChatFormatting.GRAY + AuthorKuba },
6,
9,
"IndustrialApiary.png",
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_INDUSTRIAL_APIARY_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_INDUSTRIAL_APIARY_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_INDUSTRIAL_APIARY_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_INDUSTRIAL_APIARY),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_INDUSTRIAL_APIARY_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_INDUSTRIAL_APIARY_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_INDUSTRIAL_APIARY_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_INDUSTRIAL_APIARY_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_INDUSTRIAL_APIARY_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_INDUSTRIAL_APIARY),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_INDUSTRIAL_APIARY_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_INDUSTRIAL_APIARY_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_INDUSTRIAL_APIARY_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_INDUSTRIAL_APIARY_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_INDUSTRIAL_APIARY_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_INDUSTRIAL_APIARY),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_INDUSTRIAL_APIARY_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_INDUSTRIAL_APIARY_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_INDUSTRIAL_APIARY_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_INDUSTRIAL_APIARY_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_INDUSTRIAL_APIARY_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_INDUSTRIAL_APIARY),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_INDUSTRIAL_APIARY_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_INDUSTRIAL_APIARY_GLOW).glow().build()));
}
- public GT_MetaTileEntity_IndustrialApiary(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_IndustrialApiary(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 4, aDescription, aTextures, 6, 9, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_IndustrialApiary(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_IndustrialApiary(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 4, aDescription, aTextures, 6, 9, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_IndustrialApiary(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -252,13 +231,13 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
final HashMap<GT_Utility.ItemId, ItemStack> pollen = new HashMap<>();
if (isRetrievingPollen && floweringMod > 0f) {
- final int icycles =
- (int) cycles + (getWorld().rand.nextFloat() < (cycles - (float) ((int) cycles)) ? 1 : 0);
+ final int icycles = (int) cycles
+ + (getWorld().rand.nextFloat() < (cycles - (float) ((int) cycles)) ? 1 : 0);
for (int z = 0; z < icycles; z++) {
final IIndividual p = bee.retrievePollen(this);
if (p != null) {
- final ItemStack s =
- p.getGenome().getSpeciesRoot().getMemberStack(p, EnumGermlingType.POLLEN.ordinal());
+ final ItemStack s = p.getGenome().getSpeciesRoot()
+ .getMemberStack(p, EnumGermlingType.POLLEN.ordinal());
if (s != null) {
final GT_Utility.ItemId id = GT_Utility.ItemId.createNoCopy(s);
pollen.computeIfAbsent(id, k -> {
@@ -285,19 +264,16 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
final HashMap<GT_Utility.ItemId, Float> drops = new HashMap<>();
final HashMap<GT_Utility.ItemId, ItemStack> dropstacks = new HashMap<>();
- for (Map.Entry<ItemStack, Float> entry :
- primary.getProductChances().entrySet()) {
+ for (Map.Entry<ItemStack, Float> entry : primary.getProductChances().entrySet()) {
final GT_Utility.ItemId id = GT_Utility.ItemId.createNoCopy(entry.getKey());
drops.merge(
id,
- Bee.getFinalChance(entry.getValue(), speed, prodMod, 8f)
- * (float) entry.getKey().stackSize
+ Bee.getFinalChance(entry.getValue(), speed, prodMod, 8f) * (float) entry.getKey().stackSize
* cycles,
Float::sum);
dropstacks.computeIfAbsent(id, k -> entry.getKey());
}
- for (Map.Entry<ItemStack, Float> entry :
- secondary.getProductChances().entrySet()) {
+ for (Map.Entry<ItemStack, Float> entry : secondary.getProductChances().entrySet()) {
final GT_Utility.ItemId id = GT_Utility.ItemId.createNoCopy(entry.getKey());
drops.merge(
id,
@@ -308,8 +284,7 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
dropstacks.computeIfAbsent(id, k -> entry.getKey());
}
if (primary.isJubilant(genome, this) && secondary.isJubilant(genome, this))
- for (Map.Entry<ItemStack, Float> entry :
- primary.getSpecialtyChances().entrySet()) {
+ for (Map.Entry<ItemStack, Float> entry : primary.getSpecialtyChances().entrySet()) {
final GT_Utility.ItemId id = GT_Utility.ItemId.createNoCopy(entry.getKey());
drops.merge(
id,
@@ -361,24 +336,20 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
for (Map.Entry<GT_Utility.ItemId, Float> entry : drops.entrySet()) {
final ItemStack s = dropstacks.get(entry.getKey()).copy();
s.stackSize = entry.getValue().intValue()
- + (getWorld().rand.nextFloat()
- < (entry.getValue()
- - (float) entry.getValue().intValue())
+ + (getWorld().rand.nextFloat() < (entry.getValue() - (float) entry.getValue().intValue())
? 1
: 0);
- if (s.stackSize > 0 && i < imax)
- while (true) {
- if (s.stackSize <= s.getMaxStackSize()) {
- this.mOutputItems[i++] = s;
- break;
- } else this.mOutputItems[i++] = s.splitStack(s.getMaxStackSize());
- if (i >= imax) break;
- }
+ if (s.stackSize > 0 && i < imax) while (true) {
+ if (s.stackSize <= s.getMaxStackSize()) {
+ this.mOutputItems[i++] = s;
+ break;
+ } else this.mOutputItems[i++] = s.splitStack(s.getMaxStackSize());
+ if (i >= imax) break;
+ }
}
- for (ItemStack s : pollen.values())
- if (i < imax) this.mOutputItems[i++] = s;
- else break;
+ for (ItemStack s : pollen.values()) if (i < imax) this.mOutputItems[i++] = s;
+ else break;
// Overclock
@@ -475,15 +446,13 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
}
if (effect instanceof IAlleleBeeAcceleratableEffect) {
effectData[0] = effect.validateStorage(effectData[0]);
- effectData[0] = ((IAlleleBeeAcceleratableEffect) effect)
- .doEffectAccelerated(
- genome,
- effectData[0],
- this,
- usedBeeLife
- / (effect instanceof AlleleEffectThrottled
- ? (float) AlleleBeeEffectThrottledField.getInt(effect)
- : 1f));
+ effectData[0] = ((IAlleleBeeAcceleratableEffect) effect).doEffectAccelerated(
+ genome,
+ effectData[0],
+ this,
+ usedBeeLife / (effect instanceof AlleleEffectThrottled
+ ? (float) AlleleBeeEffectThrottledField.getInt(effect)
+ : 1f));
}
if (!effect.isCombinable()) return;
@@ -493,15 +462,13 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
if (secondary instanceof IAlleleBeeAcceleratableEffect) {
effectData[1] = secondary.validateStorage(effectData[1]);
- effectData[1] = ((IAlleleBeeAcceleratableEffect) secondary)
- .doEffectAccelerated(
- genome,
- effectData[0],
- this,
- usedBeeLife
- / (secondary instanceof AlleleEffectThrottled
- ? (float) AlleleBeeEffectThrottledField.getInt(secondary)
- : 1f));
+ effectData[1] = ((IAlleleBeeAcceleratableEffect) secondary).doEffectAccelerated(
+ genome,
+ effectData[0],
+ this,
+ usedBeeLife / (secondary instanceof AlleleEffectThrottled
+ ? (float) AlleleBeeEffectThrottledField.getInt(secondary)
+ : 1f));
}
} catch (Exception ex) {
ex.printStackTrace();
@@ -512,9 +479,10 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
if (aBaseMetaTileEntity.isClientSide()) {
if (GT_Client.changeDetected == 4) {
- /* Client tick counter that is set to 5 on hiding pipes and covers.
- * It triggers a texture update next client tick when reaching 4, with provision for 3 more update tasks,
- * spreading client change detection related work and network traffic on different ticks, until it reaches 0.
+ /*
+ * Client tick counter that is set to 5 on hiding pipes and covers. It triggers a texture update next
+ * client tick when reaching 4, with provision for 3 more update tasks, spreading client change
+ * detection related work and network traffic on different ticks, until it reaches 0.
*/
aBaseMetaTileEntity.issueTextureUpdate();
}
@@ -537,8 +505,7 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
if (!aBaseMetaTileEntity.isActive()) {
if (aBaseMetaTileEntity.isAllowedToWork()
- && (aBaseMetaTileEntity.hasInventoryBeenModified()
- || aTick % 600 == 0
+ && (aBaseMetaTileEntity.hasInventoryBeenModified() || aTick % 600 == 0
|| aBaseMetaTileEntity.hasWorkJustBeenEnabled())
&& hasEnoughEnergyToCheckRecipe()) {
final int check = checkRecipe();
@@ -572,13 +539,12 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
if (usedQueen != null) {
if (usedQueenBee == null) usedQueenBee = beeRoot.getMember(usedQueen);
doEffect();
- if (!retrievingPollenInThisOperation
- && floweringMod > 0f
+ if (!retrievingPollenInThisOperation && floweringMod > 0f
&& this.mProgresstime % pollinationDelay == 0) {
if (retrievedpollen == null) retrievedpollen = usedQueenBee.retrievePollen(this);
- if (retrievedpollen != null
- && (usedQueenBee.pollinateRandom(this, retrievedpollen)
- || this.mProgresstime % (pollinationDelay * 5) == 0)) retrievedpollen = null;
+ if (retrievedpollen != null && (usedQueenBee.pollinateRandom(this, retrievedpollen)
+ || this.mProgresstime % (pollinationDelay * 5) == 0))
+ retrievedpollen = null;
}
}
@@ -593,21 +559,20 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
if (usedQueenBee != null) doAcceleratedEffects();
updateModifiers();
for (int i = 0; i < mOutputItems.length; i++)
- if (mOutputItems[i] != null)
- for (int j = 0; j < mOutputItems.length; j++) {
- if (j == 0 && isAutomated) {
- if (beeRoot.isMember(mOutputItems[i], EnumBeeType.QUEEN.ordinal())
- || beeRoot.isMember(mOutputItems[i], EnumBeeType.PRINCESS.ordinal())) {
- if (aBaseMetaTileEntity.addStackToSlot(queen, mOutputItems[i])) break;
- } else if (beeRoot.isMember(mOutputItems[i], EnumBeeType.DRONE.ordinal()))
- if (aBaseMetaTileEntity.addStackToSlot(drone, mOutputItems[i])) break;
- } else if (i == 0
- && j == 0
- && beeRoot.isMember(mOutputItems[0], EnumBeeType.QUEEN.ordinal()))
+ if (mOutputItems[i] != null) for (int j = 0; j < mOutputItems.length; j++) {
+ if (j == 0 && isAutomated) {
+ if (beeRoot.isMember(mOutputItems[i], EnumBeeType.QUEEN.ordinal())
+ || beeRoot.isMember(mOutputItems[i], EnumBeeType.PRINCESS.ordinal())) {
+ if (aBaseMetaTileEntity.addStackToSlot(queen, mOutputItems[i])) break;
+ } else if (beeRoot.isMember(mOutputItems[i], EnumBeeType.DRONE.ordinal()))
+ if (aBaseMetaTileEntity.addStackToSlot(drone, mOutputItems[i])) break;
+ } else
+ if (i == 0 && j == 0 && beeRoot.isMember(mOutputItems[0], EnumBeeType.QUEEN.ordinal()))
if (aBaseMetaTileEntity.addStackToSlot(queen, mOutputItems[0])) break;
- if (aBaseMetaTileEntity.addStackToSlot(
- getOutputSlot() + ((j + i) % mOutputItems.length), mOutputItems[i])) break;
- }
+ if (aBaseMetaTileEntity
+ .addStackToSlot(getOutputSlot() + ((j + i) % mOutputItems.length), mOutputItems[i]))
+ break;
+ }
Arrays.fill(mOutputItems, null);
mEUt = 0;
mProgresstime = 0;
@@ -616,8 +581,8 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
aBaseMetaTileEntity.setActive(false);
if (doesAutoOutput() && !isOutputEmpty() && aBaseMetaTileEntity.getFrontFacing() != mMainFacing) {
- final TileEntity tTileEntity2 =
- aBaseMetaTileEntity.getTileEntityAtSide(aBaseMetaTileEntity.getFrontFacing());
+ final TileEntity tTileEntity2 = aBaseMetaTileEntity
+ .getTileEntityAtSide(aBaseMetaTileEntity.getFrontFacing());
final long tStoredEnergy = aBaseMetaTileEntity.getUniversalEnergyStored();
int tMaxStacks = (int) (tStoredEnergy / 64L);
if (tMaxStacks > mOutputItems.length) tMaxStacks = mOutputItems.length;
@@ -644,8 +609,7 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
}
public void cancelProcess() {
- if (this.getBaseMetaTileEntity().isActive()
- && this.getBaseMetaTileEntity().isServerSide()
+ if (this.getBaseMetaTileEntity().isActive() && this.getBaseMetaTileEntity().isServerSide()
&& usedQueen != null
&& beeRoot.isMember(usedQueen, EnumBeeType.QUEEN.ordinal())) {
Arrays.fill(mOutputItems, null);
@@ -663,9 +627,8 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
public boolean isItemValidForSlot(int aIndex, ItemStack aStack) {
if (aStack == null) return false;
if (aIndex < getInputSlot()) return true;
- if (aIndex == queen)
- return beeRoot.isMember(aStack, EnumBeeType.QUEEN.ordinal())
- || beeRoot.isMember(aStack, EnumBeeType.PRINCESS.ordinal());
+ if (aIndex == queen) return beeRoot.isMember(aStack, EnumBeeType.QUEEN.ordinal())
+ || beeRoot.isMember(aStack, EnumBeeType.PRINCESS.ordinal());
else if (aIndex == drone) return beeRoot.isMember(aStack, EnumBeeType.DRONE.ordinal());
else if (aIndex < getOutputSlot()) {
if (!GT_ApiaryUpgrade.isUpgrade(aStack)) return false;
@@ -741,10 +704,9 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
@Override
public GameProfile getOwner() {
- if (owner == null)
- owner = new GameProfile(
- this.getBaseMetaTileEntity().getOwnerUuid(),
- this.getBaseMetaTileEntity().getOwnerName());
+ if (owner == null) owner = new GameProfile(
+ this.getBaseMetaTileEntity().getOwnerUuid(),
+ this.getBaseMetaTileEntity().getOwnerName());
return owner;
}
@@ -868,12 +830,16 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
|| getWorld().getBlockMetadata(flowercoords.posX, flowercoords.posY, flowercoords.posZ)
!= flowerBlockMeta)
if (!FlowerManager.flowerRegistry.isAcceptedFlower(
- flowerType, getWorld(), flowercoords.posX, flowercoords.posY, flowercoords.posZ))
+ flowerType,
+ getWorld(),
+ flowercoords.posX,
+ flowercoords.posY,
+ flowercoords.posZ))
flowercoords = null;
else {
flowerBlock = getWorld().getBlock(flowercoords.posX, flowercoords.posY, flowercoords.posZ);
- flowerBlockMeta =
- getWorld().getBlockMetadata(flowercoords.posX, flowercoords.posY, flowercoords.posZ);
+ flowerBlockMeta = getWorld()
+ .getBlockMetadata(flowercoords.posX, flowercoords.posY, flowercoords.posZ);
}
}
if (flowercoords == null) {
@@ -1044,6 +1010,7 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
// endregion
static final IBeekeepingLogic dummylogic = new IBeekeepingLogic() {
+
@Override
public boolean canWork() {
return true;
@@ -1093,103 +1060,86 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new SlotWidget(new ApiarySlot(inventoryHandler, queen))
+ builder.widget(
+ new SlotWidget(new ApiarySlot(inventoryHandler, queen))
.setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_BEE_QUEEN)
.setPos(36, 21))
- .widget(new SlotWidget(new ApiarySlot(inventoryHandler, drone))
- .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_BEE_DRONE)
- .setPos(36, 41))
- .widget(SlotGroup.ofItemHandler(inventoryHandler, 2)
- .startFromSlot(7)
- .endAtSlot(10)
- .slotCreator(i -> new ApiarySlot(inventoryHandler, i))
- .applyForWidget(widget -> widget.setGTTooltip(() -> mTooltipCache.getData(UPGRADE_TOOLTIP))
- .setTooltipShowUpDelay(TOOLTIP_DELAY))
- .build()
- .setPos(61, 23));
+ .widget(
+ new SlotWidget(new ApiarySlot(inventoryHandler, drone))
+ .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_BEE_DRONE)
+ .setPos(36, 41))
+ .widget(
+ SlotGroup.ofItemHandler(inventoryHandler, 2).startFromSlot(7).endAtSlot(10)
+ .slotCreator(i -> new ApiarySlot(inventoryHandler, i))
+ .applyForWidget(
+ widget -> widget.setGTTooltip(() -> mTooltipCache.getData(UPGRADE_TOOLTIP))
+ .setTooltipShowUpDelay(TOOLTIP_DELAY))
+ .build().setPos(61, 23));
super.addUIWidgets(builder, buildContext);
- builder.widget(new ProgressBar()
- .setProgress(() -> (float) getProgresstime() / Math.max(maxProgresstime(), 1))
- .setTexture(GT_UITextures.PROGRESSBAR_ARROW, 20)
- .setPos(70, 3)
- .setSize(20, 18))
- .widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> cancelProcess())
- .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_CROSS)
- .setGTTooltip(() -> mTooltipCache.getData(CANCEL_PROCESS_TOOLTIP))
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setPos(7, 26)
- .setSize(18, 18))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_INFORMATION)
- .setGTTooltip(() -> {
- final String energyreq = GT_Utility.formatNumbers(
- (int) ((float) GT_MetaTileEntity_IndustrialApiary.baseEUtUsage
- * getEnergyModifier()
- * getAcceleration())
- + getAdditionalEnergyUsage());
- final String Temp = StatCollector.translateToLocal(
- getTemperature().getName());
- final String Hum =
- StatCollector.translateToLocal(getHumidity().getName());
- if (getUsedQueen() != null
- && BeeManager.beeRoot.isMember(getUsedQueen(), EnumBeeType.QUEEN.ordinal())) {
- final IBee bee = BeeManager.beeRoot.getMember(getUsedQueen());
- if (bee.isAnalyzed()) {
- final IBeeGenome genome = bee.getGenome();
- final IBeeModifier mod = BeeManager.beeRoot
- .getBeekeepingMode(getWorld())
- .getBeeModifier();
- final float tmod =
- getTerritoryModifier(null, 1f) * mod.getTerritoryModifier(null, 1f);
- final int[] t = Arrays.stream(genome.getTerritory())
- .map(i -> (int) ((float) i * tmod))
- .toArray();
- return mTooltipCache.getUncachedTooltipData(
- INFO_WITH_BEE_TOOLTIP,
- energyreq,
- Temp,
- Hum,
- genome.getSpeed(),
- getProductionModifier(null, 1f) * mod.getProductionModifier(null, 1f),
- Math.round(getFloweringModifier(null, 1f)
- * genome.getFlowering()
+ builder.widget(
+ new ProgressBar().setProgress(() -> (float) getProgresstime() / Math.max(maxProgresstime(), 1))
+ .setTexture(GT_UITextures.PROGRESSBAR_ARROW, 20).setPos(70, 3).setSize(20, 18))
+ .widget(
+ new ButtonWidget().setOnClick((clickData, widget) -> cancelProcess())
+ .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_CROSS)
+ .setGTTooltip(() -> mTooltipCache.getData(CANCEL_PROCESS_TOOLTIP))
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setPos(7, 26).setSize(18, 18))
+ .widget(new DrawableWidget().setDrawable(GT_UITextures.PICTURE_INFORMATION).setGTTooltip(() -> {
+ final String energyreq = GT_Utility.formatNumbers(
+ (int) ((float) GT_MetaTileEntity_IndustrialApiary.baseEUtUsage * getEnergyModifier()
+ * getAcceleration()) + getAdditionalEnergyUsage());
+ final String Temp = StatCollector.translateToLocal(getTemperature().getName());
+ final String Hum = StatCollector.translateToLocal(getHumidity().getName());
+ if (getUsedQueen() != null
+ && BeeManager.beeRoot.isMember(getUsedQueen(), EnumBeeType.QUEEN.ordinal())) {
+ final IBee bee = BeeManager.beeRoot.getMember(getUsedQueen());
+ if (bee.isAnalyzed()) {
+ final IBeeGenome genome = bee.getGenome();
+ final IBeeModifier mod = BeeManager.beeRoot.getBeekeepingMode(getWorld()).getBeeModifier();
+ final float tmod = getTerritoryModifier(null, 1f) * mod.getTerritoryModifier(null, 1f);
+ final int[] t = Arrays.stream(genome.getTerritory()).map(i -> (int) ((float) i * tmod))
+ .toArray();
+ return mTooltipCache.getUncachedTooltipData(
+ INFO_WITH_BEE_TOOLTIP,
+ energyreq,
+ Temp,
+ Hum,
+ genome.getSpeed(),
+ getProductionModifier(null, 1f) * mod.getProductionModifier(null, 1f),
+ Math.round(
+ getFloweringModifier(null, 1f) * genome.getFlowering()
* mod.getFloweringModifier(null, 1f)),
- Math.round(getLifespanModifier(null, null, 1f)
- * genome.getLifespan()
+ Math.round(
+ getLifespanModifier(null, null, 1f) * genome.getLifespan()
* mod.getLifespanModifier(null, null, 1f)),
- t[0],
- t[1],
- t[2]);
- }
- }
- return mTooltipCache.getUncachedTooltipData(INFO_TOOLTIP, energyreq, Temp, Hum);
- })
- .attachSyncer(
- new FakeSyncWidget.ItemStackSyncer(() -> usedQueen, val -> usedQueen = val),
- builder,
- (widget, val) -> widget.notifyTooltipChange())
- .setPos(163, 5)
- .setSize(7, 18))
- .widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> {
- if (clickData.mouseButton == 0) {
- if (mLockedSpeed) return;
- if (!clickData.shift) {
- mSpeed++;
- if (mSpeed > getMaxSpeed()) mSpeed = 0;
- } else {
- mSpeed--;
- if (mSpeed < 0) mSpeed = getMaxSpeed();
- }
- } else if (clickData.mouseButton == 1) {
- mLockedSpeed = !mLockedSpeed;
- if (mLockedSpeed) mSpeed = getMaxSpeed();
- }
- })
- .setGTTooltip(() -> mTooltipCache.getUncachedTooltipData(
+ t[0],
+ t[1],
+ t[2]);
+ }
+ }
+ return mTooltipCache.getUncachedTooltipData(INFO_TOOLTIP, energyreq, Temp, Hum);
+ }).attachSyncer(
+ new FakeSyncWidget.ItemStackSyncer(() -> usedQueen, val -> usedQueen = val),
+ builder,
+ (widget, val) -> widget.notifyTooltipChange()).setPos(163, 5).setSize(7, 18))
+ .widget(new ButtonWidget().setOnClick((clickData, widget) -> {
+ if (clickData.mouseButton == 0) {
+ if (mLockedSpeed) return;
+ if (!clickData.shift) {
+ mSpeed++;
+ if (mSpeed > getMaxSpeed()) mSpeed = 0;
+ } else {
+ mSpeed--;
+ if (mSpeed < 0) mSpeed = getMaxSpeed();
+ }
+ } else if (clickData.mouseButton == 1) {
+ mLockedSpeed = !mLockedSpeed;
+ if (mLockedSpeed) mSpeed = getMaxSpeed();
+ }
+ }).setGTTooltip(
+ () -> mTooltipCache.getUncachedTooltipData(
mLockedSpeed ? SPEED_LOCKED_TOOLTIP : SPEED_TOOLTIP,
getAcceleration(),
GT_Utility.formatNumbers(getAdditionalEnergyUsage())))
@@ -1201,18 +1151,12 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
new FakeSyncWidget.BooleanSyncer(() -> mLockedSpeed, val -> mLockedSpeed = val),
builder,
(widget, val) -> widget.notifyTooltipChange())
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setBackground(GT_UITextures.PICTURE_SQUARE_LIGHT_GRAY)
- .setPos(25, 62)
- .setSize(18, 18))
- .widget(new TextWidget("x")
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(30, 63))
- .widget(TextWidget.dynamicString(() -> String.valueOf(1 << mSpeed))
- // mSpeed is already synced
- .setSynced(false)
- .setDefaultColor(COLOR_TEXT_GRAY.get())
- .setPos(26, 72));
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setBackground(GT_UITextures.PICTURE_SQUARE_LIGHT_GRAY)
+ .setPos(25, 62).setSize(18, 18))
+ .widget(new TextWidget("x").setDefaultColor(COLOR_TEXT_GRAY.get()).setPos(30, 63)).widget(
+ TextWidget.dynamicString(() -> String.valueOf(1 << mSpeed))
+ // mSpeed is already synced
+ .setSynced(false).setDefaultColor(COLOR_TEXT_GRAY.get()).setPos(26, 72));
}
@Override
@@ -1233,37 +1177,31 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
@Override
protected SlotWidget createChargerSlot(int x, int y, String tooltipKey, Object[] tooltipArgs) {
- return (SlotWidget)
- super.createChargerSlot(x, y, tooltipKey, tooltipArgs).setPos(79, 62);
+ return (SlotWidget) super.createChargerSlot(x, y, tooltipKey, tooltipArgs).setPos(79, 62);
}
@Override
protected DrawableWidget createErrorStatusArea(ModularWindow.Builder builder, IDrawable picture) {
- return (DrawableWidget) super.createErrorStatusArea(builder, picture)
- .setPos(100, 62)
- .attachSyncer(
- new FakeSyncWidget.ListSyncer<>(
- () -> Arrays.asList(mErrorStates.toArray(new IErrorState[0])),
- val -> {
- mErrorStates.clear();
- mErrorStates.addAll(new HashSet<>(val));
- },
- (buffer, val) -> buffer.writeShort(val.getID()),
- buffer -> ForestryAPI.errorStateRegistry.getErrorState(buffer.readShort())),
- builder,
- (widget, val) -> widget.notifyTooltipChange());
+ return (DrawableWidget) super.createErrorStatusArea(builder, picture).setPos(100, 62).attachSyncer(
+ new FakeSyncWidget.ListSyncer<>(() -> Arrays.asList(mErrorStates.toArray(new IErrorState[0])), val -> {
+ mErrorStates.clear();
+ mErrorStates.addAll(new HashSet<>(val));
+ },
+ (buffer, val) -> buffer.writeShort(val.getID()),
+ buffer -> ForestryAPI.errorStateRegistry.getErrorState(buffer.readShort())),
+ builder,
+ (widget, val) -> widget.notifyTooltipChange());
}
@Override
protected List<String> getErrorDescriptions() {
if (!mErrorStates.isEmpty()) {
- return mErrorStates.stream()
- .map(state ->
- EnumChatFormatting.RED + StatCollector.translateToLocal("for." + state.getDescription()))
+ return mErrorStates.stream().map(
+ state -> EnumChatFormatting.RED + StatCollector.translateToLocal("for." + state.getDescription()))
.collect(Collectors.toList());
} else if (mStuttering) {
- return mTooltipCache.getData(STALLED_STUTTERING_TOOLTIP, StatCollector.translateToLocal(POWER_SOURCE_POWER))
- .text;
+ return mTooltipCache
+ .getData(STALLED_STUTTERING_TOOLTIP, StatCollector.translateToLocal(POWER_SOURCE_POWER)).text;
} else {
return Collections.emptyList();
}
@@ -1306,8 +1244,8 @@ public class GT_MetaTileEntity_IndustrialApiary extends GT_MetaTileEntity_BasicM
}
}
- private static final UIInfo<?, ?> IndustrialApiaryUI =
- GT_UIInfos.GTTileEntityUIFactory.apply(GT_ModularUIContainer_IndustrialApiary::new);
+ private static final UIInfo<?, ?> IndustrialApiaryUI = GT_UIInfos.GTTileEntityUIFactory
+ .apply(GT_ModularUIContainer_IndustrialApiary::new);
private static class GT_ModularUIContainer_IndustrialApiary extends ModularUIContainer {
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Massfabricator.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Massfabricator.java
index b68d3bc436..d1c03e1527 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Massfabricator.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Massfabricator.java
@@ -3,6 +3,10 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.GT_Values.V;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.Arrays;
+
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.enums.ConfigCategories;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.ItemList;
@@ -17,10 +21,9 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.common.power.BasicMachineEUPower;
import gregtech.common.power.Power;
-import java.util.Arrays;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMachine {
+
public static int sUUAperUUM = 1;
public static int sUUASpeedBonus = 4;
public static int sDurationMultiplier = 3215;
@@ -41,68 +44,39 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_MASSFAB_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_MASSFAB_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_MASSFAB_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_MASSFAB),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_MASSFAB_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_MASSFAB_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_MASSFAB_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_MASSFAB_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_MASSFAB_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_MASSFAB),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_MASSFAB_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_MASSFAB_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_MASSFAB_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_MASSFAB_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_MASSFAB_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_MASSFAB),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_MASSFAB_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_MASSFAB_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_MASSFAB_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_MASSFAB_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_MASSFAB_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_MASSFAB),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_MASSFAB_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_MASSFAB_GLOW).glow().build()));
EUt = V[1] * (long) Math.pow(2, mTier + 2);
}
- public GT_MetaTileEntity_Massfabricator(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Massfabricator(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
EUt = V[1] * (long) Math.pow(2, mTier + 2);
}
- public GT_MetaTileEntity_Massfabricator(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_Massfabricator(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
EUt = V[1] * (long) Math.pow(2, mTier + 2);
}
@@ -110,7 +84,12 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Massfabricator(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -126,8 +105,8 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
@Override
public void onConfigLoad(GT_Config aConfig) {
super.onConfigLoad(aConfig);
- sDurationMultiplier = aConfig.get(
- ConfigCategories.machineconfig, "Massfabricator.UUM_Duration_Multiplier", sDurationMultiplier);
+ sDurationMultiplier = aConfig
+ .get(ConfigCategories.machineconfig, "Massfabricator.UUM_Duration_Multiplier", sDurationMultiplier);
sUUAperUUM = aConfig.get(ConfigCategories.machineconfig, "Massfabricator.UUA_per_UUM", sUUAperUUM);
sUUASpeedBonus = aConfig.get(ConfigCategories.machineconfig, "Massfabricator.UUA_Speed_Bonus", sUUASpeedBonus);
sRequiresUUA = aConfig.get(ConfigCategories.machineconfig, "Massfabricator.UUA_Requirement", sRequiresUUA);
@@ -159,11 +138,10 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
tFluid.amount -= sUUAperUUM;
return FOUND_AND_SUCCESSFULLY_USED_RECIPE;
}
- return sRequiresUUA
- || Arrays.stream(getAllInputs())
- .anyMatch(s -> ItemList.Circuit_Integrated.isStackEqual(s, true, true))
- ? FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS
- : FOUND_AND_SUCCESSFULLY_USED_RECIPE;
+ return sRequiresUUA || Arrays.stream(getAllInputs())
+ .anyMatch(s -> ItemList.Circuit_Integrated.isStackEqual(s, true, true))
+ ? FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS
+ : FOUND_AND_SUCCESSFULLY_USED_RECIPE;
}
return DID_NOT_FIND_RECIPE;
}
@@ -188,6 +166,7 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
}
protected class MassfabricatorPower extends BasicMachineEUPower {
+
protected MassfabricatorPower(byte tier, int amperage) {
super(tier, amperage);
}
@@ -204,7 +183,7 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
recipeEuPerTick = Integer.MAX_VALUE - 1;
recipeDuration = Integer.MAX_VALUE - 1;
} else {
- recipeEuPerTick = (int) (V[1] << 2); // 2^2=4 so shift <<2
+ recipeEuPerTick = (int) (V[1] << 2); // 2^2=4 so shift <<2
recipeDuration = (int) xMaxProgresstime;
}
} else {
@@ -218,9 +197,8 @@ public class GT_MetaTileEntity_Massfabricator extends GT_MetaTileEntity_BasicMac
while (tempEUt <= V[mTier - 1]) {
tempEUt <<= 2; // this actually controls overclocking
recipeDuration >>= 1; // this is effect of overclocking
- if (recipeDuration == 0)
- xEUt = (long) (xEUt
- / 1.1D); // U know, if the time is less than 1 tick make the machine use less power
+ if (recipeDuration == 0) xEUt = (long) (xEUt / 1.1D); // U know, if the time is less than 1 tick
+ // make the machine use less power
}
if (xEUt > Integer.MAX_VALUE - 1) {
recipeEuPerTick = Integer.MAX_VALUE - 1;
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MicrowaveEnergyTransmitter.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MicrowaveEnergyTransmitter.java
index 14a213b156..32a0ad8537 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MicrowaveEnergyTransmitter.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MicrowaveEnergyTransmitter.java
@@ -7,6 +7,16 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_ACTIVE;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_ACTIVE_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_GLOW;
+import java.util.function.Consumer;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.world.World;
+import net.minecraftforge.common.DimensionManager;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizons.modularui.api.drawable.IDrawable;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
@@ -14,6 +24,7 @@ import com.gtnewhorizons.modularui.common.widget.ButtonWidget;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.ConfigCategories;
import gregtech.api.enums.Materials;
@@ -31,14 +42,6 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicTank;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Config;
import gregtech.api.util.GT_Utility;
-import java.util.function.Consumer;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.world.World;
-import net.minecraftforge.common.DimensionManager;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEntity_BasicTank
implements IAddGregtechLogo, IAddUIWidgets {
@@ -60,21 +63,23 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
public TileEntity tTile = null;
public GT_MetaTileEntity_MicrowaveEnergyTransmitter(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 3, new String[] {
- "Transmits Energy Wirelessly",
- "Use Nitrogen Plasma",
- "for Inter-dimensional transmission",
- "0.004EU Loss per 100 Blocks"
- });
- }
-
- public GT_MetaTileEntity_MicrowaveEnergyTransmitter(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 3,
+ new String[] { "Transmits Energy Wirelessly", "Use Nitrogen Plasma",
+ "for Inter-dimensional transmission", "0.004EU Loss per 100 Blocks" });
+ }
+
+ public GT_MetaTileEntity_MicrowaveEnergyTransmitter(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, 3, aDescription, aTextures);
}
- public GT_MetaTileEntity_MicrowaveEnergyTransmitter(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_MicrowaveEnergyTransmitter(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, 3, aDescription, aTextures);
}
@@ -89,51 +94,36 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_MicrowaveEnergyTransmitter(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
public String[] getInfoData() {
- return new String[] {
- "Coordinates:",
- "X: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetX) + EnumChatFormatting.RESET,
- "Y: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetY) + EnumChatFormatting.RESET,
- "Z: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetZ) + EnumChatFormatting.RESET,
- "Dimension: " + EnumChatFormatting.GREEN + this.mTargetD + EnumChatFormatting.RESET,
- "Dimension Valid: "
- + (GT_Utility.isRealDimension(this.mTargetD)
- ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
- : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET),
- "Dimension Registered: "
- + (DimensionManager.isDimensionRegistered(this.mTargetD)
- ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
- : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET)
- };
- }
-
- @Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide == 0) return new ITexture[] {MACHINE_CASINGS[mTier][aColorIndex + 1]};
- if (aActive)
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
+ return new String[] { "Coordinates:",
+ "X: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetX) + EnumChatFormatting.RESET,
+ "Y: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetY) + EnumChatFormatting.RESET,
+ "Z: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetZ) + EnumChatFormatting.RESET,
+ "Dimension: " + EnumChatFormatting.GREEN + this.mTargetD + EnumChatFormatting.RESET,
+ "Dimension Valid: " + (GT_Utility.isRealDimension(this.mTargetD)
+ ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
+ : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET),
+ "Dimension Registered: " + (DimensionManager.isDimensionRegistered(this.mTargetD)
+ ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
+ : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET) };
+ }
+
+ @Override
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide == 0) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1] };
+ if (aActive) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
TextureFactory.of(OVERLAY_TELEPORTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(OVERLAY_TELEPORTER),
- TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).glow().build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW).glow().build() };
+ return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_TELEPORTER),
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).glow().build() };
}
@Override
@@ -158,8 +148,8 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
@Override
public void onConfigLoad(GT_Config aConfig) {
- sInterDimensionalTeleportAllowed =
- aConfig.get(ConfigCategories.machineconfig, "Teleporter.Interdimensional", true);
+ sInterDimensionalTeleportAllowed = aConfig
+ .get(ConfigCategories.machineconfig, "Teleporter.Interdimensional", true);
mMaxLoss = Math.max(aConfig.get(ConfigCategories.machineconfig, "MicrowaveTransmitter.MaxLoss", 50), 11);
mMaxLossDistance = aConfig.get(ConfigCategories.machineconfig, "MicrowaveTransmitter.MaxLossDistance", 10000);
mPassiveEnergyUse = aConfig.get(ConfigCategories.machineconfig, "MicrowaveTransmitter.PassiveEnergy", true);
@@ -193,19 +183,13 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
}
public boolean hasDimensionalTeleportCapability() {
- return this.mDebug
- || (sInterDimensionalTeleportAllowed
- && (this.hasBlock
- || mFluid != null
- && mFluid.isFluidEqual(Materials.Nitrogen.getPlasma(1))
- && mFluid.amount >= 1000));
+ return this.mDebug || (sInterDimensionalTeleportAllowed && (this.hasBlock
+ || mFluid != null && mFluid.isFluidEqual(Materials.Nitrogen.getPlasma(1)) && mFluid.amount >= 1000));
}
public boolean isDimensionalTeleportAvailable() {
- return this.mDebug
- || (hasDimensionalTeleportCapability()
- && GT_Utility.isRealDimension(this.mTargetD)
- && GT_Utility.isRealDimension(getBaseMetaTileEntity().getWorld().provider.dimensionId));
+ return this.mDebug || (hasDimensionalTeleportCapability() && GT_Utility.isRealDimension(this.mTargetD)
+ && GT_Utility.isRealDimension(getBaseMetaTileEntity().getWorld().provider.dimensionId));
}
@Override
@@ -218,8 +202,7 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
if (getBaseMetaTileEntity().getTimer() % 100L == 50L) {
this.hasBlock = checkForBlock();
}
- if ((getBaseMetaTileEntity().isAllowedToWork())
- && (getBaseMetaTileEntity().getRedstone())) {
+ if ((getBaseMetaTileEntity().isAllowedToWork()) && (getBaseMetaTileEntity().getRedstone())) {
if (getBaseMetaTileEntity().getStoredEU() > (V[mTier] * 16)) {
if (mPassiveEnergyUse) {
getBaseMetaTileEntity().decreaseStoredEnergyUnits(2L << (mTier - 1), false);
@@ -258,8 +241,8 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
}
long energyUse = 10;
if (mMaxLossDistance != 0) {
- energyUse = GT_Utility.safeInt(
- 10L + (tDistance * Math.max(mMaxLoss - 10L, 0) / mMaxLossDistance));
+ energyUse = GT_Utility
+ .safeInt(10L + (tDistance * Math.max(mMaxLoss - 10L, 0) / mMaxLossDistance));
}
energyUse = packetSize + ((V[mTier] * energyUse) / 100);
if (getBaseMetaTileEntity().isUniversalEnergyStored(energyUse)) {
@@ -278,13 +261,13 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
}
private int distanceCalculation() {
- return Math.abs(((this.mTargetD != getBaseMetaTileEntity().getWorld().provider.dimensionId)
- && (isDimensionalTeleportAvailable())
- ? 100
- : 1)
- * (int) Math.sqrt(Math.pow(getBaseMetaTileEntity().getXCoord() - this.mTargetX, 2.0D)
- + Math.pow(getBaseMetaTileEntity().getYCoord() - this.mTargetY, 2.0D)
- + Math.pow(getBaseMetaTileEntity().getZCoord() - this.mTargetZ, 2.0D)));
+ return Math.abs(
+ ((this.mTargetD != getBaseMetaTileEntity().getWorld().provider.dimensionId)
+ && (isDimensionalTeleportAvailable()) ? 100 : 1)
+ * (int) Math.sqrt(
+ Math.pow(getBaseMetaTileEntity().getXCoord() - this.mTargetX, 2.0D)
+ + Math.pow(getBaseMetaTileEntity().getYCoord() - this.mTargetY, 2.0D)
+ + Math.pow(getBaseMetaTileEntity().getZCoord() - this.mTargetZ, 2.0D)));
}
@Override
@@ -424,27 +407,26 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK)
- .setSize(90, 72)
- .setPos(43, 4))
- .widget(TextWidget.dynamicString(() -> "X: " + GT_Utility.parseNumberToString(mTargetX))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 8))
- .widget(TextWidget.dynamicString(() -> "Y: " + GT_Utility.parseNumberToString(mTargetY))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 16))
- .widget(TextWidget.dynamicString(() -> "Z: " + GT_Utility.parseNumberToString(mTargetZ))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 24))
- .widget(TextWidget.dynamicString(() -> "Dim: " + GT_Utility.parseNumberToString(mTargetD))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 32))
- .widget(TextWidget.dynamicString(
- () -> "Dim Valid: " + (GT_Utility.isRealDimension(mTargetD) ? "Yes" : "No"))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setEnabled(widget -> hasDimensionalTeleportCapability())
- .setPos(46, 40))
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK).setSize(90, 72).setPos(43, 4))
+ .widget(
+ TextWidget.dynamicString(() -> "X: " + GT_Utility.parseNumberToString(mTargetX))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 8))
+ .widget(
+ TextWidget.dynamicString(() -> "Y: " + GT_Utility.parseNumberToString(mTargetY))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 16))
+ .widget(
+ TextWidget.dynamicString(() -> "Z: " + GT_Utility.parseNumberToString(mTargetZ))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 24))
+ .widget(
+ TextWidget.dynamicString(() -> "Dim: " + GT_Utility.parseNumberToString(mTargetD))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 32))
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> "Dim Valid: " + (GT_Utility.isRealDimension(mTargetD) ? "Yes" : "No"))
+ .setDefaultColor(COLOR_TEXT_WHITE.get())
+ .setEnabled(widget -> hasDimensionalTeleportCapability()).setPos(46, 40))
.widget(new FakeSyncWidget.FluidStackSyncer(() -> mFluid, val -> mFluid = val));
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE, -512, -64, 7);
@@ -453,33 +435,38 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_LARGE, 512, 64, 151);
addChangeNumberButton(
- builder, GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE, val -> mTargetD += val, -16, -8, 7, 58);
+ builder,
+ GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE,
+ val -> mTargetD += val,
+ -16,
+ -8,
+ 7,
+ 58);
addChangeNumberButton(
- builder, GT_UITextures.OVERLAY_BUTTON_MINUS_SMALL, val -> mTargetD += val, -4, -1, 25, 58);
+ builder,
+ GT_UITextures.OVERLAY_BUTTON_MINUS_SMALL,
+ val -> mTargetD += val,
+ -4,
+ -1,
+ 25,
+ 58);
addChangeNumberButton(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_SMALL, val -> mTargetD += val, 4, 1, 133, 58);
addChangeNumberButton(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_LARGE, val -> mTargetD += val, 16, 8, 151, 58);
}
- private void addChangeNumberButtons(
- ModularWindow.Builder builder, IDrawable overlay, int addNumberShift, int addNumber, int xPos) {
+ private void addChangeNumberButtons(ModularWindow.Builder builder, IDrawable overlay, int addNumberShift,
+ int addNumber, int xPos) {
addChangeNumberButton(builder, overlay, val -> mTargetX += val, addNumberShift, addNumber, xPos, 4);
addChangeNumberButton(builder, overlay, val -> mTargetY += val, addNumberShift, addNumber, xPos, 22);
addChangeNumberButton(builder, overlay, val -> mTargetZ += val, addNumberShift, addNumber, xPos, 40);
}
- private void addChangeNumberButton(
- ModularWindow.Builder builder,
- IDrawable overlay,
- Consumer<Integer> setter,
- int addNumberShift,
- int addNumber,
- int xPos,
- int yPos) {
- builder.widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> setter.accept(clickData.shift ? addNumberShift : addNumber))
- .setBackground(GT_UITextures.BUTTON_STANDARD, overlay)
- .setSize(18, 18)
- .setPos(xPos, yPos));
+ private void addChangeNumberButton(ModularWindow.Builder builder, IDrawable overlay, Consumer<Integer> setter,
+ int addNumberShift, int addNumber, int xPos, int yPos) {
+ builder.widget(
+ new ButtonWidget()
+ .setOnClick((clickData, widget) -> setter.accept(clickData.shift ? addNumberShift : addNumber))
+ .setBackground(GT_UITextures.BUTTON_STANDARD, overlay).setSize(18, 18).setPos(xPos, yPos));
}
@Override
@@ -489,9 +476,7 @@ public class GT_MetaTileEntity_MicrowaveEnergyTransmitter extends GT_MetaTileEnt
@Override
public void addGregTechLogo(ModularWindow.Builder builder) {
- builder.widget(new DrawableWidget()
- .setDrawable(getGUITextureSet().getGregTechLogo())
- .setSize(17, 17)
- .setPos(113, 56));
+ builder.widget(
+ new DrawableWidget().setDrawable(getGUITextureSet().getGregTechLogo()).setSize(17, 17).setPos(113, 56));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Miner.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Miner.java
index 1c1ed70c20..7e4d5f8165 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Miner.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Miner.java
@@ -3,6 +3,19 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.GT_Values.V;
import static gregtech.api.enums.GT_Values.debugBlockMiner;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.ChunkPosition;
+import net.minecraftforge.common.util.FakePlayer;
+
import com.gtnewhorizons.modularui.api.drawable.FallbackableUITexture;
import com.gtnewhorizons.modularui.api.drawable.UITexture;
import com.gtnewhorizons.modularui.api.math.Pos2d;
@@ -10,6 +23,7 @@ import com.gtnewhorizons.modularui.api.math.Size;
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
+
import gregtech.api.enums.Textures;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.ITexture;
@@ -24,24 +38,14 @@ import gregtech.common.blocks.GT_Block_Ores_Abstract;
import gregtech.common.blocks.GT_TileEntity_Ores;
import gregtech.common.misc.GT_DrillingLogicDelegate;
import gregtech.common.misc.GT_IDrillingLogicDelegateOwner;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.ChunkPosition;
-import net.minecraftforge.common.util.FakePlayer;
@SuppressWarnings("ObjectEquality")
public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
implements GT_IDrillingLogicDelegateOwner, IAddUIWidgets {
- static final int[] RADIUS = {8, 8, 16, 24, 32}; // Miner radius per tier
- static final int[] SPEED = {160, 160, 80, 40, 20}; // Miner cycle time per tier
- static final int[] ENERGY = {8, 8, 32, 128, 512}; // Miner energy consumption per tier
+
+ static final int[] RADIUS = { 8, 8, 16, 24, 32 }; // Miner radius per tier
+ static final int[] SPEED = { 160, 160, 80, 40, 20 }; // Miner cycle time per tier
+ static final int[] ENERGY = { 8, 8, 32, 128, 512 }; // Miner energy consumption per tier
/** Miner configured radius */
private int radiusConfig;
@@ -60,91 +64,71 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
aNameRegional,
aTier,
1,
- new String[] {
- "Digging ore instead of you",
- "Use Screwdriver to regulate work area",
- "Use Soft Mallet to disable and retract the pipe",
- String.format("%d EU/t, %d sec per block, no stuttering", ENERGY[aTier], SPEED[aTier] / 20),
- String.format("Maximum work area %dx%d", (RADIUS[aTier] * 2 + 1), (RADIUS[aTier] * 2 + 1)),
- String.format("Fortune bonus of %d", aTier)
- },
+ new String[] { "Digging ore instead of you", "Use Screwdriver to regulate work area",
+ "Use Soft Mallet to disable and retract the pipe",
+ String.format("%d EU/t, %d sec per block, no stuttering", ENERGY[aTier], SPEED[aTier] / 20),
+ String.format("Maximum work area %dx%d", (RADIUS[aTier] * 2 + 1), (RADIUS[aTier] * 2 + 1)),
+ String.format("Fortune bonus of %d", aTier) },
2,
2,
"Miner.png",
"",
TextureFactory.of(
- TextureFactory.of(
- new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_SIDE_ACTIVE")),
- TextureFactory.builder()
- .addIcon(new Textures.BlockIcons.CustomIcon(
- "basicmachines/miner/OVERLAY_SIDE_ACTIVE_GLOW"))
- .glow()
- .build()),
+ TextureFactory
+ .of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_SIDE_ACTIVE")),
+ TextureFactory.builder().addIcon(
+ new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_SIDE_ACTIVE_GLOW"))
+ .glow().build()),
TextureFactory.of(
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_SIDE")),
TextureFactory.builder()
.addIcon(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_SIDE_GLOW"))
- .glow()
- .build()),
+ .glow().build()),
TextureFactory.of(
- TextureFactory.of(
- new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_FRONT_ACTIVE")),
- TextureFactory.builder()
- .addIcon(new Textures.BlockIcons.CustomIcon(
- "basicmachines/miner/OVERLAY_FRONT_ACTIVE_GLOW"))
- .glow()
- .build()),
+ TextureFactory
+ .of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_FRONT_ACTIVE")),
+ TextureFactory.builder().addIcon(
+ new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_FRONT_ACTIVE_GLOW"))
+ .glow().build()),
TextureFactory.of(
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_FRONT")),
TextureFactory.builder()
.addIcon(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_FRONT_GLOW"))
- .glow()
- .build()),
+ .glow().build()),
TextureFactory.of(
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_TOP_ACTIVE")),
- TextureFactory.builder()
- .addIcon(new Textures.BlockIcons.CustomIcon(
- "basicmachines/miner/OVERLAY_TOP_ACTIVE_GLOW"))
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(
+ new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_TOP_ACTIVE_GLOW"))
+ .glow().build()),
TextureFactory.of(
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_TOP")),
TextureFactory.builder()
.addIcon(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_TOP_GLOW"))
- .glow()
- .build()),
+ .glow().build()),
TextureFactory.of(
- TextureFactory.of(
- new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_BOTTOM_ACTIVE")),
- TextureFactory.builder()
- .addIcon(new Textures.BlockIcons.CustomIcon(
- "basicmachines/miner/OVERLAY_BOTTOM_ACTIVE_GLOW"))
- .glow()
- .build()),
+ TextureFactory
+ .of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_BOTTOM_ACTIVE")),
+ TextureFactory.builder().addIcon(
+ new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_BOTTOM_ACTIVE_GLOW"))
+ .glow().build()),
TextureFactory.of(
TextureFactory.of(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_BOTTOM")),
TextureFactory.builder()
.addIcon(new Textures.BlockIcons.CustomIcon("basicmachines/miner/OVERLAY_BOTTOM_GLOW"))
- .glow()
- .build()));
+ .glow().build()));
mSpeed = SPEED[aTier];
radiusConfig = RADIUS[mTier];
}
- public GT_MetaTileEntity_Miner(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Miner(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
mSpeed = SPEED[aTier];
radiusConfig = RADIUS[mTier];
}
- public GT_MetaTileEntity_Miner(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_Miner(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 2, 2, aGUIName, aNEIName);
mSpeed = SPEED[aTier];
radiusConfig = RADIUS[mTier];
@@ -162,8 +146,8 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack) //
&& aStack.getItem() == GT_DrillingLogicDelegate.MINING_PIPE_STACK.getItem();
}
@@ -241,8 +225,10 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
if (!aBaseMetaTileEntity.isUniversalEnergyStored((long) ENERGY[mTier] * (mSpeed - mProgresstime))) {
mMaxProgresstime = 0;
if (debugBlockMiner) {
- GT_Log.out.println("MINER: Not enough energy yet, want " + (ENERGY[mTier] * mSpeed) + " have "
- + aBaseMetaTileEntity.getUniversalEnergyStored());
+ GT_Log.out.println(
+ "MINER: Not enough energy yet, want " + (ENERGY[mTier] * mSpeed)
+ + " have "
+ + aBaseMetaTileEntity.getUniversalEnergyStored());
}
return;
}
@@ -272,13 +258,12 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
boolean isOre;
do {
ChunkPosition oreBlockPos = oreBlockPositions.remove(0);
- oreBlock = aBaseMetaTileEntity.getBlockOffset(
- oreBlockPos.chunkPosX, oreBlockPos.chunkPosY, oreBlockPos.chunkPosZ);
+ oreBlock = aBaseMetaTileEntity
+ .getBlockOffset(oreBlockPos.chunkPosX, oreBlockPos.chunkPosY, oreBlockPos.chunkPosZ);
x = aBaseMetaTileEntity.getXCoord() + oreBlockPos.chunkPosX;
y = aBaseMetaTileEntity.getYCoord() + oreBlockPos.chunkPosY;
z = aBaseMetaTileEntity.getZCoord() + oreBlockPos.chunkPosZ;
- isOre = GT_Utility.isOre(
- oreBlock, aBaseMetaTileEntity.getWorld().getBlockMetadata(x, y, z));
+ isOre = GT_Utility.isOre(oreBlock, aBaseMetaTileEntity.getWorld().getBlockMetadata(x, y, z));
} // someone else might have removed the block
while (!isOre && !oreBlockPositions.isEmpty());
@@ -390,19 +375,18 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
@Override
public String[] getInfoData() {
return new String[] {
- String.format(
- "%s%s%s",
- EnumChatFormatting.BLUE,
- StatCollector.translateToLocal("GT5U.machines.miner"),
- EnumChatFormatting.RESET),
- String.format(
- "%s: %s%d%s %s",
- StatCollector.translateToLocal("GT5U.machines.workarea"),
- EnumChatFormatting.GREEN,
- (radiusConfig * 2 + 1),
- EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.machines.blocks"))
- };
+ String.format(
+ "%s%s%s",
+ EnumChatFormatting.BLUE,
+ StatCollector.translateToLocal("GT5U.machines.miner"),
+ EnumChatFormatting.RESET),
+ String.format(
+ "%s: %s%d%s %s",
+ StatCollector.translateToLocal("GT5U.machines.workarea"),
+ EnumChatFormatting.GREEN,
+ (radiusConfig * 2 + 1),
+ EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.machines.blocks")) };
}
@Override
@@ -415,7 +399,10 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
return mSpeed;
}
- /** @deprecated This method are obsolete, and may be removed in further updates. Please use 'this.getPipe().descent()' access! */
+ /**
+ * @deprecated This method are obsolete, and may be removed in further updates. Please use
+ * 'this.getPipe().descent()' access!
+ */
@Deprecated
public boolean moveOneDown(IGregTechTileEntity tileEntity) {
boolean descends = pipe.descent(tileEntity);
@@ -425,7 +412,10 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
return descends;
}
- /** @deprecated This method are obsolete, and may be removed in further updates. Please use 'this.getPipe().getFakePlayer(te)' access! */
+ /**
+ * @deprecated This method are obsolete, and may be removed in further updates. Please use
+ * 'this.getPipe().getFakePlayer(te)' access!
+ */
@Deprecated
protected FakePlayer getFakePlayer(IGregTechTileEntity aBaseTile) {
return pipe.getFakePlayer(aBaseTile);
@@ -441,12 +431,18 @@ public class GT_MetaTileEntity_Miner extends GT_MetaTileEntity_BasicMachine
}
private static final FallbackableUITexture progressBarTexture = new FallbackableUITexture(
- UITexture.fullImage("gregtech", "gui/progressbar/miner"), GT_UITextures.PROGRESSBAR_CANNER);
+ UITexture.fullImage("gregtech", "gui/progressbar/miner"),
+ GT_UITextures.PROGRESSBAR_CANNER);
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
super.addUIWidgets(builder, buildContext);
- builder.widget(createProgressBar(
- progressBarTexture.get(), 20, ProgressBar.Direction.RIGHT, new Pos2d(78, 24), new Size(20, 18)));
+ builder.widget(
+ createProgressBar(
+ progressBarTexture.get(),
+ 20,
+ ProgressBar.Direction.RIGHT,
+ new Pos2d(78, 24),
+ new Size(20, 18)));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MonsterRepellent.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MonsterRepellent.java
index 65f62f240a..054ca1694a 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MonsterRepellent.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_MonsterRepellent.java
@@ -7,16 +7,18 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_ACTIVE;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_ACTIVE_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_GLOW;
+import java.util.Arrays;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_TieredMachineBlock;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_SpawnEventHandler;
-import java.util.Arrays;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_MonsterRepellent extends GT_MetaTileEntity_TieredMachineBlock {
@@ -29,60 +31,50 @@ public class GT_MetaTileEntity_MonsterRepellent extends GT_MetaTileEntity_Tiered
aNameRegional,
aTier,
0,
- "Repels nasty Creatures. Range: " + (4 + (12 * aTier)) + " unpowered / " + (16 + (48 * aTier))
- + " powered. Costs " + (1L << (aTier * 2)) + " EU/t");
+ "Repels nasty Creatures. Range: " + (4 + (12 * aTier))
+ + " unpowered / "
+ + (16 + (48 * aTier))
+ + " powered. Costs "
+ + (1L << (aTier * 2))
+ + " EU/t");
}
- public GT_MetaTileEntity_MonsterRepellent(
- String aName, int aTier, int aInvSlotCount, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_MonsterRepellent(String aName, int aTier, int aInvSlotCount, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
- public GT_MetaTileEntity_MonsterRepellent(
- String aName, int aTier, int aInvSlotCount, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_MonsterRepellent(String aName, int aTier, int aInvSlotCount, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aInvSlotCount, aDescription, aTextures);
}
@Override
public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_MonsterRepellent(
- this.mName, this.mTier, this.mInventory.length, this.mDescriptionArray, this.mTextures);
+ this.mName,
+ this.mTier,
+ this.mInventory.length,
+ this.mDescriptionArray,
+ this.mTextures);
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide != ForgeDirection.UP.ordinal()) return new ITexture[] {MACHINE_CASINGS[mTier][aColorIndex + 1]};
- if (aActive)
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide != ForgeDirection.UP.ordinal()) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1] };
+ if (aActive) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
TextureFactory.of(OVERLAY_TELEPORTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(OVERLAY_TELEPORTER),
- TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).glow().build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW).glow().build() };
+ return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_TELEPORTER),
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).glow().build() };
}
@Override
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTimer) {
if (aBaseMetaTileEntity.isAllowedToWork() && aBaseMetaTileEntity.isServerSide()) {
- int[] tCoords = {
- aBaseMetaTileEntity.getXCoord(),
- aBaseMetaTileEntity.getYCoord(),
- aBaseMetaTileEntity.getZCoord(),
- aBaseMetaTileEntity.getWorld().provider.dimensionId
- };
+ int[] tCoords = { aBaseMetaTileEntity.getXCoord(), aBaseMetaTileEntity.getYCoord(),
+ aBaseMetaTileEntity.getZCoord(), aBaseMetaTileEntity.getWorld().provider.dimensionId };
if ((aTimer % 600 == 0) && !GT_SpawnEventHandler.mobReps.contains(tCoords)) {
GT_SpawnEventHandler.mobReps.add(tCoords);
}
@@ -97,23 +89,16 @@ public class GT_MetaTileEntity_MonsterRepellent extends GT_MetaTileEntity_Tiered
@Override
public void onFirstTick(IGregTechTileEntity aBaseMetaTileEntity) {
- int[] tCoords = {
- aBaseMetaTileEntity.getXCoord(),
- aBaseMetaTileEntity.getYCoord(),
- aBaseMetaTileEntity.getZCoord(),
- aBaseMetaTileEntity.getWorld().provider.dimensionId
- };
+ int[] tCoords = { aBaseMetaTileEntity.getXCoord(), aBaseMetaTileEntity.getYCoord(),
+ aBaseMetaTileEntity.getZCoord(), aBaseMetaTileEntity.getWorld().provider.dimensionId };
GT_SpawnEventHandler.mobReps.add(tCoords);
}
@Override
public void onRemoval() {
- int[] tCoords = {
- this.getBaseMetaTileEntity().getXCoord(),
- this.getBaseMetaTileEntity().getYCoord(),
- this.getBaseMetaTileEntity().getZCoord(),
- this.getBaseMetaTileEntity().getWorld().provider.dimensionId
- };
+ int[] tCoords = { this.getBaseMetaTileEntity().getXCoord(), this.getBaseMetaTileEntity().getYCoord(),
+ this.getBaseMetaTileEntity().getZCoord(),
+ this.getBaseMetaTileEntity().getWorld().provider.dimensionId };
GT_SpawnEventHandler.mobReps.removeIf(coords -> Arrays.equals(coords, tCoords));
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_PotionBrewer.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_PotionBrewer.java
index 2a7e28f10b..f905717c5a 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_PotionBrewer.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_PotionBrewer.java
@@ -2,6 +2,11 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraft.init.Items;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
@@ -12,12 +17,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.init.Items;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_PotionBrewer extends GT_MetaTileEntity_BasicMachine {
+
public GT_MetaTileEntity_PotionBrewer(int aID, String aName, String aNameRegional, int aTier) {
super(
aID,
@@ -32,73 +34,49 @@ public class GT_MetaTileEntity_PotionBrewer extends GT_MetaTileEntity_BasicMachi
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_POTIONBREWER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_POTIONBREWER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_POTIONBREWER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_POTIONBREWER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_POTIONBREWER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_POTIONBREWER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_POTIONBREWER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_POTIONBREWER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_POTIONBREWER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_POTIONBREWER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_POTIONBREWER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_POTIONBREWER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_POTIONBREWER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_POTIONBREWER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_POTIONBREWER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_POTIONBREWER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_POTIONBREWER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_POTIONBREWER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_POTIONBREWER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_POTIONBREWER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_POTIONBREWER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_POTIONBREWER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_POTIONBREWER_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_POTIONBREWER_GLOW).glow().build()));
}
- public GT_MetaTileEntity_PotionBrewer(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_PotionBrewer(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 0, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_PotionBrewer(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_PotionBrewer(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 0, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_PotionBrewer(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -156,7 +134,8 @@ public class GT_MetaTileEntity_PotionBrewer extends GT_MetaTileEntity_BasicMachi
return setOutput("potion.weakness");
}
if (GT_Utility.areStacksEqual(
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Glowstone, 1L), getInputAt(0))) {
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Glowstone, 1L),
+ getInputAt(0))) {
if (!tModifier.startsWith("strong")) {
return setOutput(
"potion." + tInputName + ".strong" + (tModifier.isEmpty() ? "" : "." + tModifier));
@@ -167,7 +146,8 @@ public class GT_MetaTileEntity_PotionBrewer extends GT_MetaTileEntity_BasicMachi
return setOutput("potion.thick");
}
if (GT_Utility.areStacksEqual(
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Redstone, 1L), getInputAt(0))) {
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Redstone, 1L),
+ getInputAt(0))) {
if (!tModifier.startsWith("long")) {
return setOutput(
"potion." + tInputName + ".long" + (tModifier.isEmpty() ? "" : "." + tModifier));
@@ -178,7 +158,8 @@ public class GT_MetaTileEntity_PotionBrewer extends GT_MetaTileEntity_BasicMachi
return setOutput("potion.mundane");
}
if (GT_Utility.areStacksEqual(
- GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Gunpowder, 1L), getInputAt(0))) {
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Gunpowder, 1L),
+ getInputAt(0))) {
if (!tInputName.endsWith(".splash")) {
return setOutput("potion." + tInputName + ".splash");
}
@@ -205,8 +186,8 @@ public class GT_MetaTileEntity_PotionBrewer extends GT_MetaTileEntity_BasicMachi
}
@Override
- public boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ public boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& getRecipeList().containsInput(aStack);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Printer.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Printer.java
index 6771ba0fcc..7da1ec5e43 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Printer.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Printer.java
@@ -1,5 +1,9 @@
package gregtech.common.tileentities.machines.basic;
+import java.util.ArrayList;
+
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -8,10 +12,9 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicMachin
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_Printer extends GT_MetaTileEntity_BasicMachine {
+
public GT_MetaTileEntity_Printer(int aID, String aName, String aNameRegional, int aTier) {
super(
aID,
@@ -26,8 +29,8 @@ public class GT_MetaTileEntity_Printer extends GT_MetaTileEntity_BasicMachine {
GT_Recipe.GT_Recipe_Map.sPrinterRecipes.mNEIName);
}
- public GT_MetaTileEntity_Printer(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Printer(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 2, 2, aGUIName, aNEIName);
}
@@ -35,28 +38,27 @@ public class GT_MetaTileEntity_Printer extends GT_MetaTileEntity_BasicMachine {
public int checkRecipe() {
if (getOutputAt(0) != null) {
this.mOutputBlocked += 1;
- } else if ((GT_Utility.isStackValid(getInputAt(0)))
- && (getInputAt(0).stackSize > 0)
+ } else if ((GT_Utility.isStackValid(getInputAt(0))) && (getInputAt(0).stackSize > 0)
&& (GT_Utility.isStackInvalid(getSpecialSlot()))
&& (OrePrefixes.block.contains(getInputAt(0)))) {
- ArrayList<ItemStack> tList =
- GT_OreDictUnificator.getOres(GT_OreDictUnificator.getAssociation(getInputAt(0)));
- if (tList.size() > 1) {
- tList.add(tList.get(0));
- int i = 0;
- for (int j = tList.size() - 1; i < j; i++) {
- if (GT_Utility.areStacksEqual(getInputAt(0), (ItemStack) tList.get(i))) {
- this.mOutputItems[0] = GT_Utility.copyAmount(1L, tList.get(i + 1));
- calculateOverclockedNess(1, 32);
- // In case recipe is too OP for that machine
- if (mMaxProgresstime == Integer.MAX_VALUE - 1 && mEUt == Integer.MAX_VALUE - 1)
- return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
- getInputAt(0).stackSize -= 1;
- return 2;
+ ArrayList<ItemStack> tList = GT_OreDictUnificator
+ .getOres(GT_OreDictUnificator.getAssociation(getInputAt(0)));
+ if (tList.size() > 1) {
+ tList.add(tList.get(0));
+ int i = 0;
+ for (int j = tList.size() - 1; i < j; i++) {
+ if (GT_Utility.areStacksEqual(getInputAt(0), (ItemStack) tList.get(i))) {
+ this.mOutputItems[0] = GT_Utility.copyAmount(1L, tList.get(i + 1));
+ calculateOverclockedNess(1, 32);
+ // In case recipe is too OP for that machine
+ if (mMaxProgresstime == Integer.MAX_VALUE - 1 && mEUt == Integer.MAX_VALUE - 1)
+ return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
+ getInputAt(0).stackSize -= 1;
+ return 2;
+ }
+ }
}
}
- }
- }
this.mMaxProgresstime = 0;
return 0;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Pump.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Pump.java
index 26eed71b41..012f6e547f 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Pump.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Pump.java
@@ -3,22 +3,12 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.GT_Values.V;
import static gregtech.api.enums.GT_Values.debugBlockPump;
-import gregtech.api.enums.Textures;
-import gregtech.api.gui.modularui.GT_UIInfos;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.metatileentity.BaseTileEntity;
-import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_Utility;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
@@ -33,11 +23,24 @@ import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidBlock;
import net.minecraftforge.fluids.IFluidHandler;
+import gregtech.api.enums.Textures;
+import gregtech.api.gui.modularui.GT_UIInfos;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.metatileentity.BaseTileEntity;
+import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_Utility;
+
public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
+
private static final ItemStack MINING_PIPE = GT_ModHandler.getIC2Item("miningPipe", 0);
private static final Block MINING_PIPE_BLOCK = GT_Utility.getBlockFromStack(MINING_PIPE);
- private static final Block MINING_PIPE_TIP_BLOCK =
- GT_Utility.getBlockFromStack(GT_ModHandler.getIC2Item("miningPipeTip", 0));
+ private static final Block MINING_PIPE_TIP_BLOCK = GT_Utility
+ .getBlockFromStack(GT_ModHandler.getIC2Item("miningPipeTip", 0));
public static int getMaxDistanceForTier(int aTier) {
return (10 * ((int) Math.pow(1.6D, aTier)));
@@ -60,17 +63,22 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
private boolean mDisallowRetract = true;
public GT_MetaTileEntity_Pump(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 3, new String[] {
- "The best way to empty Oceans! Outputs on top",
- getEuUsagePerTier(aTier) + " EU/operation, " + GT_Utility.safeInt(160 / 20 / (long) Math.pow(2, aTier))
- + " sec per bucket, no stuttering",
- "Maximum pumping area: " + (getMaxDistanceForTier(aTier) * 2 + 1) + "x"
- + (getMaxDistanceForTier(aTier) * 2 + 1),
- "Use Screwdriver to regulate pumping area",
- "Use Soft Mallet to disable and retract the pipe",
- "Disable the bottom pump to retract the pipe!",
- "Use Soldering Iron to auto retract the pipe when hitting a rock",
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 3,
+ new String[] { "The best way to empty Oceans! Outputs on top",
+ getEuUsagePerTier(aTier) + " EU/operation, "
+ + GT_Utility.safeInt(160 / 20 / (long) Math.pow(2, aTier))
+ + " sec per bucket, no stuttering",
+ "Maximum pumping area: " + (getMaxDistanceForTier(aTier) * 2 + 1)
+ + "x"
+ + (getMaxDistanceForTier(aTier) * 2 + 1),
+ "Use Screwdriver to regulate pumping area", "Use Soft Mallet to disable and retract the pipe",
+ "Disable the bottom pump to retract the pipe!",
+ "Use Soldering Iron to auto retract the pipe when hitting a rock", });
radiusConfig = getMaxDistanceForTier(mTier);
}
@@ -93,8 +101,13 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
public void saveNBTData(NBTTagCompound aNBT) {
boolean wasPumping = this.wasPumping || !this.mPumpList.isEmpty();
if (debugBlockPump) {
- GT_Log.out.println("PUMP: NBT:Save - WasPumping - " + wasPumping + " blocks (" + this.mPrimaryPumpedBlock
- + ", " + this.mSecondaryPumpedBlock + ")");
+ GT_Log.out.println(
+ "PUMP: NBT:Save - WasPumping - " + wasPumping
+ + " blocks ("
+ + this.mPrimaryPumpedBlock
+ + ", "
+ + this.mSecondaryPumpedBlock
+ + ")");
}
super.saveNBTData(aNBT);
aNBT.setString(
@@ -102,8 +115,7 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
this.mPrimaryPumpedBlock == null ? "" : Block.blockRegistry.getNameForObject(this.mPrimaryPumpedBlock));
aNBT.setString(
"mPumpedBlock2",
- this.mSecondaryPumpedBlock == null
- ? ""
+ this.mSecondaryPumpedBlock == null ? ""
: Block.blockRegistry.getNameForObject(this.mSecondaryPumpedBlock));
aNBT.setBoolean("wasPumping", wasPumping);
aNBT.setInteger("radiusConfig", radiusConfig);
@@ -122,8 +134,12 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
this.mDisallowRetract = aNBT.getBoolean("mDisallowRetract");
if (debugBlockPump) {
- GT_Log.out.println("PUMP: NBT:Load - WasPumping - " + this.wasPumping + "("
- + aNBT.getString("mPumpedBlock1") + ") " + this.mPrimaryPumpedBlock);
+ GT_Log.out.println(
+ "PUMP: NBT:Load - WasPumping - " + this.wasPumping
+ + "("
+ + aNBT.getString("mPumpedBlock1")
+ + ") "
+ + this.mPrimaryPumpedBlock);
}
}
@@ -151,15 +167,17 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
}
GT_Utility.sendChatToPlayer(
aPlayer,
- StatCollector.translateToLocal("GT5U.machines.workareaset") + " " + (radiusConfig * 2 + 1) + "x"
+ StatCollector.translateToLocal("GT5U.machines.workareaset") + " "
+ + (radiusConfig * 2 + 1)
+ + "x"
+ (radiusConfig * 2 + 1)); // TODO Add translation support
clearQueue(false);
}
@Override
- public boolean onSolderingToolRightClick(
- byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public boolean onSolderingToolRightClick(byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY,
+ float aZ) {
if (super.onSolderingToolRightClick(aSide, aWrenchingSide, aPlayer, aX, aY, aZ)) return true;
mDisallowRetract = !mDisallowRetract;
GT_Utility.sendChatToPlayer(
@@ -216,13 +234,10 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
this.mPumpCountBelow = 0;
IGregTechTileEntity tTileEntity;
- for (int i = 1;
- (i < 21)
- && ((tTileEntity = getBaseMetaTileEntity()
- .getIGregTechTileEntityAtSideAndDistance((byte) 0, i))
- != null)
- && ((tTileEntity.getMetaTileEntity() instanceof GT_MetaTileEntity_Pump));
- i++) {
+ for (int i = 1; (i < 21)
+ && ((tTileEntity = getBaseMetaTileEntity().getIGregTechTileEntityAtSideAndDistance((byte) 0, i))
+ != null)
+ && ((tTileEntity.getMetaTileEntity() instanceof GT_MetaTileEntity_Pump)); i++) {
// Apparently someone might stack 21 pumps on top of each other, so let's check for that
getBaseMetaTileEntity().setActive(tTileEntity.isActive());
this.mPumpCountBelow += 1;
@@ -239,8 +254,7 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
if ((getBaseMetaTileEntity().isUniversalEnergyStored(this.getEuUsagePerAction()))
&& ((this.mFluid == null) || (this.mFluid.amount + 1000 <= getCapacity()))) {
boolean tMovedOneDown = false;
- if ((this.mPumpList.isEmpty())
- && (getBaseMetaTileEntity().getTimer() % 100L == 0L)) {
+ if ((this.mPumpList.isEmpty()) && (getBaseMetaTileEntity().getTimer() % 100L == 0L)) {
if (!this.wasPumping) {
tMovedOneDown = moveOneDown();
if (!tMovedOneDown) {
@@ -265,17 +279,19 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
GT_Log.out.println("PUMP: Was pumping, didn't move down");
}
}
- int x = getBaseMetaTileEntity().getXCoord(),
- z = getBaseMetaTileEntity().getZCoord();
+ int x = getBaseMetaTileEntity().getXCoord(), z = getBaseMetaTileEntity().getZCoord();
if (!this.hasValidFluid()) {
// We don't have a valid block, let's try to find one
int y = getYOfPumpHead();
if (debugBlockPump && this.mPrimaryPumpedBlock != null) {
- GT_Log.out.println("PUMP: Had an invalid pump block. Trying to find a fluid at Y: " + y
- + " Previous blocks 1: " + this.mPrimaryPumpedBlock + " 2: "
- + this.mSecondaryPumpedBlock);
+ GT_Log.out.println(
+ "PUMP: Had an invalid pump block. Trying to find a fluid at Y: " + y
+ + " Previous blocks 1: "
+ + this.mPrimaryPumpedBlock
+ + " 2: "
+ + this.mSecondaryPumpedBlock);
}
// First look down
checkForFluidToPump(x, y - 1, z);
@@ -294,20 +310,22 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
} else if (getYOfPumpHead() < getBaseMetaTileEntity().getYCoord()) {
// We didn't just look for a block, and the pump head is below the pump
- if ((tMovedOneDown)
- || this.wasPumping
+ if ((tMovedOneDown) || this.wasPumping
|| ((this.mPumpList.isEmpty())
&& (getBaseMetaTileEntity().getTimer() % 200L == 100L))
|| (getBaseMetaTileEntity().getTimer() % 72000L == 100L)) {
// Rebuild the list to pump if any of the following conditions are true:
- // 1) We just moved down
- // 2) We were previously pumping (and possibly just reloaded)
- // 3) We have an empty queue and enough time has passed
- // 4) A long while has passed
+ // 1) We just moved down
+ // 2) We were previously pumping (and possibly just reloaded)
+ // 3) We have an empty queue and enough time has passed
+ // 4) A long while has passed
if (debugBlockPump) {
- GT_Log.out.println("PUMP: Rebuilding pump list - Size " + this.mPumpList.size()
- + " WasPumping: " + this.wasPumping + " Timer "
- + getBaseMetaTileEntity().getTimer());
+ GT_Log.out.println(
+ "PUMP: Rebuilding pump list - Size " + this.mPumpList.size()
+ + " WasPumping: "
+ + this.wasPumping
+ + " Timer "
+ + getBaseMetaTileEntity().getTimer());
}
int yPump = getBaseMetaTileEntity().getYCoord() - 1, yHead = getYOfPumpHead();
@@ -329,7 +347,7 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
this.mPumpTimer = mPumpTimer == 0 ? 1 : mPumpTimer;
}
} else {
- // We somehow have a valid fluid, but the head of the pump isn't below the pump. Perhaps
+ // We somehow have a valid fluid, but the head of the pump isn't below the pump. Perhaps
// someone broke some pipes
// -- Clear the queue and we should try to move down until we can find a valid fluid
this.clearQueue(false);
@@ -338,10 +356,8 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
GT_Log.out.println("PUMP: Not enough energy? Free space?");
}
} else {
- if (!mRetractDone
- && ((aTick % 5) == 0)
- && ((this.mInventory[0] == null)
- || this.mInventory[0].stackSize == 0
+ if (!mRetractDone && ((aTick % 5) == 0)
+ && ((this.mInventory[0] == null) || this.mInventory[0].stackSize == 0
|| (GT_Utility.areStacksEqual(this.mInventory[0], MINING_PIPE)
&& (this.mInventory[0].stackSize
< this.mInventory[0].getMaxStackSize())))) {
@@ -355,8 +371,7 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
final int tZCoord = this.getBaseMetaTileEntity().getZCoord();
this.getBaseMetaTileEntity().getWorld().setBlockToAir(tXCoord, tHeadY, tZCoord);
if (tHeadY < this.getBaseMetaTileEntity().getYCoord() - 1) {
- getBaseMetaTileEntity()
- .getWorld()
+ getBaseMetaTileEntity().getWorld()
.setBlock(tXCoord, tHeadY + 1, tZCoord, MINING_PIPE_TIP_BLOCK);
}
if (this.mInventory[0] == null) {
@@ -407,8 +422,7 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
}
private boolean moveOneDown() {
- if ((this.mInventory[0] == null)
- || (this.mInventory[0].stackSize < 1)
+ if ((this.mInventory[0] == null) || (this.mInventory[0].stackSize < 1)
|| (!GT_Utility.areStacksEqual(this.mInventory[0], MINING_PIPE))) {
// No mining pipes
if (debugBlockPump) {
@@ -428,10 +442,8 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
int x = getBaseMetaTileEntity().getXCoord(), z = getBaseMetaTileEntity().getZCoord();
- if ((!consumeFluid(x, yHead - 1, z))
- && (!getBaseMetaTileEntity()
- .getBlock(x, yHead - 1, z)
- .isAir(getBaseMetaTileEntity().getWorld(), x, yHead - 1, z))) {
+ if ((!consumeFluid(x, yHead - 1, z)) && (!getBaseMetaTileEntity().getBlock(x, yHead - 1, z)
+ .isAir(getBaseMetaTileEntity().getWorld(), x, yHead - 1, z))) {
// Either we didn't consume a fluid, or it's a non Air block
if (debugBlockPump) {
GT_Log.out.println("PUMP: Did not consume fluid, or non-airblock found");
@@ -440,7 +452,13 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
}
// Try to set the block below us to a tip
if (!GT_Utility.setBlockByFakePlayer(
- getFakePlayer(getBaseMetaTileEntity()), x, yHead - 1, z, MINING_PIPE_TIP_BLOCK, 0, false)) {
+ getFakePlayer(getBaseMetaTileEntity()),
+ x,
+ yHead - 1,
+ z,
+ MINING_PIPE_TIP_BLOCK,
+ 0,
+ false)) {
if (debugBlockPump) {
GT_Log.out.println("PUMP: Could not set block below to new tip");
}
@@ -461,8 +479,7 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
// Let's play find the pump head!
// TODO: Handle pipe|pipe|head|pipe|pipe
- int y = getBaseMetaTileEntity().getYCoord() - 1,
- x = getBaseMetaTileEntity().getXCoord(),
+ int y = getBaseMetaTileEntity().getYCoord() - 1, x = getBaseMetaTileEntity().getXCoord(),
z = getBaseMetaTileEntity().getZCoord();
while (y > 0) {
@@ -550,8 +567,8 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
}
}
- private boolean queueFluid(
- int aX, int aY, int aZ, ArrayDeque<ChunkPosition> fluidsFound, Set<ChunkPosition> checked) {
+ private boolean queueFluid(int aX, int aY, int aZ, ArrayDeque<ChunkPosition> fluidsFound,
+ Set<ChunkPosition> checked) {
// If we haven't already looked at this coordinate set, and it's not already in the list of fluids found, see if
// there is
// a valid fluid and add it to the fluids found
@@ -598,13 +615,11 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
Block aBlock = getBaseMetaTileEntity().getBlock(aX, aY, aZ);
- return aBlock != null
- && (aBlock == Blocks.water
- || aBlock == Blocks.flowing_water
- || aBlock == Blocks.lava
- || aBlock == Blocks.flowing_lava
- || aBlock instanceof IFluidBlock
- || aBlock.isAir(getBaseMetaTileEntity().getWorld(), aX, aY, aZ));
+ return aBlock != null && (aBlock == Blocks.water || aBlock == Blocks.flowing_water
+ || aBlock == Blocks.lava
+ || aBlock == Blocks.flowing_lava
+ || aBlock instanceof IFluidBlock
+ || aBlock.isAir(getBaseMetaTileEntity().getWorld(), aX, aY, aZ));
}
private boolean consumeFluid(int aX, int aY, int aZ) {
@@ -615,8 +630,8 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
Block aBlock = getBaseMetaTileEntity().getBlock(aX, aY, aZ);
if (aBlock != null && ((this.mPrimaryPumpedBlock == aBlock) || (this.mSecondaryPumpedBlock == aBlock))) {
- boolean isWaterOrLava =
- ((this.mPrimaryPumpedBlock == Blocks.water || this.mPrimaryPumpedBlock == Blocks.lava));
+ boolean isWaterOrLava = ((this.mPrimaryPumpedBlock == Blocks.water
+ || this.mPrimaryPumpedBlock == Blocks.lava));
if (isWaterOrLava && getBaseMetaTileEntity().getMetaID(aX, aY, aZ) != 0) {
// Water/Lava that isn't a source block - do nothing here, but set the block to air and consume energy
@@ -630,26 +645,24 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
else if (this.mPrimaryPumpedBlock == Blocks.lava) this.mFluid = GT_ModHandler.getLava(1000L);
else {
// Not water or lava; try to drain and set to air
- this.mFluid =
- ((IFluidBlock) aBlock).drain(getBaseMetaTileEntity().getWorld(), aX, aY, aZ, true);
+ this.mFluid = ((IFluidBlock) aBlock).drain(getBaseMetaTileEntity().getWorld(), aX, aY, aZ, true);
}
- } else if (GT_ModHandler.isWater(this.mFluid)
- || GT_ModHandler.isLava(this.mFluid)
+ } else if (GT_ModHandler.isWater(this.mFluid) || GT_ModHandler.isLava(this.mFluid)
|| this.mFluid.isFluidEqual(
((IFluidBlock) aBlock).drain(getBaseMetaTileEntity().getWorld(), aX, aY, aZ, false))) {
- if (!isWaterOrLava) {
- // Only set Block to Air for non lava/water fluids
- this.getBaseMetaTileEntity().getWorld().setBlockToAir(aX, aY, aZ);
- }
- this.mFluid.amount += 1000;
+ if (!isWaterOrLava) {
+ // Only set Block to Air for non lava/water fluids
+ this.getBaseMetaTileEntity().getWorld().setBlockToAir(aX, aY, aZ);
+ }
+ this.mFluid.amount += 1000;
- } else {
- if (debugBlockPump) {
- GT_Log.out.println("PUMP: Couldn't consume " + aBlock);
- }
- // We didn't do anything
- return false;
- }
+ } else {
+ if (debugBlockPump) {
+ GT_Log.out.println("PUMP: Couldn't consume " + aBlock);
+ }
+ // We didn't do anything
+ return false;
+ }
getBaseMetaTileEntity().decreaseStoredEnergyUnits(this.getEuUsagePerAction(), true);
getBaseMetaTileEntity().getWorld().setBlock(aX, aY, aZ, Blocks.air, 0, 2);
@@ -665,24 +678,29 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
}
@Override
- public ArrayList<String> getSpecialDebugInfo(
- IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer, int aLogLevel, ArrayList<String> aList) {
- aList.addAll(Arrays.asList(
- EnumChatFormatting.BLUE
- + StatCollector.translateToLocal("GT5U.machines.pump")
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.machines.workarea") + ": " + EnumChatFormatting.GREEN
- + (radiusConfig * 2 + 1) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.machines.blocks"),
- "Primary pumping fluid: "
- + (this.mPrimaryPumpedBlock != null ? this.mPrimaryPumpedBlock.getLocalizedName() : "None"),
- "Secondary pumping fluid: "
- + (this.mSecondaryPumpedBlock != null ? this.mSecondaryPumpedBlock.getLocalizedName() : "None"),
- "Pumps below: " + mPumpCountBelow,
- "Queue size: " + mPumpList.size(),
- "Pump head at Y: " + getYOfPumpHead(),
- "Pump timer: " + mPumpTimer,
- "Meta Entity Timer: " + getBaseMetaTileEntity().getTimer()));
+ public ArrayList<String> getSpecialDebugInfo(IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer,
+ int aLogLevel, ArrayList<String> aList) {
+ aList.addAll(
+ Arrays.asList(
+ EnumChatFormatting.BLUE + StatCollector.translateToLocal("GT5U.machines.pump")
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.machines.workarea") + ": "
+ + EnumChatFormatting.GREEN
+ + (radiusConfig * 2 + 1)
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.machines.blocks"),
+ "Primary pumping fluid: "
+ + (this.mPrimaryPumpedBlock != null ? this.mPrimaryPumpedBlock.getLocalizedName()
+ : "None"),
+ "Secondary pumping fluid: "
+ + (this.mSecondaryPumpedBlock != null ? this.mSecondaryPumpedBlock.getLocalizedName()
+ : "None"),
+ "Pumps below: " + mPumpCountBelow,
+ "Queue size: " + mPumpList.size(),
+ "Pump head at Y: " + getYOfPumpHead(),
+ "Pump timer: " + mPumpTimer,
+ "Meta Entity Timer: " + getBaseMetaTileEntity().getTimer()));
return aList;
}
@@ -777,19 +795,11 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- Textures.BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
- (aSide == 0 || aSide == 1)
- ? TextureFactory.of(Textures.BlockIcons.OVERLAY_PIPE_OUT)
- : TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP)
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { Textures.BlockIcons.MACHINE_CASINGS[mTier][aColorIndex + 1],
+ (aSide == 0 || aSide == 1) ? TextureFactory.of(Textures.BlockIcons.OVERLAY_PIPE_OUT)
+ : TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP) };
}
@Override
@@ -799,12 +809,10 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
@Override
public ITexture[] getTexturesInactive(ITexture aBaseTexture) {
- return new ITexture[] {
- TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
- TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
- TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
- TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
- };
+ return new ITexture[] { TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
+ TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
+ TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP),
+ TextureFactory.of(Textures.BlockIcons.OVERLAY_ADV_PUMP), };
}
private FakePlayer mFakePlayer = null;
@@ -819,11 +827,14 @@ public class GT_MetaTileEntity_Pump extends GT_MetaTileEntity_Hatch {
@Override
public String[] getInfoData() {
return new String[] {
- EnumChatFormatting.BLUE + StatCollector.translateToLocal("GT5U.machines.pump") + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.machines.workarea") + ": " + EnumChatFormatting.GREEN
- + (radiusConfig * 2 + 1) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.machines.blocks")
- };
+ EnumChatFormatting.BLUE + StatCollector.translateToLocal("GT5U.machines.pump")
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.machines.workarea") + ": "
+ + EnumChatFormatting.GREEN
+ + (radiusConfig * 2 + 1)
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.machines.blocks") };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Replicator.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Replicator.java
index 57536d0e9d..6add532358 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Replicator.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Replicator.java
@@ -2,6 +2,12 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.HashMap;
+import java.util.NoSuchElementException;
+
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Element;
import gregtech.api.enums.ItemList;
@@ -16,12 +22,9 @@ import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.common.items.behaviors.Behaviour_DataOrb;
-import java.util.HashMap;
-import java.util.NoSuchElementException;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_Replicator extends GT_MetaTileEntity_BasicMachine {
+
public static final HashMap<Materials, Long> MASS_OVERRIDES = new HashMap<>();
public static final double EXPONENT = GregTech_API.sOPStuff.get("Replicator", "Nerf Exponent", 1.2D);
private static int sHeaviestElementMass = 0;
@@ -49,73 +52,49 @@ public class GT_MetaTileEntity_Replicator extends GT_MetaTileEntity_BasicMachine
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_REPLICATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_REPLICATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_REPLICATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_REPLICATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_REPLICATOR_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_REPLICATOR_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_REPLICATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_REPLICATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_REPLICATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_REPLICATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_REPLICATOR_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_REPLICATOR_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_REPLICATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_REPLICATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_REPLICATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_REPLICATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_REPLICATOR_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_REPLICATOR_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_REPLICATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_REPLICATOR_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_REPLICATOR_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_REPLICATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_REPLICATOR_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_REPLICATOR_GLOW).glow().build()));
}
- public GT_MetaTileEntity_Replicator(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Replicator(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_Replicator(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_Replicator(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Replicator(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
public static long cubicFluidMultiplier(long amount) {
@@ -129,9 +108,7 @@ public class GT_MetaTileEntity_Replicator extends GT_MetaTileEntity_BasicMachine
ItemStack tDataOrb = getSpecialSlot();
if ((ItemList.Tool_DataOrb.isStackEqual(tDataOrb, false, true))
&& (Behaviour_DataOrb.getDataTitle(tDataOrb).equals("Elemental-Scan"))) {
- Materials tMaterial = Element.get(Behaviour_DataOrb.getDataName(tDataOrb))
- .mLinkedMaterials
- .get(0);
+ Materials tMaterial = Element.get(Behaviour_DataOrb.getDataName(tDataOrb)).mLinkedMaterials.get(0);
long tMass = cubicFluidMultiplier(MASS_OVERRIDES.getOrDefault(tMaterial, tMaterial.getMass()));
if ((tFluid.amount >= tMass) && (tMass > 0L)) {
@@ -178,8 +155,8 @@ public class GT_MetaTileEntity_Replicator extends GT_MetaTileEntity_BasicMachine
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& ItemList.Cell_Empty.isStackEqual(aStack);
}
@@ -193,8 +170,7 @@ public class GT_MetaTileEntity_Replicator extends GT_MetaTileEntity_BasicMachine
public int getCapacity() {
if ((sHeaviestElementMass == 0) && (GregTech_API.sPostloadFinished)) {
sHeaviestElementMass = Materials.getMaterialsMap().values().stream()
- .mapToInt(material -> (int) cubicFluidMultiplier((int) material.getMass()))
- .max()
+ .mapToInt(material -> (int) cubicFluidMultiplier((int) material.getMass())).max()
.orElseThrow(NoSuchElementException::new);
// Make the Number nicer =)
sHeaviestElementMass = 1000 * (sHeaviestElementMass / 1000 + 1);
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_RockBreaker.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_RockBreaker.java
index 6c0f6cb051..584164fa94 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_RockBreaker.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_RockBreaker.java
@@ -2,6 +2,9 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
import gregtech.api.interfaces.ITexture;
@@ -12,10 +15,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_RockBreaker extends GT_MetaTileEntity_BasicMachine {
+
public GT_MetaTileEntity_RockBreaker(int aID, String aName, String aNameRegional, int aTier) {
super(
aID,
@@ -30,73 +32,49 @@ public class GT_MetaTileEntity_RockBreaker extends GT_MetaTileEntity_BasicMachin
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_GLOW).glow().build()));
}
- public GT_MetaTileEntity_RockBreaker(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_RockBreaker(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_RockBreaker(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_RockBreaker(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_RockBreaker(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -105,8 +83,8 @@ public class GT_MetaTileEntity_RockBreaker extends GT_MetaTileEntity_BasicMachin
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& getRecipeList().containsInput(aStack);
}
@@ -130,12 +108,13 @@ public class GT_MetaTileEntity_RockBreaker extends GT_MetaTileEntity_BasicMachin
|| (aBaseMetaTileEntity.getBlockOffset(0, 0, -1) == Blocks.lava)
|| (aBaseMetaTileEntity.getBlockOffset(-1, 0, 0) == Blocks.lava)
|| (aBaseMetaTileEntity.getBlockOffset(1, 0, 0) == Blocks.lava)) {
- tOutput = new ItemStack(Blocks.cobblestone, 1);
- }
+ tOutput = new ItemStack(Blocks.cobblestone, 1);
+ }
if (tOutput != null) {
if (GT_Utility.areStacksEqual(getStackInSlot(getCircuitSlot()), GT_Utility.getIntegratedCircuit(1))) {
if (GT_Utility.areStacksEqual(
- getInputAt(0), GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Redstone, 1L))) {
+ getInputAt(0),
+ GT_OreDictUnificator.get(OrePrefixes.dust, Materials.Redstone, 1L))) {
tOutput = new ItemStack(Blocks.obsidian, 1);
if (canOutput(tOutput)) {
getInputAt(0).stackSize -= 1;
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Scanner.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Scanner.java
index 7780e56eee..20b42e7bb4 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Scanner.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Scanner.java
@@ -4,6 +4,13 @@ import static gregtech.api.enums.GT_Values.*;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.util.GT_Recipe.GT_Recipe_Map.sScannerFakeRecipes;
+import java.util.Objects;
+
+import net.minecraft.init.Items;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+
import forestry.api.genetics.AlleleManager;
import forestry.api.genetics.IIndividual;
import gregtech.GT_Mod;
@@ -24,11 +31,6 @@ import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.common.items.behaviors.Behaviour_DataOrb;
-import java.util.Objects;
-import net.minecraft.init.Items;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
@@ -46,73 +48,49 @@ public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_SCANNER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_SCANNER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_SCANNER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_SCANNER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_SCANNER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_SCANNER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_SCANNER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_SCANNER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_SCANNER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_SCANNER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_SCANNER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_SCANNER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_SCANNER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_SCANNER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_SCANNER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_SCANNER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_SCANNER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_SCANNER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_SCANNER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_SCANNER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_SCANNER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_SCANNER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_SCANNER_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_SCANNER_GLOW).glow().build()));
}
- public GT_MetaTileEntity_Scanner(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_Scanner(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_Scanner(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_Scanner(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_Scanner(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -182,8 +160,7 @@ public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
return 2;
}
ItemData tData = GT_OreDictUnificator.getAssociation(aStack);
- if ((tData != null)
- && ((tData.mPrefix == OrePrefixes.dust) || (tData.mPrefix == OrePrefixes.cell))
+ if ((tData != null) && ((tData.mPrefix == OrePrefixes.dust) || (tData.mPrefix == OrePrefixes.cell))
&& (tData.mMaterial.mMaterial.mElement != null)
&& (!tData.mMaterial.mMaterial.mElement.mIsIsotope)
&& (tData.mMaterial.mMaterial != Materials.Magic)
@@ -230,8 +207,11 @@ public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
this.mOutputItems[0] = GT_Utility.copyAmount(1L, getSpecialSlot());
assert this.mOutputItems[0] != null;
- this.mOutputItems[0].setTagCompound(GT_Utility.getNBTContainingShort(
- new NBTTagCompound(), "map_id", (short) aStack.getItemDamage()));
+ this.mOutputItems[0].setTagCompound(
+ GT_Utility.getNBTContainingShort(
+ new NBTTagCompound(),
+ "map_id",
+ (short) aStack.getItemDamage()));
calculateOverclockedNess(30, 128);
// In case recipe is too OP for that machine
if (mMaxProgresstime == Integer.MAX_VALUE - 1 && mEUt == Integer.MAX_VALUE - 1)
@@ -240,56 +220,47 @@ public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
}
if ((aStack.getItem().getUnlocalizedName().contains("Schematic")
- || aStack.getItem().getUnlocalizedName().contains("schematic"))
+ || aStack.getItem().getUnlocalizedName().contains("schematic"))
&& !aStack.getItem().getUnlocalizedName().contains("Schematics")) {
if (mTier < 3) return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
String sTier = "";
int stackItemID = Item.getIdFromItem(aStack.getItem());
int stackItemDamage = aStack.getItemDamage();
- if (stackItemID
- == Item.getIdFromItem(Objects.requireNonNull(
- GT_ModHandler.getModItem(MOD_ID_GC_CORE, "item.schematic", 1L, 0))
+ if (stackItemID == Item.getIdFromItem(
+ Objects.requireNonNull(GT_ModHandler.getModItem(MOD_ID_GC_CORE, "item.schematic", 1L, 0))
.getItem())) {
- if (stackItemDamage == 0
- && aStack.toString()
- .equals(Objects.requireNonNull(GT_ModHandler.getModItem(
- MOD_ID_GC_CORE, "item.schematic", 1L, 0))
- .copy()
- .toString())) sTier = "100";
- else if (stackItemDamage == 1
- && aStack.toString()
- .equals(Objects.requireNonNull(GT_ModHandler.getModItem(
- MOD_ID_GC_CORE, "item.schematic", 1L, 1))
- .copy()
- .toString())) sTier = "2";
+ if (stackItemDamage == 0 && aStack.toString().equals(
+ Objects.requireNonNull(
+ GT_ModHandler.getModItem(MOD_ID_GC_CORE, "item.schematic", 1L, 0)).copy()
+ .toString()))
+ sTier = "100";
+ else if (stackItemDamage == 1 && aStack.toString().equals(
+ Objects.requireNonNull(
+ GT_ModHandler.getModItem(MOD_ID_GC_CORE, "item.schematic", 1L, 1)).copy()
+ .toString()))
+ sTier = "2";
} else {
- if (stackItemID
- == Item.getIdFromItem(Objects.requireNonNull(
- GT_ModHandler.getModItem(MOD_ID_GC_MARS, "item.schematic", 1L, 0))
- .getItem())) {
- if (stackItemDamage == 0
- && aStack.toString()
- .equals(Objects.requireNonNull(GT_ModHandler.getModItem(
- MOD_ID_GC_MARS, "item.schematic", 1L, 0))
- .copy()
- .toString())) sTier = "3";
- else if (stackItemDamage == 1
- && aStack.toString()
- .equals(Objects.requireNonNull(GT_ModHandler.getModItem(
- MOD_ID_GC_MARS, "item.schematic", 1L, 1))
- .copy()
- .toString())) sTier = "101";
- else if (stackItemDamage == 2
- && aStack.toString()
- .equals(Objects.requireNonNull(GT_ModHandler.getModItem(
- MOD_ID_GC_MARS, "item.schematic", 1L, 2))
- .copy()
- .toString())) sTier = "102";
+ if (stackItemID == Item.getIdFromItem(
+ Objects.requireNonNull(
+ GT_ModHandler.getModItem(MOD_ID_GC_MARS, "item.schematic", 1L, 0)).getItem())) {
+ if (stackItemDamage == 0 && aStack.toString().equals(
+ Objects.requireNonNull(
+ GT_ModHandler.getModItem(MOD_ID_GC_MARS, "item.schematic", 1L, 0)).copy()
+ .toString()))
+ sTier = "3";
+ else if (stackItemDamage == 1 && aStack.toString().equals(
+ Objects.requireNonNull(
+ GT_ModHandler.getModItem(MOD_ID_GC_MARS, "item.schematic", 1L, 1)).copy()
+ .toString()))
+ sTier = "101";
+ else if (stackItemDamage == 2 && aStack.toString().equals(
+ Objects.requireNonNull(
+ GT_ModHandler.getModItem(MOD_ID_GC_MARS, "item.schematic", 1L, 2)).copy()
+ .toString()))
+ sTier = "102";
} else if (aStack.getUnlocalizedName().matches(".*\\d+.*"))
- sTier = aStack.getUnlocalizedName()
- .split("(?<=\\D)(?=\\d)")[1]
- .substring(0, 1);
+ sTier = aStack.getUnlocalizedName().split("(?<=\\D)(?=\\d)")[1].substring(0, 1);
else sTier = "1";
}
@@ -298,8 +269,11 @@ public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
this.mOutputItems[0] = GT_Utility.copyAmount(1L, getSpecialSlot());
assert this.mOutputItems[0] != null;
- this.mOutputItems[0].setTagCompound(GT_Utility.getNBTContainingShort(
- new NBTTagCompound(), "rocket_tier", Short.parseShort(sTier)));
+ this.mOutputItems[0].setTagCompound(
+ GT_Utility.getNBTContainingShort(
+ new NBTTagCompound(),
+ "rocket_tier",
+ Short.parseShort(sTier)));
calculateOverclockedNess(480, 36000);
// In case recipe is too OP for that machine
@@ -379,8 +353,8 @@ public class GT_MetaTileEntity_Scanner extends GT_MetaTileEntity_BasicMachine {
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& getRecipeList().containsInput(aStack);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_SeismicProspector.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_SeismicProspector.java
index ff54291188..4e8af7d283 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_SeismicProspector.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_SeismicProspector.java
@@ -2,6 +2,17 @@ package gregtech.common.tileentities.machines.basic;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.Item;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Materials;
@@ -17,15 +28,6 @@ import gregtech.common.GT_UndergroundOil;
import gregtech.common.blocks.GT_Block_Ores_Abstract;
import gregtech.common.blocks.GT_TileEntity_Ores;
import ic2.core.Ic2Items;
-import java.util.ArrayList;
-import java.util.List;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_SeismicProspector extends GT_MetaTileEntity_BasicMachine {
@@ -45,73 +47,49 @@ public class GT_MetaTileEntity_SeismicProspector extends GT_MetaTileEntity_Basic
"",
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_SIDE_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_TOP_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_ACTIVE_GLOW).glow().build()),
TextureFactory.of(
TextureFactory.of(OVERLAY_BOTTOM_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_GLOW)
- .glow()
- .build()));
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_ROCK_BREAKER_GLOW).glow().build()));
}
- public GT_MetaTileEntity_SeismicProspector(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures, String aGUIName, String aNEIName) {
+ public GT_MetaTileEntity_SeismicProspector(String aName, int aTier, String aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
- public GT_MetaTileEntity_SeismicProspector(
- String aName,
- int aTier,
- String[] aDescription,
- ITexture[][][] aTextures,
- String aGUIName,
- String aNEIName) {
+ public GT_MetaTileEntity_SeismicProspector(String aName, int aTier, String[] aDescription, ITexture[][][] aTextures,
+ String aGUIName, String aNEIName) {
super(aName, aTier, 1, aDescription, aTextures, 1, 1, aGUIName, aNEIName);
}
@Override
public MetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
return new GT_MetaTileEntity_SeismicProspector(
- this.mName, this.mTier, this.mDescriptionArray, this.mTextures, this.mGUIName, this.mNEIName);
+ this.mName,
+ this.mTier,
+ this.mDescriptionArray,
+ this.mTextures,
+ this.mGUIName,
+ this.mNEIName);
}
@Override
@@ -119,18 +97,14 @@ public class GT_MetaTileEntity_SeismicProspector extends GT_MetaTileEntity_Basic
if (aBaseMetaTileEntity.isServerSide()) {
ItemStack aStack = aPlayer.getCurrentEquippedItem();
ItemData stackData = GT_OreDictUnificator.getItemData(aStack);
- if (!ready
- && (aStack != null)
+ if (!ready && (aStack != null)
&& ((aStack.getItem() == Item.getItemFromBlock(Blocks.tnt) && aStack.stackSize >= 2)
|| (aStack.getItem() == Ic2Items.industrialTnt.getItem() && aStack.stackSize >= 1)
|| (aStack.getItem() == Ic2Items.dynamite.getItem() && aStack.stackSize >= 4)
- || (stackData != null
- && stackData.mMaterial.mMaterial == Materials.Glyceryl
+ || (stackData != null && stackData.mMaterial.mMaterial == Materials.Glyceryl
&& aStack.stackSize >= 1)
|| (aStack.getItem() == ItemList.Block_Powderbarrel.getItem()
- && aStack.getItemDamage()
- == ItemList.Block_Powderbarrel.get(1)
- .getItemDamage()
+ && aStack.getItemDamage() == ItemList.Block_Powderbarrel.get(1).getItemDamage()
&& aStack.stackSize >= 8))) {
if ((!aPlayer.capabilities.isCreativeMode) && (aStack.stackSize != 111)) {
if (aStack.getItem() == Item.getItemFromBlock(Blocks.tnt)) {
@@ -140,89 +114,84 @@ public class GT_MetaTileEntity_SeismicProspector extends GT_MetaTileEntity_Basic
} else if (aStack.getItem() == Ic2Items.dynamite.getItem()) {
aStack.stackSize -= 4;
} else if (aStack.getItem() == ItemList.Block_Powderbarrel.getItem()
- && aStack.getItemDamage()
- == ItemList.Block_Powderbarrel.get(1).getItemDamage()) {
- aStack.stackSize -= 8;
- } else {
- aStack.stackSize -= 1;
- }
+ && aStack.getItemDamage() == ItemList.Block_Powderbarrel.get(1).getItemDamage()) {
+ aStack.stackSize -= 8;
+ } else {
+ aStack.stackSize -= 1;
+ }
}
this.ready = true;
this.mMaxProgresstime = 200;
- } else if (ready
- && mMaxProgresstime == 0
+ } else if (ready && mMaxProgresstime == 0
&& aStack != null
&& aStack.stackSize == 1
&& aStack.getItem() == ItemList.Tool_DataStick.getItem()) {
- this.ready = false;
- GT_Utility.ItemNBT.setBookTitle(aPlayer.getCurrentEquippedItem(), "Raw Prospection Data");
- List<String> tStringList = new ArrayList<String>();
-
- // range by tier
- int min = -range();
- int max = range();
- int step = step();
-
- for (int i = this.getBaseMetaTileEntity().getYCoord(); i > 0; i--) {
- for (int f = min; f <= max; f += step) {
- for (int g = min; g <= max; g += step) {
- Block tBlock = this.getBaseMetaTileEntity().getBlockOffset(f, -i, g);
- if ((tBlock instanceof GT_Block_Ores_Abstract)) {
- TileEntity tTileEntity = getBaseMetaTileEntity()
- .getWorld()
- .getTileEntity(
+ this.ready = false;
+ GT_Utility.ItemNBT.setBookTitle(aPlayer.getCurrentEquippedItem(), "Raw Prospection Data");
+ List<String> tStringList = new ArrayList<String>();
+
+ // range by tier
+ int min = -range();
+ int max = range();
+ int step = step();
+
+ for (int i = this.getBaseMetaTileEntity().getYCoord(); i > 0; i--) {
+ for (int f = min; f <= max; f += step) {
+ for (int g = min; g <= max; g += step) {
+ Block tBlock = this.getBaseMetaTileEntity().getBlockOffset(f, -i, g);
+ if ((tBlock instanceof GT_Block_Ores_Abstract)) {
+ TileEntity tTileEntity = getBaseMetaTileEntity().getWorld().getTileEntity(
getBaseMetaTileEntity().getXCoord() + f,
getBaseMetaTileEntity().getYCoord() + (-i),
getBaseMetaTileEntity().getZCoord() + g);
- if ((tTileEntity instanceof GT_TileEntity_Ores)) {
- if (((GT_TileEntity_Ores) tTileEntity).mMetaData < 16000) {
- Materials tMaterial = GregTech_API.sGeneratedMaterials[
- (((GT_TileEntity_Ores) tTileEntity).mMetaData % 1000)];
- if ((tMaterial != null) && (tMaterial != Materials._NULL)) {
- if (!tStringList.contains(tMaterial.mDefaultLocalName)) {
- tStringList.add(tMaterial.mDefaultLocalName);
+ if ((tTileEntity instanceof GT_TileEntity_Ores)) {
+ if (((GT_TileEntity_Ores) tTileEntity).mMetaData < 16000) {
+ Materials tMaterial = GregTech_API.sGeneratedMaterials[(((GT_TileEntity_Ores) tTileEntity).mMetaData
+ % 1000)];
+ if ((tMaterial != null) && (tMaterial != Materials._NULL)) {
+ if (!tStringList.contains(tMaterial.mDefaultLocalName)) {
+ tStringList.add(tMaterial.mDefaultLocalName);
+ }
+ }
}
}
- }
- }
- } else {
- int tMetaID = getBaseMetaTileEntity()
- .getWorld()
- .getBlockMetadata(
+ } else {
+ int tMetaID = getBaseMetaTileEntity().getWorld().getBlockMetadata(
getBaseMetaTileEntity().getXCoord() + f,
getBaseMetaTileEntity().getYCoord() + (-i),
getBaseMetaTileEntity().getZCoord() + g);
- ItemData tAssotiation =
- GT_OreDictUnificator.getAssociation(new ItemStack(tBlock, 1, tMetaID));
- if ((tAssotiation != null)
- && (tAssotiation.mPrefix.toString().startsWith("ore"))) {
- if (!tStringList.contains(tAssotiation.mMaterial.mMaterial.mDefaultLocalName)) {
- tStringList.add(tAssotiation.mMaterial.mMaterial.mDefaultLocalName);
+ ItemData tAssotiation = GT_OreDictUnificator
+ .getAssociation(new ItemStack(tBlock, 1, tMetaID));
+ if ((tAssotiation != null)
+ && (tAssotiation.mPrefix.toString().startsWith("ore"))) {
+ if (!tStringList
+ .contains(tAssotiation.mMaterial.mMaterial.mDefaultLocalName)) {
+ tStringList.add(tAssotiation.mMaterial.mMaterial.mDefaultLocalName);
+ }
+ }
}
}
}
}
+ if (tStringList.size() < 1) {
+ tStringList.add("No Ores found.");
+ }
+ FluidStack tFluid = GT_UndergroundOil.undergroundOilReadInformation(getBaseMetaTileEntity());
+ String[] tStringArray = new String[tStringList.size()];
+ {
+ for (int i = 0; i < tStringArray.length; i++) {
+ tStringArray[i] = tStringList.get(i);
+ }
+ }
+ GT_Utility.ItemNBT.setProspectionData(
+ aPlayer.getCurrentEquippedItem(),
+ this.getBaseMetaTileEntity().getXCoord(),
+ this.getBaseMetaTileEntity().getYCoord(),
+ this.getBaseMetaTileEntity().getZCoord(),
+ this.getBaseMetaTileEntity().getWorld().provider.dimensionId,
+ tFluid,
+ tStringArray);
}
- }
- if (tStringList.size() < 1) {
- tStringList.add("No Ores found.");
- }
- FluidStack tFluid = GT_UndergroundOil.undergroundOilReadInformation(getBaseMetaTileEntity());
- String[] tStringArray = new String[tStringList.size()];
- {
- for (int i = 0; i < tStringArray.length; i++) {
- tStringArray[i] = tStringList.get(i);
- }
- }
- GT_Utility.ItemNBT.setProspectionData(
- aPlayer.getCurrentEquippedItem(),
- this.getBaseMetaTileEntity().getXCoord(),
- this.getBaseMetaTileEntity().getYCoord(),
- this.getBaseMetaTileEntity().getZCoord(),
- this.getBaseMetaTileEntity().getWorld().provider.dimensionId,
- tFluid,
- tStringArray);
- }
}
return true;
diff --git a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Teleporter.java b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Teleporter.java
index 0d09c59832..2b1f0fa349 100644
--- a/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Teleporter.java
+++ b/src/main/java/gregtech/common/tileentities/machines/basic/GT_MetaTileEntity_Teleporter.java
@@ -9,28 +9,9 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_SIDES;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_TELEPORTER_SIDES_GLOW;
-import com.gtnewhorizons.modularui.api.drawable.IDrawable;
-import com.gtnewhorizons.modularui.api.screen.ModularWindow;
-import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
-import com.gtnewhorizons.modularui.common.widget.ButtonWidget;
-import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
-import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
-import com.gtnewhorizons.modularui.common.widget.TextWidget;
-import gregtech.api.enums.ConfigCategories;
-import gregtech.api.gui.modularui.GT_UIInfos;
-import gregtech.api.gui.modularui.GT_UITextures;
-import gregtech.api.gui.modularui.GUITextureSet;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.modularui.IAddGregtechLogo;
-import gregtech.api.interfaces.modularui.IAddUIWidgets;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicTank;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_Config;
-import gregtech.api.util.GT_Utility;
import java.util.List;
import java.util.function.Consumer;
+
import net.minecraft.client.particle.EntityFX;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityHanging;
@@ -60,6 +41,28 @@ import net.minecraft.world.World;
import net.minecraftforge.common.DimensionManager;
import net.minecraftforge.fluids.FluidStack;
+import com.gtnewhorizons.modularui.api.drawable.IDrawable;
+import com.gtnewhorizons.modularui.api.screen.ModularWindow;
+import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
+import com.gtnewhorizons.modularui.common.widget.ButtonWidget;
+import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
+import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
+import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
+import gregtech.api.enums.ConfigCategories;
+import gregtech.api.gui.modularui.GT_UIInfos;
+import gregtech.api.gui.modularui.GT_UITextures;
+import gregtech.api.gui.modularui.GUITextureSet;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.modularui.IAddGregtechLogo;
+import gregtech.api.interfaces.modularui.IAddUIWidgets;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicTank;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_Config;
+import gregtech.api.util.GT_Utility;
+
public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
implements IAddGregtechLogo, IAddUIWidgets {
@@ -75,11 +78,14 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
// public boolean hasEgg = false;
public GT_MetaTileEntity_Teleporter(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 3, new String[] {
- "Teleport long distances with this little device.",
- "Use a Dragon Egg or Nitrogen Plasma",
- "for Inter-dimensional transmission"
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 3,
+ new String[] { "Teleport long distances with this little device.",
+ "Use a Dragon Egg or Nitrogen Plasma", "for Inter-dimensional transmission" });
}
public GT_MetaTileEntity_Teleporter(String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
@@ -95,8 +101,7 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
if ((aEntity instanceof EntityFX)) {
return -1.0F;
}
- } catch (Throwable e) {
- }
+ } catch (Throwable e) {}
if ((aEntity instanceof EntityFishHook)) {
return -1.0F;
}
@@ -191,54 +196,30 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
@Override
public String[] getInfoData() {
- return new String[] {
- "Coordinates:",
- "X: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetX) + EnumChatFormatting.RESET,
- "Y: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetY) + EnumChatFormatting.RESET,
- "Z: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetZ) + EnumChatFormatting.RESET,
- "Dimension: " + EnumChatFormatting.GREEN + this.mTargetD + EnumChatFormatting.RESET,
- "Dimension Valid: "
- + (GT_Utility.isRealDimension(this.mTargetD)
- ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
- : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET),
- "Dimension Registered: "
- + (DimensionManager.isDimensionRegistered(this.mTargetD)
- ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
- : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET)
- };
- }
-
- @Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide != this.getBaseMetaTileEntity().getFrontFacing())
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(OVERLAY_TELEPORTER_SIDES),
- TextureFactory.builder()
- .addIcon(OVERLAY_TELEPORTER_SIDES_GLOW)
- .glow()
- .build()
- };
- if (aActive)
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
+ return new String[] { "Coordinates:",
+ "X: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetX) + EnumChatFormatting.RESET,
+ "Y: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetY) + EnumChatFormatting.RESET,
+ "Z: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(this.mTargetZ) + EnumChatFormatting.RESET,
+ "Dimension: " + EnumChatFormatting.GREEN + this.mTargetD + EnumChatFormatting.RESET,
+ "Dimension Valid: " + (GT_Utility.isRealDimension(this.mTargetD)
+ ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
+ : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET),
+ "Dimension Registered: " + (DimensionManager.isDimensionRegistered(this.mTargetD)
+ ? EnumChatFormatting.GREEN + "Yes" + EnumChatFormatting.RESET
+ : EnumChatFormatting.RED + "No" + EnumChatFormatting.RESET) };
+ }
+
+ @Override
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide != this.getBaseMetaTileEntity().getFrontFacing()) return new ITexture[] {
+ MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_TELEPORTER_SIDES),
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_SIDES_GLOW).glow().build() };
+ if (aActive) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
TextureFactory.of(OVERLAY_TELEPORTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(OVERLAY_TELEPORTER),
- TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).glow().build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_ACTIVE_GLOW).glow().build() };
+ return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_TELEPORTER),
+ TextureFactory.builder().addIcon(OVERLAY_TELEPORTER_GLOW).glow().build() };
}
@Override
@@ -263,10 +244,10 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
@Override
public void onConfigLoad(GT_Config aConfig) {
- sInterDimensionalTeleportAllowed =
- aConfig.get(ConfigCategories.machineconfig, "Teleporter.Interdimensional", true);
- sPassiveEnergyDrain =
- aConfig.get(ConfigCategories.machineconfig, "Teleporter.PassiveDrain", sPassiveEnergyDrain);
+ sInterDimensionalTeleportAllowed = aConfig
+ .get(ConfigCategories.machineconfig, "Teleporter.Interdimensional", true);
+ sPassiveEnergyDrain = aConfig
+ .get(ConfigCategories.machineconfig, "Teleporter.PassiveDrain", sPassiveEnergyDrain);
sPowerMultiplyer = aConfig.get(ConfigCategories.machineconfig, "Teleporter.PowerMultipler", sPowerMultiplyer);
sFPowerMultiplyer = sPowerMultiplyer / 100.0;
}
@@ -274,8 +255,7 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
@Override
public void onFirstTick(IGregTechTileEntity aBaseMetaTileEntity) {
if (getBaseMetaTileEntity().isServerSide()) {
- if ((this.mTargetX == 0)
- && (this.mTargetY == 0)
+ if ((this.mTargetX == 0) && (this.mTargetY == 0)
&& (this.mTargetZ == 0)
&& (this.mTargetD == Integer.MIN_VALUE)) {
this.mTargetX = aBaseMetaTileEntity.getXCoord();
@@ -288,36 +268,33 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
}
// public boolean checkForEgg() {
- // for (byte i = -5; i <= 5; i = (byte) (i + 1)) {
- // for (byte j = -5; j <= 5; j = (byte) (j + 1)) {
- // for (byte k = -5; k <= 5; k = (byte) (k + 1)) {
- // if (getBaseMetaTileEntity().getBlockOffset(i, j, k) == Blocks.dragon_egg) {
- // return true;
- // }
- // }
- // }
- // }
- // return false;
+ // for (byte i = -5; i <= 5; i = (byte) (i + 1)) {
+ // for (byte j = -5; j <= 5; j = (byte) (j + 1)) {
+ // for (byte k = -5; k <= 5; k = (byte) (k + 1)) {
+ // if (getBaseMetaTileEntity().getBlockOffset(i, j, k) == Blocks.dragon_egg) {
+ // return true;
+ // }
+ // }
+ // }
+ // }
+ // return false;
// }
public boolean hasDimensionalTeleportCapability() {
- return this.mDebug
- ||
- // (
+ return this.mDebug ||
+ // (
sInterDimensionalTeleportAllowed // &&
- // (
- // this.hasEgg ||
- // mFluid.isFluidEqual(Materials.Nitrogen.getPlasma(1)) && mFluid.amount >= 1000
- // )
+ // (
+ // this.hasEgg ||
+ // mFluid.isFluidEqual(Materials.Nitrogen.getPlasma(1)) && mFluid.amount >= 1000
+ // )
// )
;
}
public boolean isDimensionalTeleportAvailable() {
- return this.mDebug
- || (hasDimensionalTeleportCapability()
- && GT_Utility.isRealDimension(this.mTargetD)
- && GT_Utility.isRealDimension(getBaseMetaTileEntity().getWorld().provider.dimensionId));
+ return this.mDebug || (hasDimensionalTeleportCapability() && GT_Utility.isRealDimension(this.mTargetD)
+ && GT_Utility.isRealDimension(getBaseMetaTileEntity().getWorld().provider.dimensionId));
}
@Override
@@ -329,18 +306,17 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
super.onPostTick(aBaseMetaTileEntity, aTick);
if (getBaseMetaTileEntity().isServerSide()) {
// if (getBaseMetaTileEntity().getTimer() % 100L == 50L) {
- // this.hasEgg = checkForEgg();
+ // this.hasEgg = checkForEgg();
// }
- if ((getBaseMetaTileEntity().isAllowedToWork())
- && (getBaseMetaTileEntity().getRedstone())) {
+ if ((getBaseMetaTileEntity().isAllowedToWork()) && (getBaseMetaTileEntity().getRedstone())) {
if (getBaseMetaTileEntity().decreaseStoredEnergyUnits(sPassiveEnergyDrain, false)) {
// if (hasDimensionalTeleportCapability() && this.mTargetD !=
// getBaseMetaTileEntity().getWorld().provider.dimensionId && (hasEgg ||
// mFluid.isFluidEqual(Materials.Nitrogen.getPlasma(1)))&& new XSTR().nextInt(10)==0) {
- // mFluid.amount--;
- // if (mFluid.amount < 1) {
- // mFluid = null;
- // }
+ // mFluid.amount--;
+ // if (mFluid.amount < 1) {
+ // mFluid = null;
+ // }
// }
int tDistance = distanceCalculation();
if (mInventory[0] != null) {
@@ -356,13 +332,20 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
if (tTile instanceof IInventory) {
int tStacksize = mInventory[0].stackSize;
GT_Utility.moveOneItemStack(
- this, tTile, (byte) 0, (byte) 0, null, false, (byte) 64, (byte) 1, (byte) 64,
+ this,
+ tTile,
+ (byte) 0,
+ (byte) 0,
+ null,
+ false,
+ (byte) 64,
+ (byte) 1,
+ (byte) 64,
(byte) 1);
if (mInventory[0] == null || mInventory[0].stackSize < tStacksize) {
getBaseMetaTileEntity()
.decreaseStoredEnergyUnits(
- (long) (Math.pow(tDistance, 1.5)
- * tDistance
+ (long) (Math.pow(tDistance, 1.5) * tDistance
* (tStacksize
- (mInventory[0] == null ? 0 : mInventory[0].stackSize))
* sFPowerMultiplyer),
@@ -370,66 +353,32 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
}
}
}
- List entities_in_box = getBaseMetaTileEntity()
- .getWorld()
- .getEntitiesWithinAABB(
- Entity.class,
- AxisAlignedBB.getBoundingBox(
- getBaseMetaTileEntity()
- .getOffsetX(
- getBaseMetaTileEntity()
- .getFrontFacing(),
- 2)
- - 1,
- getBaseMetaTileEntity()
- .getOffsetY(
- getBaseMetaTileEntity()
- .getFrontFacing(),
- 2)
- - 1,
- getBaseMetaTileEntity()
- .getOffsetZ(
- getBaseMetaTileEntity()
- .getFrontFacing(),
- 2)
- - 1,
- getBaseMetaTileEntity()
- .getOffsetX(
- getBaseMetaTileEntity()
- .getFrontFacing(),
- 2)
- + 2,
- getBaseMetaTileEntity()
- .getOffsetY(
- getBaseMetaTileEntity()
- .getFrontFacing(),
- 2)
- + 2,
- getBaseMetaTileEntity()
- .getOffsetZ(
- getBaseMetaTileEntity()
- .getFrontFacing(),
- 2)
- + 2));
+ List entities_in_box = getBaseMetaTileEntity().getWorld().getEntitiesWithinAABB(
+ Entity.class,
+ AxisAlignedBB.getBoundingBox(
+ getBaseMetaTileEntity().getOffsetX(getBaseMetaTileEntity().getFrontFacing(), 2) - 1,
+ getBaseMetaTileEntity().getOffsetY(getBaseMetaTileEntity().getFrontFacing(), 2) - 1,
+ getBaseMetaTileEntity().getOffsetZ(getBaseMetaTileEntity().getFrontFacing(), 2) - 1,
+ getBaseMetaTileEntity().getOffsetX(getBaseMetaTileEntity().getFrontFacing(), 2) + 2,
+ getBaseMetaTileEntity().getOffsetY(getBaseMetaTileEntity().getFrontFacing(), 2) + 2,
+ getBaseMetaTileEntity().getOffsetZ(getBaseMetaTileEntity().getFrontFacing(), 2)
+ + 2));
for (Object tObject : entities_in_box) {
if (((tObject instanceof Entity)) && (!((Entity) tObject).isDead)) {
Entity tEntity = (Entity) tObject;
- // GT_FML_LOGGER.info("teleport"+(Math.pow(tDistance, 1.5)));
- if (getBaseMetaTileEntity()
- .decreaseStoredEnergyUnits(
- (long) (Math.pow(tDistance, 1.5)
- * weightCalculation(tEntity)
- * sFPowerMultiplyer),
- false)) {
+ // GT_FML_LOGGER.info("teleport"+(Math.pow(tDistance, 1.5)));
+ if (getBaseMetaTileEntity().decreaseStoredEnergyUnits(
+ (long) (Math.pow(tDistance, 1.5) * weightCalculation(tEntity) * sFPowerMultiplyer),
+ false)) {
// if (hasDimensionalTeleportCapability() && this.mTargetD !=
// getBaseMetaTileEntity().getWorld().provider.dimensionId && (hasEgg ||
// mFluid.isFluidEqual(Materials.Nitrogen.getPlasma(1)))) {
- // mFluid.amount = mFluid.amount - ((int) Math.min(10, (Math.pow(tDistance, 1.5) *
+ // mFluid.amount = mFluid.amount - ((int) Math.min(10, (Math.pow(tDistance, 1.5) *
// weightCalculation(tEntity) / 8192)));
- // if (mFluid.amount < 1) {
- // mFluid = null;
- // }
+ // if (mFluid.amount < 1) {
+ // mFluid = null;
+ // }
// }
if (tEntity.ridingEntity != null) {
tEntity.mountEntity(null);
@@ -446,14 +395,15 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
this.mTargetY + 0.5D,
this.mTargetZ + 0.5D))) {
if ((tEntity instanceof EntityLivingBase)) {
- ((EntityLivingBase) tEntity)
- .setPositionAndUpdate(
- this.mTargetX + 0.5D,
- this.mTargetY + 0.5D,
- this.mTargetZ + 0.5D);
+ ((EntityLivingBase) tEntity).setPositionAndUpdate(
+ this.mTargetX + 0.5D,
+ this.mTargetY + 0.5D,
+ this.mTargetZ + 0.5D);
} else {
tEntity.setPosition(
- this.mTargetX + 0.5D, this.mTargetY + 0.5D, this.mTargetZ + 0.5D);
+ this.mTargetX + 0.5D,
+ this.mTargetY + 0.5D,
+ this.mTargetZ + 0.5D);
}
}
}
@@ -470,11 +420,14 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
private int distanceCalculation() {
return Math.abs(
((this.mTargetD != getBaseMetaTileEntity().getWorld().provider.dimensionId)
- && (isDimensionalTeleportAvailable())
- ? 4000
- : (int) Math.sqrt(Math.pow(getBaseMetaTileEntity().getXCoord() - this.mTargetX, 2.0D)
- + Math.pow(getBaseMetaTileEntity().getYCoord() - this.mTargetY, 2.0D)
- + Math.pow(getBaseMetaTileEntity().getZCoord() - this.mTargetZ, 2.0D))));
+ && (isDimensionalTeleportAvailable())
+ ? 4000
+ : (int) Math.sqrt(
+ Math.pow(getBaseMetaTileEntity().getXCoord() - this.mTargetX, 2.0D)
+ + Math.pow(getBaseMetaTileEntity().getYCoord() - this.mTargetY, 2.0D)
+ + Math.pow(
+ getBaseMetaTileEntity().getZCoord() - this.mTargetZ,
+ 2.0D))));
}
@Override
@@ -614,27 +567,26 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK)
- .setSize(90, 72)
- .setPos(43, 4))
- .widget(TextWidget.dynamicString(() -> "X: " + GT_Utility.parseNumberToString(mTargetX))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 8))
- .widget(TextWidget.dynamicString(() -> "Y: " + GT_Utility.parseNumberToString(mTargetY))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 16))
- .widget(TextWidget.dynamicString(() -> "Z: " + GT_Utility.parseNumberToString(mTargetZ))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 24))
- .widget(TextWidget.dynamicString(() -> "Dim: " + GT_Utility.parseNumberToString(mTargetD))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(46, 32))
- .widget(TextWidget.dynamicString(
- () -> "Dim Valid: " + (GT_Utility.isRealDimension(mTargetD) ? "Yes" : "No"))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setEnabled(widget -> hasDimensionalTeleportCapability())
- .setPos(46, 40))
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK).setSize(90, 72).setPos(43, 4))
+ .widget(
+ TextWidget.dynamicString(() -> "X: " + GT_Utility.parseNumberToString(mTargetX))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 8))
+ .widget(
+ TextWidget.dynamicString(() -> "Y: " + GT_Utility.parseNumberToString(mTargetY))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 16))
+ .widget(
+ TextWidget.dynamicString(() -> "Z: " + GT_Utility.parseNumberToString(mTargetZ))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 24))
+ .widget(
+ TextWidget.dynamicString(() -> "Dim: " + GT_Utility.parseNumberToString(mTargetD))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(46, 32))
+ .widget(
+ TextWidget
+ .dynamicString(
+ () -> "Dim Valid: " + (GT_Utility.isRealDimension(mTargetD) ? "Yes" : "No"))
+ .setDefaultColor(COLOR_TEXT_WHITE.get())
+ .setEnabled(widget -> hasDimensionalTeleportCapability()).setPos(46, 40))
.widget(new FakeSyncWidget.FluidStackSyncer(() -> mFluid, val -> mFluid = val));
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE, -512, -64, 7);
@@ -643,33 +595,38 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
addChangeNumberButtons(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_LARGE, 512, 64, 151);
addChangeNumberButton(
- builder, GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE, val -> mTargetD += val, -16, -8, 7, 58);
+ builder,
+ GT_UITextures.OVERLAY_BUTTON_MINUS_LARGE,
+ val -> mTargetD += val,
+ -16,
+ -8,
+ 7,
+ 58);
addChangeNumberButton(
- builder, GT_UITextures.OVERLAY_BUTTON_MINUS_SMALL, val -> mTargetD += val, -4, -1, 25, 58);
+ builder,
+ GT_UITextures.OVERLAY_BUTTON_MINUS_SMALL,
+ val -> mTargetD += val,
+ -4,
+ -1,
+ 25,
+ 58);
addChangeNumberButton(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_SMALL, val -> mTargetD += val, 4, 1, 133, 58);
addChangeNumberButton(builder, GT_UITextures.OVERLAY_BUTTON_PLUS_LARGE, val -> mTargetD += val, 16, 8, 151, 58);
}
- private void addChangeNumberButtons(
- ModularWindow.Builder builder, IDrawable overlay, int addNumberShift, int addNumber, int xPos) {
+ private void addChangeNumberButtons(ModularWindow.Builder builder, IDrawable overlay, int addNumberShift,
+ int addNumber, int xPos) {
addChangeNumberButton(builder, overlay, val -> mTargetX += val, addNumberShift, addNumber, xPos, 4);
addChangeNumberButton(builder, overlay, val -> mTargetY += val, addNumberShift, addNumber, xPos, 22);
addChangeNumberButton(builder, overlay, val -> mTargetZ += val, addNumberShift, addNumber, xPos, 40);
}
- private void addChangeNumberButton(
- ModularWindow.Builder builder,
- IDrawable overlay,
- Consumer<Integer> setter,
- int addNumberShift,
- int addNumber,
- int xPos,
- int yPos) {
- builder.widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> setter.accept(clickData.shift ? addNumberShift : addNumber))
- .setBackground(GT_UITextures.BUTTON_STANDARD, overlay)
- .setSize(18, 18)
- .setPos(xPos, yPos));
+ private void addChangeNumberButton(ModularWindow.Builder builder, IDrawable overlay, Consumer<Integer> setter,
+ int addNumberShift, int addNumber, int xPos, int yPos) {
+ builder.widget(
+ new ButtonWidget()
+ .setOnClick((clickData, widget) -> setter.accept(clickData.shift ? addNumberShift : addNumber))
+ .setBackground(GT_UITextures.BUTTON_STANDARD, overlay).setSize(18, 18).setPos(xPos, yPos));
}
@Override
@@ -679,9 +636,7 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank
@Override
public void addGregTechLogo(ModularWindow.Builder builder) {
- builder.widget(new DrawableWidget()
- .setDrawable(getGUITextureSet().getGregTechLogo())
- .setSize(17, 17)
- .setPos(113, 56));
+ builder.widget(
+ new DrawableWidget().setDrawable(getGUITextureSet().getGregTechLogo()).setSize(17, 17).setPos(113, 56));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineBase.java b/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineBase.java
index f6bc532469..cae467c4a0 100644
--- a/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineBase.java
+++ b/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineBase.java
@@ -6,18 +6,16 @@
*
* This file is part of GregTech.
*
- * GregTech is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
+ * GregTech is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
+ * version.
*
- * GregTech is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License for more details.
+ * GregTech is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details.
*
- * You should have received a copy of the GNU Lesser General Public License
- * along with GregTech. If not, see <http://www.gnu.org/licenses/>.
+ * You should have received a copy of the GNU Lesser General Public License along with GregTech. If not, see
+ * <http://www.gnu.org/licenses/>.
*/
package gregtech.common.tileentities.machines.long_distance;
@@ -28,14 +26,6 @@ import static mcp.mobius.waila.api.SpecialChars.RED;
import static mcp.mobius.waila.api.SpecialChars.RESET;
import static mcp.mobius.waila.api.SpecialChars.YELLOW;
-import gregtech.api.GregTech_API;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.items.GT_Block_LongDistancePipe;
-import gregtech.api.metatileentity.BaseMetaTileEntity;
-import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicHull_NonElectric;
-import gregtech.api.util.GT_Utility;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
@@ -43,8 +33,10 @@ import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Queue;
+
import mcp.mobius.waila.api.IWailaConfigHandler;
import mcp.mobius.waila.api.IWailaDataAccessor;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.player.EntityPlayerMP;
@@ -55,7 +47,17 @@ import net.minecraft.util.ChunkCoordinates;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
+import gregtech.api.GregTech_API;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.items.GT_Block_LongDistancePipe;
+import gregtech.api.metatileentity.BaseMetaTileEntity;
+import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicHull_NonElectric;
+import gregtech.api.util.GT_Utility;
+
public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_MetaTileEntity_BasicHull_NonElectric {
+
public static int minimalDistancePoints = 64;
protected GT_MetaTileEntity_LongDistancePipelineBase mTarget = null;
// these two are updated by machine block update thread, so must be volatile
@@ -63,13 +65,13 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
protected volatile ChunkCoordinates mTargetPos = null;
protected GT_MetaTileEntity_LongDistancePipelineBase mTooCloseTarget = null, mTooCloseSender = null;
- public GT_MetaTileEntity_LongDistancePipelineBase(
- int aID, String aName, String aNameRegional, int aTier, String aDescription) {
+ public GT_MetaTileEntity_LongDistancePipelineBase(int aID, String aName, String aNameRegional, int aTier,
+ String aDescription) {
super(aID, aName, aNameRegional, aTier, aDescription);
}
- public GT_MetaTileEntity_LongDistancePipelineBase(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_LongDistancePipelineBase(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
@@ -89,7 +91,9 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
super.loadNBTData(aNBT);
if (aNBT.hasKey("target")) {
mTargetPos = new ChunkCoordinates(
- aNBT.getInteger("target.x"), aNBT.getInteger("target.y"), aNBT.getInteger("target.z"));
+ aNBT.getInteger("target.x"),
+ aNBT.getInteger("target.y"),
+ aNBT.getInteger("target.z"));
if (getDistanceToSelf(mTargetPos) < minimalDistancePoints) mTargetPos = null;
}
}
@@ -125,15 +129,15 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
// We don't have a target position, scan the pipes
scanPipes();
} else if (mTarget == null || mTarget.isDead()) {
- // We don't have a target, or it's dead. Try checking the target position
+ // We don't have a target, or it's dead. Try checking the target position
mTarget = null;
if (world.blockExists(mTargetPos.posX, mTargetPos.posY, mTargetPos.posZ)) {
// Only check if the target position is loaded
TileEntity te = world.getTileEntity(mTargetPos.posX, mTargetPos.posY, mTargetPos.posZ);
final IMetaTileEntity tMeta;
if (te instanceof BaseMetaTileEntity
- && ((tMeta = ((BaseMetaTileEntity) te).getMetaTileEntity())
- instanceof GT_MetaTileEntity_LongDistancePipelineBase)
+ && ((tMeta = ((BaseMetaTileEntity) te)
+ .getMetaTileEntity()) instanceof GT_MetaTileEntity_LongDistancePipelineBase)
&& isSameClass((GT_MetaTileEntity_LongDistancePipelineBase) tMeta)) {
// It's the right type!
mTarget = (GT_MetaTileEntity_LongDistancePipelineBase) tMeta;
@@ -147,8 +151,7 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
if (mTooCloseSender != null && (mTooCloseSender.isDead() || mTooCloseSender.mTarget != null))
mTooCloseSender = null;
if (mTarget == null || mTarget == this) return false;
- if (mTarget.mSender == null
- || mTarget.mSender.isDead()
+ if (mTarget.mSender == null || mTarget.mSender.isDead()
|| mTarget.mSender.mTarget == null
|| mTarget.mSender.mTarget.isDead()) {
mTarget.mSender = this;
@@ -159,17 +162,23 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
}
@Override
- public ArrayList<String> getSpecialDebugInfo(
- IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer, int aLogLevel, ArrayList<String> aList) {
+ public ArrayList<String> getSpecialDebugInfo(IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer,
+ int aLogLevel, ArrayList<String> aList) {
if (mSender != null && !mSender.isDead() && mSender.mTarget == this) {
final ChunkCoordinates coords = mSender.getCoords();
- aList.addAll(Arrays.asList(
- "Is the Target", "Sender is at: X: " + coords.posX + " Y: " + coords.posY + " Z: " + coords.posZ));
+ aList.addAll(
+ Arrays.asList(
+ "Is the Target",
+ "Sender is at: X: " + coords.posX + " Y: " + coords.posY + " Z: " + coords.posZ));
} else {
- aList.addAll(Arrays.asList(
- checkTarget() ? "Has Target" : "Has no loaded Target",
- "Target should be around: X: " + mTargetPos.posX + " Y: " + mTargetPos.posY + " Z: "
- + mTargetPos.posZ));
+ aList.addAll(
+ Arrays.asList(
+ checkTarget() ? "Has Target" : "Has no loaded Target",
+ "Target should be around: X: " + mTargetPos.posX
+ + " Y: "
+ + mTargetPos.posY
+ + " Z: "
+ + mTargetPos.posZ));
}
return aList;
@@ -201,8 +210,8 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
HashSet<ChunkCoordinates> tVisited = new HashSet<>(Collections.singletonList(getCoords())),
tWires = new HashSet<>();
- Queue<ChunkCoordinates> tQueue =
- new LinkedList<>(Collections.singletonList(getFacingOffset(gtTile, gtTile.getBackFacing())));
+ Queue<ChunkCoordinates> tQueue = new LinkedList<>(
+ Collections.singletonList(getFacingOffset(gtTile, gtTile.getBackFacing())));
while (!tQueue.isEmpty()) {
final ChunkCoordinates aCoords = tQueue.poll();
@@ -231,15 +240,13 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
} else {
// It's not a block - let's see if it's a tile entity
TileEntity tTileEntity = world.getTileEntity(aCoords.posX, aCoords.posY, aCoords.posZ);
- if (tTileEntity != gtTile
- && tTileEntity instanceof BaseMetaTileEntity
- && ((BaseMetaTileEntity) tTileEntity).getMetaTileEntity()
- instanceof GT_MetaTileEntity_LongDistancePipelineBase) {
- final GT_MetaTileEntity_LongDistancePipelineBase tGtTile =
- (GT_MetaTileEntity_LongDistancePipelineBase)
- ((BaseMetaTileEntity) tTileEntity).getMetaTileEntity();
- if (isSameClass(tGtTile)
- && tWires.contains(tGtTile.getFacingOffset(
+ if (tTileEntity != gtTile && tTileEntity instanceof BaseMetaTileEntity
+ && ((BaseMetaTileEntity) tTileEntity)
+ .getMetaTileEntity() instanceof GT_MetaTileEntity_LongDistancePipelineBase) {
+ final GT_MetaTileEntity_LongDistancePipelineBase tGtTile = (GT_MetaTileEntity_LongDistancePipelineBase) ((BaseMetaTileEntity) tTileEntity)
+ .getMetaTileEntity();
+ if (isSameClass(tGtTile) && tWires.contains(
+ tGtTile.getFacingOffset(
(BaseMetaTileEntity) tTileEntity,
((BaseMetaTileEntity) tTileEntity).getFrontFacing()))) {
// If it's the same class, and we've scanned a wire in front of it (the input side), we've
@@ -276,7 +283,9 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
public ChunkCoordinates getFacingOffset(IGregTechTileEntity gt_tile, byte aSide) {
return new ChunkCoordinates(
- gt_tile.getOffsetX(aSide, 1), gt_tile.getOffsetY(aSide, 1), gt_tile.getOffsetZ(aSide, 1));
+ gt_tile.getOffsetX(aSide, 1),
+ gt_tile.getOffsetY(aSide, 1),
+ gt_tile.getOffsetZ(aSide, 1));
}
public ChunkCoordinates getCoords() {
@@ -302,8 +311,8 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
}
@Override
- public void getWailaBody(
- ItemStack itemStack, List<String> currentTip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
+ public void getWailaBody(ItemStack itemStack, List<String> currentTip, IWailaDataAccessor accessor,
+ IWailaConfigHandler config) {
final NBTTagCompound tag = accessor.getNBTData();
final int facing = getBaseMetaTileEntity().getFrontFacing();
final int side = (byte) accessor.getSide().ordinal();
@@ -326,8 +335,8 @@ public abstract class GT_MetaTileEntity_LongDistancePipelineBase extends GT_Meta
}
@Override
- public void getWailaNBTData(
- EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y, int z) {
+ public void getWailaNBTData(EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y,
+ int z) {
super.getWailaNBTData(player, tile, tag, world, x, y, z);
tag.setBoolean("hasSender", mSender != null);
diff --git a/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineFluid.java b/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineFluid.java
index 849ce40101..ce020560cb 100644
--- a/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineFluid.java
+++ b/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineFluid.java
@@ -6,18 +6,16 @@
*
* This file is part of GregTech.
*
- * GregTech is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
+ * GregTech is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
+ * version.
*
- * GregTech is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License for more details.
+ * GregTech is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details.
*
- * You should have received a copy of the GNU Lesser General Public License
- * along with GregTech. If not, see <http://www.gnu.org/licenses/>.
+ * You should have received a copy of the GNU Lesser General Public License along with GregTech. If not, see
+ * <http://www.gnu.org/licenses/>.
*/
package gregtech.common.tileentities.machines.long_distance;
@@ -27,26 +25,28 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPELINE_FLUID_FRON
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPELINE_FLUID_SIDE;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPELINE_FLUID_SIDE_GLOW;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_Utility;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidTankInfo;
import net.minecraftforge.fluids.IFluidHandler;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_Utility;
+
public class GT_MetaTileEntity_LongDistancePipelineFluid extends GT_MetaTileEntity_LongDistancePipelineBase {
- static final FluidTankInfo[] emptyTank = {new FluidTankInfo(null, Integer.MAX_VALUE)};
+
+ static final FluidTankInfo[] emptyTank = { new FluidTankInfo(null, Integer.MAX_VALUE) };
public GT_MetaTileEntity_LongDistancePipelineFluid(int aID, String aName, String aNameRegional, int aTier) {
super(aID, aName, aNameRegional, aTier, "Sends fluids over long distances");
}
- public GT_MetaTileEntity_LongDistancePipelineFluid(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_LongDistancePipelineFluid(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
@@ -109,29 +109,14 @@ public class GT_MetaTileEntity_LongDistancePipelineFluid extends GT_MetaTileEnti
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide == aFacing)
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPELINE_FLUID_FRONT)
- };
- else if (aSide == GT_Utility.getOppositeSide(aFacing))
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPELINE_FLUID_BACK)
- };
- else
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide == aFacing) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
+ TextureFactory.of(OVERLAY_PIPELINE_FLUID_FRONT) };
+ else if (aSide == GT_Utility.getOppositeSide(aFacing)) return new ITexture[] {
+ MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPELINE_FLUID_BACK) };
+ else return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
TextureFactory.of(OVERLAY_PIPELINE_FLUID_SIDE),
- TextureFactory.builder()
- .addIcon(OVERLAY_PIPELINE_FLUID_SIDE_GLOW)
- .glow()
- .build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_PIPELINE_FLUID_SIDE_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineItem.java b/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineItem.java
index 0559290df6..d62e87c707 100644
--- a/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineItem.java
+++ b/src/main/java/gregtech/common/tileentities/machines/long_distance/GT_MetaTileEntity_LongDistancePipelineItem.java
@@ -6,18 +6,16 @@
*
* This file is part of GregTech.
*
- * GregTech is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
+ * GregTech is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
+ * version.
*
- * GregTech is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License for more details.
+ * GregTech is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details.
*
- * You should have received a copy of the GNU Lesser General Public License
- * along with GregTech. If not, see <http://www.gnu.org/licenses/>.
+ * You should have received a copy of the GNU Lesser General Public License along with GregTech. If not, see
+ * <http://www.gnu.org/licenses/>.
*/
package gregtech.common.tileentities.machines.long_distance;
@@ -27,24 +25,26 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPELINE_ITEM_FRONT
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPELINE_ITEM_SIDE;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_PIPELINE_ITEM_SIDE_GLOW;
+import net.minecraft.inventory.IInventory;
+import net.minecraft.inventory.ISidedInventory;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+
import gregtech.api.enums.GT_Values;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import net.minecraft.inventory.IInventory;
-import net.minecraft.inventory.ISidedInventory;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
public class GT_MetaTileEntity_LongDistancePipelineItem extends GT_MetaTileEntity_LongDistancePipelineBase {
+
public GT_MetaTileEntity_LongDistancePipelineItem(int aID, String aName, String aNameRegional, int aTier) {
super(aID, aName, aNameRegional, aTier, "Sends Items over long distances");
}
- public GT_MetaTileEntity_LongDistancePipelineItem(
- String aName, int aTier, String aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_LongDistancePipelineItem(String aName, int aTier, String aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, aDescription, aTextures);
}
@@ -145,7 +145,7 @@ public class GT_MetaTileEntity_LongDistancePipelineItem extends GT_MetaTileEntit
return false;
}
- // // Relay Sided Inventories
+ // // Relay Sided Inventories
//
@Override
@@ -188,29 +188,14 @@ public class GT_MetaTileEntity_LongDistancePipelineItem extends GT_MetaTileEntit
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide == aFacing)
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPELINE_ITEM_FRONT)
- };
- else if (aSide == GT_Utility.getOppositeSide(aFacing))
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPELINE_ITEM_BACK)
- };
- else
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide == aFacing) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
+ TextureFactory.of(OVERLAY_PIPELINE_ITEM_FRONT) };
+ else if (aSide == GT_Utility.getOppositeSide(aFacing)) return new ITexture[] {
+ MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPELINE_ITEM_BACK) };
+ else return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1],
TextureFactory.of(OVERLAY_PIPELINE_ITEM_SIDE),
- TextureFactory.builder()
- .addIcon(OVERLAY_PIPELINE_ITEM_SIDE_GLOW)
- .glow()
- .build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_PIPELINE_ITEM_SIDE_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AbstractMultiFurnace.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AbstractMultiFurnace.java
index 3dde1feb83..51c7c2eb13 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AbstractMultiFurnace.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AbstractMultiFurnace.java
@@ -1,9 +1,10 @@
package gregtech.common.tileentities.machines.multi;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.HeatingCoilLevel;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_EnhancedMultiBlockBase;
-import net.minecraft.item.ItemStack;
public abstract class GT_MetaTileEntity_AbstractMultiFurnace<T extends GT_MetaTileEntity_AbstractMultiFurnace<T>>
extends GT_MetaTileEntity_EnhancedMultiBlockBase<T> {
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AssemblyLine.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AssemblyLine.java
index e5b7110659..6f09aa6ede 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AssemblyLine.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_AssemblyLine.java
@@ -10,10 +10,19 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_ASSEMBLY_LINE
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofHatchAdder;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.ItemList;
@@ -34,84 +43,66 @@ import gregtech.api.util.*;
import gregtech.api.util.GT_Recipe.GT_Recipe_AssemblyLine;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.IGT_HatchAdder;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
-public class GT_MetaTileEntity_AssemblyLine
- extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_AssemblyLine>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_AssemblyLine extends
+ GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_AssemblyLine> implements ISurvivalConstructable {
public ArrayList<GT_MetaTileEntity_Hatch_DataAccess> mDataAccessHatches = new ArrayList<>();
private static final String STRUCTURE_PIECE_FIRST = "first";
private static final String STRUCTURE_PIECE_LATER = "later";
private static final String STRUCTURE_PIECE_LAST = "last";
- private static final IStructureDefinition<GT_MetaTileEntity_AssemblyLine> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_AssemblyLine>builder()
- .addShape(STRUCTURE_PIECE_FIRST, transpose(new String[][] {
- {" ", "e", " "},
- {"~", "l", "G"},
- {"g", "m", "g"},
- {"b", "i", "b"},
- }))
- .addShape(STRUCTURE_PIECE_LATER, transpose(new String[][] {
- {" ", "e", " "},
- {"d", "l", "d"},
- {"g", "m", "g"},
- {"b", "I", "b"},
- }))
- .addShape(STRUCTURE_PIECE_LAST, transpose(new String[][] {
- {" ", "e", " "},
- {"d", "l", "d"},
- {"g", "m", "g"},
- {"o", "i", "b"},
- }))
- .addElement('G', ofBlock(GregTech_API.sBlockCasings3, 10)) // grate machine casing
- .addElement('l', ofBlock(GregTech_API.sBlockCasings2, 9)) // assembler machine casing
- .addElement('m', ofBlock(GregTech_API.sBlockCasings2, 5)) // assembling line casing
- .addElement(
- 'g',
- ofChain(
- ofBlockUnlocalizedName("IC2", "blockAlloyGlass", 0, true),
- ofBlockUnlocalizedName("bartworks", "BW_GlasBlocks", 0, true),
- // warded glass
- ofBlockUnlocalizedName("Thaumcraft", "blockCosmeticOpaque", 2, false)))
- .addElement(
- 'e',
- ofChain(
- Energy.newAny(16, 1, ForgeDirection.UP, ForgeDirection.NORTH, ForgeDirection.SOUTH),
- ofBlock(GregTech_API.sBlockCasings2, 0)))
- .addElement(
- 'd',
- buildHatchAdder(GT_MetaTileEntity_AssemblyLine.class)
- .atLeast(DataHatchElement.DataAccess)
- .dot(2)
- .casingIndex(42)
- .allowOnly(ForgeDirection.NORTH)
- .buildAndChain(GregTech_API.sBlockCasings3, 10))
- .addElement(
- 'b',
- buildHatchAdder(GT_MetaTileEntity_AssemblyLine.class)
- .atLeast(InputHatch, InputHatch, InputHatch, InputHatch, Maintenance)
- .casingIndex(16)
- .dot(3)
- .allowOnly(ForgeDirection.DOWN)
- .buildAndChain(
- ofBlock(GregTech_API.sBlockCasings2, 0),
- ofHatchAdder(
- GT_MetaTileEntity_AssemblyLine::addOutputToMachineList, 16, 4)))
- .addElement(
- 'I',
- ofChain(
- // all blocks nearby use solid steel casing, so let's use the texture of that
- InputBus.newAny(16, 5, ForgeDirection.DOWN),
+ private static final IStructureDefinition<GT_MetaTileEntity_AssemblyLine> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_AssemblyLine>builder()
+ .addShape(
+ STRUCTURE_PIECE_FIRST,
+ transpose(
+ new String[][] { { " ", "e", " " }, { "~", "l", "G" }, { "g", "m", "g" },
+ { "b", "i", "b" }, }))
+ .addShape(
+ STRUCTURE_PIECE_LATER,
+ transpose(
+ new String[][] { { " ", "e", " " }, { "d", "l", "d" }, { "g", "m", "g" },
+ { "b", "I", "b" }, }))
+ .addShape(
+ STRUCTURE_PIECE_LAST,
+ transpose(
+ new String[][] { { " ", "e", " " }, { "d", "l", "d" }, { "g", "m", "g" },
+ { "o", "i", "b" }, }))
+ .addElement('G', ofBlock(GregTech_API.sBlockCasings3, 10)) // grate machine casing
+ .addElement('l', ofBlock(GregTech_API.sBlockCasings2, 9)) // assembler machine casing
+ .addElement('m', ofBlock(GregTech_API.sBlockCasings2, 5)) // assembling line casing
+ .addElement(
+ 'g',
+ ofChain(
+ ofBlockUnlocalizedName("IC2", "blockAlloyGlass", 0, true),
+ ofBlockUnlocalizedName("bartworks", "BW_GlasBlocks", 0, true),
+ // warded glass
+ ofBlockUnlocalizedName("Thaumcraft", "blockCosmeticOpaque", 2, false)))
+ .addElement(
+ 'e',
+ ofChain(
+ Energy.newAny(16, 1, ForgeDirection.UP, ForgeDirection.NORTH, ForgeDirection.SOUTH),
+ ofBlock(GregTech_API.sBlockCasings2, 0)))
+ .addElement(
+ 'd',
+ buildHatchAdder(GT_MetaTileEntity_AssemblyLine.class).atLeast(DataHatchElement.DataAccess).dot(2)
+ .casingIndex(42).allowOnly(ForgeDirection.NORTH)
+ .buildAndChain(GregTech_API.sBlockCasings3, 10))
+ .addElement(
+ 'b',
+ buildHatchAdder(GT_MetaTileEntity_AssemblyLine.class)
+ .atLeast(InputHatch, InputHatch, InputHatch, InputHatch, Maintenance).casingIndex(16).dot(3)
+ .allowOnly(ForgeDirection.DOWN).buildAndChain(
+ ofBlock(GregTech_API.sBlockCasings2, 0),
ofHatchAdder(GT_MetaTileEntity_AssemblyLine::addOutputToMachineList, 16, 4)))
- .addElement('i', InputBus.newAny(16, 5, ForgeDirection.DOWN))
- .addElement('o', OutputBus.newAny(16, 4, ForgeDirection.DOWN))
- .build();
+ .addElement(
+ 'I',
+ ofChain(
+ // all blocks nearby use solid steel casing, so let's use the texture of that
+ InputBus.newAny(16, 5, ForgeDirection.DOWN),
+ ofHatchAdder(GT_MetaTileEntity_AssemblyLine::addOutputToMachineList, 16, 4)))
+ .addElement('i', InputBus.newAny(16, 5, ForgeDirection.DOWN))
+ .addElement('o', OutputBus.newAny(16, 4, ForgeDirection.DOWN)).build();
public GT_MetaTileEntity_AssemblyLine(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
@@ -129,12 +120,9 @@ public class GT_MetaTileEntity_AssemblyLine
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Assembling Line")
- .addInfo("Controller block for the Assembling Line")
- .addInfo("Used to make complex machine parts (LuV+)")
- .addInfo("Does not make Assembler items")
- .addSeparator()
- .beginVariableStructureBlock(5, 16, 4, 4, 3, 3, false) // ?
+ tt.addMachineType("Assembling Line").addInfo("Controller block for the Assembling Line")
+ .addInfo("Used to make complex machine parts (LuV+)").addInfo("Does not make Assembler items")
+ .addSeparator().beginVariableStructureBlock(5, 16, 4, 4, 3, 3, false) // ?
.addStructureInfo("From Bottom to Top, Left to Right")
.addStructureInfo(
"Layer 1 - Solid Steel Machine Casing, Input Bus (last can be Output Bus), Solid Steel Machine Casing")
@@ -143,10 +131,8 @@ public class GT_MetaTileEntity_AssemblyLine
.addStructureInfo("Layer 3 - Grate Machine Casing, Assembler Machine Casing, Grate Machine Casing")
.addStructureInfo("Layer 4 - Empty, Solid Steel Machine Casing, Empty")
.addStructureInfo("Up to 16 repeating slices, each one allows for 1 more item in recipes")
- .addController("Either Grate on layer 3 of the first slice")
- .addEnergyHatch("Any layer 4 casing", 1)
- .addMaintenanceHatch("Any layer 1 casing", 3)
- .addInputBus("As specified on layer 1", 4, 5)
+ .addController("Either Grate on layer 3 of the first slice").addEnergyHatch("Any layer 4 casing", 1)
+ .addMaintenanceHatch("Any layer 1 casing", 3).addInputBus("As specified on layer 1", 4, 5)
.addInputHatch("Any layer 1 casing", 3)
.addOutputBus("Replaces Input Bus on final slice or on any solid steel casing on layer 1", 4)
.addOtherStructurePart("Data Access Hatch", "Optional, next to controller", 2)
@@ -155,41 +141,18 @@ public class GT_MetaTileEntity_AssemblyLine
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- BlockIcons.casingTexturePages[0][16],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- BlockIcons.casingTexturePages[0][16],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { BlockIcons.casingTexturePages[0][16],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { BlockIcons.casingTexturePages[0][16],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {Textures.BlockIcons.casingTexturePages[0][16]};
+ return new ITexture[] { Textures.BlockIcons.casingTexturePages[0][16] };
}
@Override
@@ -220,10 +183,9 @@ public class GT_MetaTileEntity_AssemblyLine
int[] tFluidSlot = null;
boolean foundRecipe = false;
- nextDataStick:
- for (ItemStack tDataStick : tDataStickList) {
- GT_AssemblyLineUtils.LookupResult tLookupResult =
- GT_AssemblyLineUtils.findAssemblyLineRecipeFromDataStick(tDataStick, false);
+ nextDataStick: for (ItemStack tDataStick : tDataStickList) {
+ GT_AssemblyLineUtils.LookupResult tLookupResult = GT_AssemblyLineUtils
+ .findAssemblyLineRecipeFromDataStick(tDataStick, false);
if (tLookupResult.getType() == GT_AssemblyLineUtils.LookupResultType.INVALID_STICK) continue;
@@ -281,8 +243,8 @@ public class GT_MetaTileEntity_AssemblyLine
continue nextDataStick;
} else {
if (mInputHatches.get(i) instanceof GT_MetaTileEntity_Hatch_MultiInput) {
- GT_MetaTileEntity_Hatch_MultiInput tMultiHatch =
- (GT_MetaTileEntity_Hatch_MultiInput) mInputHatches.get(i);
+ GT_MetaTileEntity_Hatch_MultiInput tMultiHatch = (GT_MetaTileEntity_Hatch_MultiInput) mInputHatches
+ .get(i);
if (!tMultiHatch.hasFluid(tRecipe.mFluidInputs[i])
|| tMultiHatch.getFluidAmount(tRecipe.mFluidInputs[i])
< tRecipe.mFluidInputs[i].amount) {
@@ -318,7 +280,7 @@ public class GT_MetaTileEntity_AssemblyLine
if (GT_Values.D1) {
GT_FML_LOGGER.info("Find available recipe");
}
- mOutputItems = new ItemStack[] {tRecipe.mOutput};
+ mOutputItems = new ItemStack[] { tRecipe.mOutput };
foundRecipe = true;
break;
}
@@ -338,8 +300,8 @@ public class GT_MetaTileEntity_AssemblyLine
for (int i = 0; i < tFluids.length; i++) {
if (mInputHatches.get(i) instanceof GT_MetaTileEntity_Hatch_MultiInput) {
- GT_MetaTileEntity_Hatch_MultiInput tMultiHatch =
- (GT_MetaTileEntity_Hatch_MultiInput) mInputHatches.get(i);
+ GT_MetaTileEntity_Hatch_MultiInput tMultiHatch = (GT_MetaTileEntity_Hatch_MultiInput) mInputHatches
+ .get(i);
tMultiHatch.getFluid(tFluidSlot[i]).amount -= tFluids[i];
if (tMultiHatch.getFluid(tFluidSlot[i]).amount <= 0) {
tMultiHatch.setFluid(null, tFluidSlot[i]);
@@ -494,6 +456,7 @@ public class GT_MetaTileEntity_AssemblyLine
}
private enum DataHatchElement implements IHatchElement<GT_MetaTileEntity_AssemblyLine> {
+
DataAccess;
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BrickedBlastFurnace.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BrickedBlastFurnace.java
index 7536735634..5babf4405d 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BrickedBlastFurnace.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BrickedBlastFurnace.java
@@ -1,5 +1,10 @@
package gregtech.common.tileentities.machines.multi;
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+
+import org.lwjgl.input.Keyboard;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.SteamVariant;
@@ -11,23 +16,16 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import org.lwjgl.input.Keyboard;
public class GT_MetaTileEntity_BrickedBlastFurnace extends GT_MetaTileEntity_PrimitiveBlastFurnace
implements ISecondaryDescribable {
- private static final ITexture[] FACING_SIDE = {TextureFactory.of(Textures.BlockIcons.MACHINE_CASING_DENSEBRICKS)};
+
+ private static final ITexture[] FACING_SIDE = { TextureFactory.of(Textures.BlockIcons.MACHINE_CASING_DENSEBRICKS) };
private static final ITexture[] FACING_FRONT = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_CASING_BRICKEDBLASTFURNACE_INACTIVE)
- };
+ TextureFactory.of(Textures.BlockIcons.MACHINE_CASING_BRICKEDBLASTFURNACE_INACTIVE) };
private static final ITexture[] FACING_ACTIVE = {
- TextureFactory.of(Textures.BlockIcons.MACHINE_CASING_BRICKEDBLASTFURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(BlockIcons.MACHINE_CASING_BRICKEDBLASTFURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ TextureFactory.of(Textures.BlockIcons.MACHINE_CASING_BRICKEDBLASTFURNACE_ACTIVE), TextureFactory.builder()
+ .addIcon(BlockIcons.MACHINE_CASING_BRICKEDBLASTFURNACE_ACTIVE_GLOW).glow().build() };
private GT_Multiblock_Tooltip_Builder tooltipBuilder;
public GT_MetaTileEntity_BrickedBlastFurnace(int aID, String aName, String aNameRegional) {
@@ -59,32 +57,22 @@ public class GT_MetaTileEntity_BrickedBlastFurnace extends GT_MetaTileEntity_Pri
protected GT_Multiblock_Tooltip_Builder getTooltip() {
if (tooltipBuilder == null) {
tooltipBuilder = new GT_Multiblock_Tooltip_Builder();
- tooltipBuilder
- .addMachineType("Blast Furnace")
- .addInfo("Controller Block for the Bricked Blast Furnace")
+ tooltipBuilder.addMachineType("Blast Furnace").addInfo("Controller Block for the Bricked Blast Furnace")
.addInfo("Usable for Steel and general Pyrometallurgy")
.addInfo("Has a useful interface, unlike other gregtech multis")
- .addPollutionAmount(GT_Mod.gregtechproxy.mPollutionPrimitveBlastFurnacePerSecond)
- .addSeparator()
- .beginStructureBlock(3, 4, 3, true)
- .addController("Front center")
+ .addPollutionAmount(GT_Mod.gregtechproxy.mPollutionPrimitveBlastFurnacePerSecond).addSeparator()
+ .beginStructureBlock(3, 4, 3, true).addController("Front center")
.addOtherStructurePart("Firebricks", "Everything except the controller")
.addStructureInfo("The top block is also empty")
.addStructureInfo("You can share the walls of GT multis, so")
- .addStructureInfo("each additional one costs less, up to 4")
- .toolTipFinisher("Gregtech");
+ .addStructureInfo("each additional one costs less, up to 4").toolTipFinisher("Gregtech");
}
return tooltipBuilder;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
return aActive ? FACING_ACTIVE : FACING_FRONT;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BronzeBlastFurnace.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BronzeBlastFurnace.java
index 734d11e4c8..8c22ab780f 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BronzeBlastFurnace.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_BronzeBlastFurnace.java
@@ -5,25 +5,22 @@ import static gregtech.api.enums.Textures.BlockIcons.MACHINE_BRONZEBLASTFURNACE_
import static gregtech.api.enums.Textures.BlockIcons.MACHINE_BRONZEBLASTFURNACE_ACTIVE_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.MACHINE_BRONZEPLATEDBRICKS;
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.SteamVariant;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_BronzeBlastFurnace extends GT_MetaTileEntity_PrimitiveBlastFurnace {
- private static final ITexture[] FACING_SIDE = {TextureFactory.of(MACHINE_BRONZEPLATEDBRICKS)};
- private static final ITexture[] FACING_FRONT = {TextureFactory.of(MACHINE_BRONZEBLASTFURNACE)};
- private static final ITexture[] FACING_ACTIVE = {
- TextureFactory.of(MACHINE_BRONZEBLASTFURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(MACHINE_BRONZEBLASTFURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+
+ private static final ITexture[] FACING_SIDE = { TextureFactory.of(MACHINE_BRONZEPLATEDBRICKS) };
+ private static final ITexture[] FACING_FRONT = { TextureFactory.of(MACHINE_BRONZEBLASTFURNACE) };
+ private static final ITexture[] FACING_ACTIVE = { TextureFactory.of(MACHINE_BRONZEBLASTFURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(MACHINE_BRONZEBLASTFURNACE_ACTIVE_GLOW).glow().build() };
public GT_MetaTileEntity_BronzeBlastFurnace(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
@@ -35,17 +32,12 @@ public class GT_MetaTileEntity_BronzeBlastFurnace extends GT_MetaTileEntity_Prim
@Override
public String[] getDescription() {
- return new String[] {"Disabled"};
+ return new String[] { "Disabled" };
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
return aActive ? FACING_ACTIVE : FACING_FRONT;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Charcoal_Pit.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Charcoal_Pit.java
index 8a2f969b18..4f1aec7f4a 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Charcoal_Pit.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Charcoal_Pit.java
@@ -7,6 +7,16 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_ROCK_BREAKER_
import static gregtech.api.enums.Textures.BlockIcons.casingTexturePages;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.world.ChunkPosition;
+import net.minecraftforge.oredict.OreDictionary;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.OrePrefixes;
@@ -21,14 +31,6 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.WorldSpawnedEventBuilder;
import gregtech.common.GT_Pollution;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.world.ChunkPosition;
-import net.minecraftforge.oredict.OreDictionary;
public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMultiBlockBase
implements ISecondaryDescribable {
@@ -110,15 +112,13 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
if (isWoodLog(
getBaseMetaTileEntity().getBlockOffset(tPos.chunkPosX, tPos.chunkPosY, tPos.chunkPosZ),
getBaseMetaTileEntity().getMetaIDOffset(tPos.chunkPosX, tPos.chunkPosY, tPos.chunkPosZ)))
- getBaseMetaTileEntity()
- .getWorld()
- .setBlock(
- getBaseMetaTileEntity().getXCoord() + tPos.chunkPosX,
- getBaseMetaTileEntity().getYCoord() + tPos.chunkPosY,
- getBaseMetaTileEntity().getZCoord() + tPos.chunkPosZ,
- GregTech_API.sBlockReinforced,
- 4,
- 3);
+ getBaseMetaTileEntity().getWorld().setBlock(
+ getBaseMetaTileEntity().getXCoord() + tPos.chunkPosX,
+ getBaseMetaTileEntity().getYCoord() + tPos.chunkPosY,
+ getBaseMetaTileEntity().getZCoord() + tPos.chunkPosZ,
+ GregTech_API.sBlockReinforced,
+ 4,
+ 3);
}
running = false;
return false;
@@ -134,13 +134,12 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
if (OreDictionary.getOreName(id).equals("logWood")) return true;
}
String tTool = log.getHarvestTool(meta);
- return OrePrefixes.log.contains(new ItemStack(log, 1, meta))
- && ("axe".equals(tTool))
+ return OrePrefixes.log.contains(new ItemStack(log, 1, meta)) && ("axe".equals(tTool))
&& (log.getMaterial() == Material.wood);
}
- private boolean checkAllBlockSides(
- int aX, int aY, int aZ, ArrayList<? super ChunkPosition> aList1, ArrayList<? super ChunkPosition> aList2) {
+ private boolean checkAllBlockSides(int aX, int aY, int aZ, ArrayList<? super ChunkPosition> aList1,
+ ArrayList<? super ChunkPosition> aList2) {
boolean expandToChunkXPos = false;
boolean expandToChunkXNeg = false;
boolean expandToChunkYPos = false;
@@ -151,7 +150,8 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
Block blockXPos = getBaseMetaTileEntity().getBlockOffset(aX + 1, aY, aZ);
if (aX + 1 < 6 && (isWoodLog(blockXPos, getBaseMetaTileEntity().getMetaIDOffset(aX + 1, aY, aZ)))) {
if (!aList1.contains(new ChunkPosition(aX + 1, aY, aZ))
- && (!aList2.contains(new ChunkPosition(aX + 1, aY, aZ)))) expandToChunkXPos = true;
+ && (!aList2.contains(new ChunkPosition(aX + 1, aY, aZ))))
+ expandToChunkXPos = true;
} else if (!(blockXPos == Blocks.dirt || blockXPos == Blocks.grass)) {
return false;
}
@@ -159,7 +159,8 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
Block blockXNeg = getBaseMetaTileEntity().getBlockOffset(aX - 1, aY, aZ);
if (aX - 1 > -6 && (isWoodLog(blockXNeg, getBaseMetaTileEntity().getMetaIDOffset(aX - 1, aY, aZ)))) {
if (!aList1.contains(new ChunkPosition(aX - 1, aY, aZ))
- && (!aList2.contains(new ChunkPosition(aX - 1, aY, aZ)))) expandToChunkXNeg = true;
+ && (!aList2.contains(new ChunkPosition(aX - 1, aY, aZ))))
+ expandToChunkXNeg = true;
} else if (!(blockXNeg == Blocks.dirt || blockXNeg == Blocks.grass)) {
return false;
}
@@ -167,17 +168,18 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
Block blockYPos = getBaseMetaTileEntity().getBlockOffset(aX, aY + 1, aZ);
if (aY + 1 < 1 && (isWoodLog(blockYPos, getBaseMetaTileEntity().getMetaIDOffset(aX, aY + 1, aZ)))) {
if (!aList1.contains(new ChunkPosition(aX, aY + 1, aZ))
- && (!aList2.contains(new ChunkPosition(aX, aY + 1, aZ)))) expandToChunkYPos = true;
- } else if (!(blockYPos == Blocks.dirt
- || blockYPos == Blocks.grass
+ && (!aList2.contains(new ChunkPosition(aX, aY + 1, aZ))))
+ expandToChunkYPos = true;
+ } else if (!(blockYPos == Blocks.dirt || blockYPos == Blocks.grass
|| (aX == 0 && aY == -1 && aZ == 0 && blockYPos == GregTech_API.sBlockMachines))) {
- return false;
- }
+ return false;
+ }
Block blockYNeg = getBaseMetaTileEntity().getBlockOffset(aX, aY - 1, aZ);
if (aY - 1 > -6 && (isWoodLog(blockYNeg, getBaseMetaTileEntity().getMetaIDOffset(aX, aY - 1, aZ)))) {
if (!aList1.contains(new ChunkPosition(aX, aY - 1, aZ))
- && (!aList2.contains(new ChunkPosition(aX, aY - 1, aZ)))) expandToChunkYNeg = true;
+ && (!aList2.contains(new ChunkPosition(aX, aY - 1, aZ))))
+ expandToChunkYNeg = true;
} else if (blockYNeg != Blocks.brick_block) {
return false;
}
@@ -185,7 +187,8 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
Block blockZPos = getBaseMetaTileEntity().getBlockOffset(aX, aY, aZ + 1);
if (aZ + 1 < 6 && (isWoodLog(blockZPos, getBaseMetaTileEntity().getMetaIDOffset(aX, aY, aZ + 1)))) {
if (!aList1.contains(new ChunkPosition(aX, aY, aZ + 1))
- && (!aList2.contains(new ChunkPosition(aX, aY, aZ + 1)))) expandToChunkZPos = true;
+ && (!aList2.contains(new ChunkPosition(aX, aY, aZ + 1))))
+ expandToChunkZPos = true;
} else if (!(blockZPos == Blocks.dirt || blockZPos == Blocks.grass)) {
return false;
}
@@ -193,7 +196,8 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
Block blockZNeg = getBaseMetaTileEntity().getBlockOffset(aX, aY, aZ - 1);
if (aZ - 1 > -6 && (isWoodLog(blockZNeg, getBaseMetaTileEntity().getMetaIDOffset(aX, aY, aZ - 1)))) {
if (!aList1.contains(new ChunkPosition(aX, aY, aZ - 1))
- && (!aList2.contains(new ChunkPosition(aX, aY, aZ - 1)))) expandToChunkZNeg = true;
+ && (!aList2.contains(new ChunkPosition(aX, aY, aZ - 1))))
+ expandToChunkZNeg = true;
} else if (!(blockZNeg == Blocks.dirt || blockZNeg == Blocks.grass)) {
return false;
}
@@ -250,50 +254,29 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Charcoal Pile Igniter")
- .addInfo("Controller for the Charcoal Pit")
- .addInfo("Converts Logs into Brittle Charcoal blocks")
- .addInfo("Will automatically start when valid")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
+ tt.addMachineType("Charcoal Pile Igniter").addInfo("Controller for the Charcoal Pit")
+ .addInfo("Converts Logs into Brittle Charcoal blocks").addInfo("Will automatically start when valid")
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator()
.beginVariableStructureBlock(3, 11, 3, 6, 3, 11, false)
.addStructureInfo("Can be up to 11x6x11 in size, shape doesn't matter")
.addOtherStructurePart("Bricks", "Bottom layer, under all wood logs")
.addOtherStructurePart("Dirt/Grass", "All logs must be covered by these, the controller, or bricks")
.addOtherStructurePart("Wood Logs", "Inside the previously mentioned blocks")
- .addStructureInfo("No air between logs allowed")
- .toolTipFinisher("Gregtech");
+ .addStructureInfo("No air between logs allowed").toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == 1) {
if (aActive)
- return new ITexture[] {
- casingTexturePages[0][10],
- TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW)
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][10],
- TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW)
- .glow()
- .build(),
- };
+ return new ITexture[] { casingTexturePages[0][10], TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_ACTIVE_GLOW).glow().build() };
+ return new ITexture[] { casingTexturePages[0][10], TextureFactory.of(OVERLAY_FRONT_ROCK_BREAKER),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ROCK_BREAKER_GLOW).glow().build(), };
}
- return new ITexture[] {casingTexturePages[0][10]};
+ return new ITexture[] { casingTexturePages[0][10] };
}
@Override
@@ -308,15 +291,13 @@ public class GT_MetaTileEntity_Charcoal_Pit extends GT_MetaTileEntity_TooltipMul
super.onPostTick(aBaseMetaTileEntity, aTimer);
if ((aBaseMetaTileEntity.isClientSide()) && (aBaseMetaTileEntity.isActive())) {
- new WorldSpawnedEventBuilder.ParticleEventBuilder()
- .setMotion(0D, 0.3D, 0D)
+ new WorldSpawnedEventBuilder.ParticleEventBuilder().setMotion(0D, 0.3D, 0D)
.setIdentifier(ParticleFX.LARGE_SMOKE)
.setPosition(
aBaseMetaTileEntity.getOffsetX((byte) 1, 1) + XSTR_INSTANCE.nextFloat(),
aBaseMetaTileEntity.getOffsetY((byte) 1, 1),
aBaseMetaTileEntity.getOffsetZ((byte) 1, 1) + XSTR_INSTANCE.nextFloat())
- .setWorld(getBaseMetaTileEntity().getWorld())
- .run();
+ .setWorld(getBaseMetaTileEntity().getWorld()).run();
}
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Cleanroom.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Cleanroom.java
index 5e6651cdad..aa082afee0 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Cleanroom.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_Cleanroom.java
@@ -4,8 +4,20 @@ import static gregtech.api.enums.GT_Values.ALL_VALID_SIDES;
import static gregtech.api.enums.GT_Values.debugCleanroom;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.HashMap;
+import java.util.Map;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.World;
+import net.minecraftforge.common.config.ConfigCategory;
+import net.minecraftforge.common.config.Configuration;
+import net.minecraftforge.common.util.ForgeDirection;
+
import com.gtnewhorizon.structurelib.StructureLibAPI;
import com.gtnewhorizon.structurelib.alignment.constructable.IConstructable;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
import gregtech.api.interfaces.ISecondaryDescribable;
@@ -19,18 +31,10 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Log;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
-import java.util.HashMap;
-import java.util.Map;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.World;
-import net.minecraftforge.common.config.ConfigCategory;
-import net.minecraftforge.common.config.Configuration;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiBlockBase
implements IConstructable, ISecondaryDescribable {
+
private int mHeight = -1;
public GT_MetaTileEntity_Cleanroom(int aID, String aName, String aNameRegional) {
@@ -49,22 +53,17 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Cleanroom")
- .addInfo("Controller block for the Cleanroom")
+ tt.addMachineType("Cleanroom").addInfo("Controller block for the Cleanroom")
.addInfo("Consumes 40 EU/t when first turned on")
.addInfo("and 4 EU/t once at 100% efficiency when not overclocked") // ?
.addInfo("An energy hatch accepts up to 2A, so you can use 2A LV or 1A MV")
.addInfo("2 LV batteries + 1 LV generator or 1 MV generator") // ?
.addInfo("Time required to reach full efficiency is proportional to")
- .addInfo("the height of empty space within")
- .addInfo("Make sure your Energy Hatch matches! ?")
- .addInfo("Machines that cause pollution aren't allowed to be put in.")
- .addSeparator()
- .beginVariableStructureBlock(3, 15, 4, 15, 3, 15, true)
- .addController("Top center")
+ .addInfo("the height of empty space within").addInfo("Make sure your Energy Hatch matches! ?")
+ .addInfo("Machines that cause pollution aren't allowed to be put in.").addSeparator()
+ .beginVariableStructureBlock(3, 15, 4, 15, 3, 15, true).addController("Top center")
.addCasingInfo("Plascrete", 20)
- .addStructureInfo(
- GT_Values.cleanroomGlass + "% of the Plascrete can be replaced with Reinforced Glass") // check
+ .addStructureInfo(GT_Values.cleanroomGlass + "% of the Plascrete can be replaced with Reinforced Glass") // check
.addStructureInfo("Other material can be used in place of Plascrete. See config for detail") // check
.addOtherStructurePart("Filter Machine Casing", "Top besides controller and edges")
.addEnergyHatch("Any casing. Exactly one.") // check
@@ -72,14 +71,13 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
.addStructureInfo("1x Reinforced Door (keep closed or efficiency will reduce)")
.addStructureInfo("Up to 10 Machine Hulls for Item & Energy transfer through walls")
.addStructureInfo("You can also use Diodes for more power")
- .addStructureInfo("Diodes also count towards 10 Machine Hulls count limit")
- .toolTipFinisher("Gregtech");
+ .addStructureInfo("Diodes also count towards 10 Machine Hulls count limit").toolTipFinisher("Gregtech");
return tt;
}
@Override
public String[] getStructureDescription(ItemStack itemStack) {
- return new String[] {"The structure in both X and Z axis has to be a square."};
+ return new String[] { "The structure in both X and Z axis has to be a square." };
}
@Override
@@ -195,17 +193,17 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
} else if (tBlock == GregTech_API.sBlockReinforced && tMeta == 2) {
mPlascreteCount++;
} else {
- final IGregTechTileEntity tTileEntity =
- aBaseMetaTileEntity.getIGregTechTileEntityOffset(dX, dY, dZ);
+ final IGregTechTileEntity tTileEntity = aBaseMetaTileEntity
+ .getIGregTechTileEntityOffset(dX, dY, dZ);
if ((!this.addMaintenanceToMachineList(tTileEntity, 210))
&& (!this.addEnergyInputToMachineList(tTileEntity, 210))) {
if (tBlock instanceof ic2.core.block.BlockIC2Door) {
if ((tMeta & 8) == 0) {
// let's not fiddle with bits anymore.
if (Math.abs(dZ) < z) // on side parallel to z axis
- doorState = tMeta == 1 || tMeta == 3 || tMeta == 4 || tMeta == 6;
+ doorState = tMeta == 1 || tMeta == 3 || tMeta == 4 || tMeta == 6;
else if (Math.abs(dX) < x) // on side parallel to x axis
- doorState = tMeta == 0 || tMeta == 2 || tMeta == 5 || tMeta == 7;
+ doorState = tMeta == 0 || tMeta == 2 || tMeta == 5 || tMeta == 7;
// corners ignored
}
mDoorCount++;
@@ -222,8 +220,9 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
mHullCount++;
} else {
if (debugCleanroom) {
- GT_Log.out.println("Cleanroom: Incorrect GT block? "
- + tBlock.getUnlocalizedName());
+ GT_Log.out.println(
+ "Cleanroom: Incorrect GT block? "
+ + tBlock.getUnlocalizedName());
}
return false;
}
@@ -236,9 +235,8 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
if (config.containsKey(key)) {
otherBlocks.compute(key, (k, v) -> v == null ? 1 : v + 1);
} else {
- if (debugCleanroom)
- GT_Log.out.println("Cleanroom: not allowed block "
- + tBlock.getUnlocalizedName());
+ if (debugCleanroom) GT_Log.out.println(
+ "Cleanroom: not allowed block " + tBlock.getUnlocalizedName());
return false;
}
}
@@ -250,8 +248,7 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
}
}
}
- if (this.mMaintenanceHatches.size() != 1
- || this.mEnergyHatches.size() != 1
+ if (this.mMaintenanceHatches.size() != 1 || this.mEnergyHatches.size() != 1
|| mDoorCount > 4
|| mHullCount > 10) {
return false;
@@ -289,26 +286,25 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
private void setCallbacks(int x, int y, int z, IGregTechTileEntity aBaseMetaTileEntity) {
for (int dX = -x + 1; dX <= x - 1; dX++)
- for (int dZ = -z + 1; dZ <= z - 1; dZ++)
- for (int dY = -1; dY >= y + 1; dY--) {
- TileEntity tTileEntity = aBaseMetaTileEntity.getTileEntityOffset(dX, dY, dZ);
+ for (int dZ = -z + 1; dZ <= z - 1; dZ++) for (int dY = -1; dY >= y + 1; dY--) {
+ TileEntity tTileEntity = aBaseMetaTileEntity.getTileEntityOffset(dX, dY, dZ);
- if (tTileEntity instanceof IGregTechTileEntity) {
- IMetaTileEntity iMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity();
+ if (tTileEntity instanceof IGregTechTileEntity) {
+ IMetaTileEntity iMetaTileEntity = ((IGregTechTileEntity) tTileEntity).getMetaTileEntity();
- if (iMetaTileEntity instanceof IMachineCallback<?>)
- checkAndSetCallback((IMachineCallback<?>) iMetaTileEntity);
+ if (iMetaTileEntity instanceof IMachineCallback<?>)
+ checkAndSetCallback((IMachineCallback<?>) iMetaTileEntity);
- } else if (tTileEntity instanceof IMachineCallback<?>)
- checkAndSetCallback((IMachineCallback<?>) tTileEntity);
- }
+ } else if (tTileEntity instanceof IMachineCallback<?>)
+ checkAndSetCallback((IMachineCallback<?>) tTileEntity);
+ }
}
@SuppressWarnings("unchecked")
private void checkAndSetCallback(IMachineCallback<?> iMachineCallback) {
- if (debugCleanroom)
- GT_Log.out.println("Cleanroom: IMachineCallback detected, checking for cleanroom: "
- + (iMachineCallback.getType() == this.getClass()));
+ if (debugCleanroom) GT_Log.out.println(
+ "Cleanroom: IMachineCallback detected, checking for cleanroom: "
+ + (iMachineCallback.getType() == this.getClass()));
if (iMachineCallback.getType() == this.getClass())
((IMachineCallback<GT_MetaTileEntity_Cleanroom>) iMachineCallback).setCallbackBase(this);
}
@@ -319,32 +315,18 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == ForgeDirection.DOWN.ordinal() || aSide == ForgeDirection.UP.ordinal()) {
- return new ITexture[] {
- TextureFactory.of(BLOCK_PLASCRETE),
- aActive
- ? TextureFactory.of(
- TextureFactory.of(OVERLAY_TOP_CLEANROOM_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_CLEANROOM_ACTIVE_GLOW)
- .glow()
- .build())
- : TextureFactory.of(
- TextureFactory.of(OVERLAY_TOP_CLEANROOM),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_CLEANROOM_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { TextureFactory.of(BLOCK_PLASCRETE),
+ aActive ? TextureFactory.of(
+ TextureFactory.of(OVERLAY_TOP_CLEANROOM_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_CLEANROOM_ACTIVE_GLOW).glow().build())
+ : TextureFactory.of(
+ TextureFactory.of(OVERLAY_TOP_CLEANROOM),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_CLEANROOM_GLOW).glow().build()) };
}
- return new ITexture[] {TextureFactory.of(BLOCK_PLASCRETE)};
+ return new ITexture[] { TextureFactory.of(BLOCK_PLASCRETE) };
}
@Override
@@ -381,21 +363,20 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
int y = baseEntity.getYCoord();
int z = baseEntity.getZCoord();
int yoff = Math.max(i * 2, 3);
- for (int X = x - i; X <= x + i; X++)
- for (int Y = y; Y >= y - yoff; Y--)
- for (int Z = z - i; Z <= z + i; Z++) {
- if (X == x && Y == y && Z == z) continue;
- if (X == x - i || X == x + i || Z == z - i || Z == z + i || Y == y - yoff) {
- if (b) StructureLibAPI.hintParticle(world, X, Y, Z, GregTech_API.sBlockReinforced, 2);
- else world.setBlock(X, Y, Z, GregTech_API.sBlockReinforced, 2, 2);
- } else if (Y == y) {
- if (b) StructureLibAPI.hintParticle(world, X, Y, Z, GregTech_API.sBlockCasings3, 11);
- else world.setBlock(X, Y, Z, GregTech_API.sBlockCasings3, 11, 2);
- }
- }
+ for (int X = x - i; X <= x + i; X++) for (int Y = y; Y >= y - yoff; Y--) for (int Z = z - i; Z <= z + i; Z++) {
+ if (X == x && Y == y && Z == z) continue;
+ if (X == x - i || X == x + i || Z == z - i || Z == z + i || Y == y - yoff) {
+ if (b) StructureLibAPI.hintParticle(world, X, Y, Z, GregTech_API.sBlockReinforced, 2);
+ else world.setBlock(X, Y, Z, GregTech_API.sBlockReinforced, 2, 2);
+ } else if (Y == y) {
+ if (b) StructureLibAPI.hintParticle(world, X, Y, Z, GregTech_API.sBlockCasings3, 11);
+ else world.setBlock(X, Y, Z, GregTech_API.sBlockCasings3, 11, 2);
+ }
+ }
}
private static class ConfigEntry {
+
int percentage;
int allowedCount;
int meta;
@@ -434,20 +415,14 @@ public class GT_MetaTileEntity_Cleanroom extends GT_MetaTileEntity_TooltipMultiB
for (ConfigCategory cc : cfg.getCategory(category).getChildren()) {
final String name = cc.get("Name").getString();
if (cc.containsKey("Count")) {
- if (cc.containsKey("Meta"))
- config.put(
- name + ":" + cc.get("Meta").getInt(),
- new ConfigEntry(
- 0, cc.get("Count").getInt(), cc.get("Meta").getInt()));
+ if (cc.containsKey("Meta")) config.put(
+ name + ":" + cc.get("Meta").getInt(),
+ new ConfigEntry(0, cc.get("Count").getInt(), cc.get("Meta").getInt()));
else config.put(name, new ConfigEntry(0, cc.get("Count").getInt(), wildcard_meta));
} else if (cc.containsKey("Percentage")) {
- if (cc.containsKey("Meta"))
- config.put(
- name + ":" + cc.get("Meta").getInt(),
- new ConfigEntry(
- cc.get("Percentage").getInt(),
- 0,
- cc.get("Meta").getInt()));
+ if (cc.containsKey("Meta")) config.put(
+ name + ":" + cc.get("Meta").getInt(),
+ new ConfigEntry(cc.get("Percentage").getInt(), 0, cc.get("Meta").getInt()));
else config.put(name, new ConfigEntry(cc.get("Percentage").getInt(), 0, wildcard_meta));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller1.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller1.java
index af1468396b..e61cfc0feb 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller1.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller1.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_ConcreteBackfiller1 extends GT_MetaTileEntity_ConcreteBackfillerBase {
+
public GT_MetaTileEntity_ConcreteBackfiller1(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller2.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller2.java
index 05646676e7..c175d73cb1 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller2.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfiller2.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_ConcreteBackfiller2 extends GT_MetaTileEntity_ConcreteBackfillerBase {
+
public GT_MetaTileEntity_ConcreteBackfiller2(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfillerBase.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfillerBase.java
index de477af9e4..dd2f54455a 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfillerBase.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ConcreteBackfillerBase.java
@@ -3,15 +3,18 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.GT_HatchElement.*;
import static gregtech.api.enums.GT_Values.VN;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+
import com.google.common.collect.ImmutableList;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.interfaces.IHatchElement;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
-import java.util.List;
-import net.minecraft.item.ItemStack;
public abstract class GT_MetaTileEntity_ConcreteBackfillerBase extends GT_MetaTileEntity_DrillerBase {
@@ -29,24 +32,18 @@ public abstract class GT_MetaTileEntity_ConcreteBackfillerBase extends GT_MetaTi
String casings = getCasingBlockItem().get(0).getDisplayName();
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Concrete Backfiller")
- .addInfo("Controller Block for the " + aStructureName)
+ tt.addMachineType("Concrete Backfiller").addInfo("Controller Block for the " + aStructureName)
.addInfo("Will fill in areas below it with light concrete. This goes through walls")
.addInfo("Use it to remove any spawning locations beneath your base to reduce lag")
.addInfo("Will pull back the pipes after it finishes that layer")
- .addInfo("Radius is " + getRadius() + " blocks")
- .addSeparator()
- .beginStructureBlock(3, 7, 3, false)
- .addController("Front bottom")
- .addOtherStructurePart(casings, "form the 3x1x3 Base")
+ .addInfo("Radius is " + getRadius() + " blocks").addSeparator().beginStructureBlock(3, 7, 3, false)
+ .addController("Front bottom").addOtherStructurePart(casings, "form the 3x1x3 Base")
.addOtherStructurePart(casings, "1x3x1 pillar above the center of the base (2 minimum total)")
.addOtherStructurePart(getFrameMaterial().mName + " Frame Boxes", "Each pillar's side and 1x3x1 on top")
- .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1)
- .addMaintenanceHatch("Any base casing", 1)
+ .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1).addMaintenanceHatch("Any base casing", 1)
.addInputBus("Mining Pipes, optional, any base casing", 1)
.addInputHatch("GT Concrete, any base casing", 1)
- .addOutputBus("Mining Pipes, optional, any base casing", 1)
- .toolTipFinisher("Gregtech");
+ .addOutputBus("Mining Pipes, optional, any base casing", 1).toolTipFinisher("Gregtech");
return tt;
}
@@ -73,8 +70,8 @@ public abstract class GT_MetaTileEntity_ConcreteBackfillerBase extends GT_MetaTi
}
@Override
- protected boolean workingUpward(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingUpward(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
if (isRefillableBlock(xPipe, yHead - 1, zPipe)) return tryRefillBlock(xPipe, yHead - 1, zPipe);
int radius = getRadius();
if (mLastXOff == 0 && mLastZOff == 0) {
@@ -107,9 +104,11 @@ public abstract class GT_MetaTileEntity_ConcreteBackfillerBase extends GT_MetaTi
private boolean isRefillableBlock(int aX, int aY, int aZ) {
IGregTechTileEntity aBaseTile = getBaseMetaTileEntity();
if (!aBaseTile.getBlock(aX, aY, aZ).isAir(aBaseTile.getWorld(), aX, aY, aZ)
- || aBaseTile.getBlock(aX, aY, aZ).getMaterial().isSolid()) return false;
- if (!GT_Utility.setBlockByFakePlayer(
- getFakePlayer(aBaseTile), aX, aY, aZ, GregTech_API.sBlockConcretes, 8, true)) return false;
+ || aBaseTile.getBlock(aX, aY, aZ).getMaterial().isSolid())
+ return false;
+ if (!GT_Utility
+ .setBlockByFakePlayer(getFakePlayer(aBaseTile), aX, aY, aZ, GregTech_API.sBlockConcretes, 8, true))
+ return false;
return true;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DieselEngine.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DieselEngine.java
index d6fd5deca4..83ffdd014f 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DieselEngine.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DieselEngine.java
@@ -14,10 +14,20 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_DIESEL_ENGINE
import static gregtech.api.enums.Textures.BlockIcons.casingTexturePages;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
@@ -31,46 +41,34 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidStack;
-public class GT_MetaTileEntity_DieselEngine
- extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_DieselEngine>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_DieselEngine extends
+ GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_DieselEngine> implements ISurvivalConstructable {
+
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_DieselEngine>> STRUCTURE_DEFINITION =
- new ClassValue<IStructureDefinition<GT_MetaTileEntity_DieselEngine>>() {
- @Override
- protected IStructureDefinition<GT_MetaTileEntity_DieselEngine> computeValue(Class<?> type) {
- return StructureDefinition.<GT_MetaTileEntity_DieselEngine>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {
- "---", "iii", "chc", "chc", "ccc",
- },
- {
- "---", "i~i", "hgh", "hgh", "cdc",
- },
- {
- "---", "iii", "chc", "chc", "ccc",
- },
- }))
- .addElement('i', lazy(t -> ofBlock(t.getIntakeBlock(), t.getIntakeMeta())))
- .addElement('c', lazy(t -> ofBlock(t.getCasingBlock(), t.getCasingMeta())))
- .addElement('g', lazy(t -> ofBlock(t.getGearboxBlock(), t.getGearboxMeta())))
- .addElement('d', lazy(t -> Dynamo.newAny(t.getCasingTextureIndex(), 2)))
- .addElement('h', lazy(t -> buildHatchAdder(GT_MetaTileEntity_DieselEngine.class)
- .atLeast(InputHatch, InputHatch, InputHatch, Muffler, Maintenance)
- .casingIndex(t.getCasingTextureIndex())
- .dot(1)
- .buildAndChain(t.getCasingBlock(), t.getCasingMeta())))
- .build();
- }
- };
+ private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_DieselEngine>> STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_DieselEngine>>() {
+
+ @Override
+ protected IStructureDefinition<GT_MetaTileEntity_DieselEngine> computeValue(Class<?> type) {
+ return StructureDefinition.<GT_MetaTileEntity_DieselEngine>builder().addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "---", "iii", "chc", "chc", "ccc", },
+ { "---", "i~i", "hgh", "hgh", "cdc", }, { "---", "iii", "chc", "chc", "ccc", }, }))
+ .addElement('i', lazy(t -> ofBlock(t.getIntakeBlock(), t.getIntakeMeta())))
+ .addElement('c', lazy(t -> ofBlock(t.getCasingBlock(), t.getCasingMeta())))
+ .addElement('g', lazy(t -> ofBlock(t.getGearboxBlock(), t.getGearboxMeta())))
+ .addElement('d', lazy(t -> Dynamo.newAny(t.getCasingTextureIndex(), 2)))
+ .addElement(
+ 'h',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_DieselEngine.class)
+ .atLeast(InputHatch, InputHatch, InputHatch, Muffler, Maintenance)
+ .casingIndex(t.getCasingTextureIndex()).dot(1)
+ .buildAndChain(t.getCasingBlock(), t.getCasingMeta())))
+ .build();
+ }
+ };
protected int fuelConsumption = 0;
protected int fuelValue = 0;
protected int fuelRemaining = 0;
@@ -87,67 +85,37 @@ public class GT_MetaTileEntity_DieselEngine
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Combustion Generator")
- .addInfo("Controller block for the Large Combustion Engine")
+ tt.addMachineType("Combustion Generator").addInfo("Controller block for the Large Combustion Engine")
.addInfo("Supply Diesel Fuels and 1000L of Lubricant per hour to run")
.addInfo("Supply 40L/s of Oxygen to boost output (optional)")
.addInfo("Default: Produces 2048EU/t at 100% fuel efficiency")
.addInfo("Boosted: Produces 6144EU/t at 150% fuel efficiency")
.addInfo("You need to wait for it to reach 300% to output full power")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 3, 4, false)
- .addController("Front center")
- .addCasingInfo("Stable Titanium Machine Casing", 16)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 3, 4, false)
+ .addController("Front center").addCasingInfo("Stable Titanium Machine Casing", 16)
.addOtherStructurePart("Titanium Gear Box Machine Casing", "Inner 2 blocks")
.addOtherStructurePart("Engine Intake Machine Casing", "8x, ring around controller")
.addStructureInfo("Engine Intake Casings must not be obstructed in front (only air blocks)")
- .addDynamoHatch("Back center", 2)
- .addMaintenanceHatch("One of the casings next to a Gear Box", 1)
+ .addDynamoHatch("Back center", 2).addMaintenanceHatch("One of the casings next to a Gear Box", 1)
.addMufflerHatch("Top middle back, above the rear Gear Box", 1)
- .addInputHatch("Diesel Fuel, next to a Gear Box", 1)
- .addInputHatch("Lubricant, next to a Gear Box", 1)
- .addInputHatch("Oxygen, optional, next to a Gear Box", 1)
- .toolTipFinisher("Gregtech");
+ .addInputHatch("Diesel Fuel, next to a Gear Box", 1).addInputHatch("Lubricant, next to a Gear Box", 1)
+ .addInputHatch("Oxygen, optional, next to a Gear Box", 1).toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][50],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DIESEL_ENGINE_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DIESEL_ENGINE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][50],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DIESEL_ENGINE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DIESEL_ENGINE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[0][50],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DIESEL_ENGINE_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DIESEL_ENGINE_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { casingTexturePages[0][50],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DIESEL_ENGINE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DIESEL_ENGINE_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {casingTexturePages[0][50]};
+ return new ITexture[] { casingTexturePages[0][50] };
}
@Override
@@ -161,8 +129,7 @@ public class GT_MetaTileEntity_DieselEngine
}
/**
- * The nominal energy output
- * This can be further multiplied by {@link #getMaxEfficiency(ItemStack)} when boosted
+ * The nominal energy output This can be further multiplied by {@link #getMaxEfficiency(ItemStack)} when boosted
*/
protected int getNominalOutput() {
return 2048;
@@ -173,9 +140,8 @@ public class GT_MetaTileEntity_DieselEngine
}
/**
- * x times fuel will be consumed when boosted
- * This will however NOT increase power output
- * Go tweak {@link #getMaxEfficiency(ItemStack)} and {@link #getNominalOutput()} instead
+ * x times fuel will be consumed when boosted This will however NOT increase power output Go tweak
+ * {@link #getMaxEfficiency(ItemStack)} and {@link #getNominalOutput()} instead
*/
protected int getBoostFactor() {
return 2;
@@ -243,8 +209,7 @@ public class GT_MetaTileEntity_DieselEngine
@Override
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
- return checkPiece(STRUCTURE_PIECE_MAIN, 1, 1, 1)
- && !mMufflerHatches.isEmpty()
+ return checkPiece(STRUCTURE_PIECE_MAIN, 1, 1, 1) && !mMufflerHatches.isEmpty()
&& mMaintenanceHatches.size() == 1;
}
@@ -336,32 +301,51 @@ public class GT_MetaTileEntity_DieselEngine
}
}
- return new String[] {
- EnumChatFormatting.BLUE + "Diesel Engine" + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- getIdealStatus() == getRepairStatus()
- ? EnumChatFormatting.GREEN
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
- + EnumChatFormatting.RESET
- : EnumChatFormatting.RED
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.engine.output") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers((mEUt * mEfficiency / 10000)) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.engine.consumption") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(fuelConsumption) + EnumChatFormatting.RESET + " L/t",
- StatCollector.translateToLocal("GT5U.engine.value") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(fuelValue) + EnumChatFormatting.RESET + " EU/L",
- StatCollector.translateToLocal("GT5U.turbine.fuel") + ": " + EnumChatFormatting.GOLD
- + GT_Utility.formatNumbers(fuelRemaining) + EnumChatFormatting.RESET + " L",
- StatCollector.translateToLocal("GT5U.engine.efficiency") + ": " + EnumChatFormatting.YELLOW
- + (mEfficiency / 100F) + EnumChatFormatting.YELLOW + " %",
- StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %"
- };
+ return new String[] { EnumChatFormatting.BLUE + "Diesel Engine" + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ getIdealStatus() == getRepairStatus()
+ ? EnumChatFormatting.GREEN + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
+ + EnumChatFormatting.RESET
+ : EnumChatFormatting.RED + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.engine.output") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers((mEUt * mEfficiency / 10000))
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.engine.consumption") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(fuelConsumption)
+ + EnumChatFormatting.RESET
+ + " L/t",
+ StatCollector.translateToLocal("GT5U.engine.value") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(fuelValue)
+ + EnumChatFormatting.RESET
+ + " EU/L",
+ StatCollector.translateToLocal("GT5U.turbine.fuel") + ": "
+ + EnumChatFormatting.GOLD
+ + GT_Utility.formatNumbers(fuelRemaining)
+ + EnumChatFormatting.RESET
+ + " L",
+ StatCollector.translateToLocal("GT5U.engine.efficiency") + ": "
+ + EnumChatFormatting.YELLOW
+ + (mEfficiency / 100F)
+ + EnumChatFormatting.YELLOW
+ + " %",
+ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %" };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DistillationTower.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DistillationTower.java
index 275c1c43a5..c6c98912e0 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DistillationTower.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DistillationTower.java
@@ -13,11 +13,19 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_DISTILLATION_
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofHatchAdder;
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.IAlignmentLimits;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Textures;
import gregtech.api.enums.Textures.BlockIcons;
@@ -31,15 +39,11 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.List;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_DistillationTower
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_DistillationTower>
implements ISurvivalConstructable {
+
protected static final int CASING_INDEX = 49;
protected static final String STRUCTURE_PIECE_BASE = "base";
protected static final String STRUCTURE_PIECE_LAYER = "layer";
@@ -48,42 +52,29 @@ public class GT_MetaTileEntity_DistillationTower
private static final IStructureDefinition<GT_MetaTileEntity_DistillationTower> STRUCTURE_DEFINITION;
static {
- IHatchElement<GT_MetaTileEntity_DistillationTower> layeredOutputHatch = OutputHatch.withCount(
- GT_MetaTileEntity_DistillationTower::getCurrentLayerOutputHatchCount)
+ IHatchElement<GT_MetaTileEntity_DistillationTower> layeredOutputHatch = OutputHatch
+ .withCount(GT_MetaTileEntity_DistillationTower::getCurrentLayerOutputHatchCount)
.withAdder(GT_MetaTileEntity_DistillationTower::addLayerOutputHatch);
STRUCTURE_DEFINITION = StructureDefinition.<GT_MetaTileEntity_DistillationTower>builder()
- .addShape(STRUCTURE_PIECE_BASE, transpose(new String[][] {
- {"b~b", "bbb", "bbb"},
- }))
- .addShape(STRUCTURE_PIECE_LAYER, transpose(new String[][] {
- {"lll", "lcl", "lll"},
- }))
- .addShape(STRUCTURE_PIECE_LAYER_HINT, transpose(new String[][] {
- {"lll", "l-l", "lll"},
- }))
- .addShape(STRUCTURE_PIECE_TOP_HINT, transpose(new String[][] {
- {"LLL", "LLL", "LLL"},
- }))
+ .addShape(STRUCTURE_PIECE_BASE, transpose(new String[][] { { "b~b", "bbb", "bbb" }, }))
+ .addShape(STRUCTURE_PIECE_LAYER, transpose(new String[][] { { "lll", "lcl", "lll" }, }))
+ .addShape(STRUCTURE_PIECE_LAYER_HINT, transpose(new String[][] { { "lll", "l-l", "lll" }, }))
+ .addShape(STRUCTURE_PIECE_TOP_HINT, transpose(new String[][] { { "LLL", "LLL", "LLL" }, }))
.addElement(
'b',
ofChain(
buildHatchAdder(GT_MetaTileEntity_DistillationTower.class)
.atLeast(Energy, OutputBus, InputHatch, InputBus, Maintenance)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .build(),
+ .casingIndex(CASING_INDEX).dot(1).build(),
onElementPass(
GT_MetaTileEntity_DistillationTower::onCasingFound,
ofBlock(GregTech_API.sBlockCasings4, 1))))
.addElement(
'l',
ofChain(
- buildHatchAdder(GT_MetaTileEntity_DistillationTower.class)
- .atLeast(layeredOutputHatch)
- .casingIndex(CASING_INDEX)
- .dot(2)
- .disallowOnly(ForgeDirection.UP, ForgeDirection.DOWN)
- .build(),
+ buildHatchAdder(GT_MetaTileEntity_DistillationTower.class).atLeast(layeredOutputHatch)
+ .casingIndex(CASING_INDEX).dot(2)
+ .disallowOnly(ForgeDirection.UP, ForgeDirection.DOWN).build(),
ofHatchAdder(
GT_MetaTileEntity_DistillationTower::addEnergyInputToMachineList,
CASING_INDEX,
@@ -99,11 +90,8 @@ public class GT_MetaTileEntity_DistillationTower
// hint element only used in top layer
.addElement(
'L',
- buildHatchAdder(GT_MetaTileEntity_DistillationTower.class)
- .atLeast(layeredOutputHatch)
- .casingIndex(CASING_INDEX)
- .dot(2)
- .disallowOnly(ForgeDirection.UP)
+ buildHatchAdder(GT_MetaTileEntity_DistillationTower.class).atLeast(layeredOutputHatch)
+ .casingIndex(CASING_INDEX).dot(2).disallowOnly(ForgeDirection.UP)
.buildAndChain(GregTech_API.sBlockCasings4, 1))
.addElement(
'c',
@@ -146,59 +134,32 @@ public class GT_MetaTileEntity_DistillationTower
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Distillery")
- .addInfo("Controller block for the Distillation Tower")
+ tt.addMachineType("Distillery").addInfo("Controller block for the Distillation Tower")
.addInfo("Fluids are only put out at the correct height")
- .addInfo("The correct height equals the slot number in the NEI recipe")
- .addSeparator()
- .beginVariableStructureBlock(3, 3, 3, 12, 3, 3, true)
- .addController("Front bottom")
+ .addInfo("The correct height equals the slot number in the NEI recipe").addSeparator()
+ .beginVariableStructureBlock(3, 3, 3, 12, 3, 3, true).addController("Front bottom")
.addOtherStructurePart("Clean Stainless Steel Machine Casing", "7 x h - 5 (minimum)")
- .addEnergyHatch("Any casing", 1, 2)
- .addMaintenanceHatch("Any casing", 1, 2, 3)
- .addInputHatch("Any bottom layer casing", 1)
- .addOutputBus("Any bottom layer casing", 1)
+ .addEnergyHatch("Any casing", 1, 2).addMaintenanceHatch("Any casing", 1, 2, 3)
+ .addInputHatch("Any bottom layer casing", 1).addOutputBus("Any bottom layer casing", 1)
.addOutputHatch("2-11x Output Hatches (At least one per layer except bottom layer)", 2, 3)
.toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- BlockIcons.getCasingTextureForId(CASING_INDEX),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DISTILLATION_TOWER_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DISTILLATION_TOWER_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- BlockIcons.getCasingTextureForId(CASING_INDEX),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DISTILLATION_TOWER)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_DISTILLATION_TOWER_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { BlockIcons.getCasingTextureForId(CASING_INDEX),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DISTILLATION_TOWER_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DISTILLATION_TOWER_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { BlockIcons.getCasingTextureForId(CASING_INDEX),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DISTILLATION_TOWER).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_DISTILLATION_TOWER_GLOW).extFacing().glow()
+ .build() };
}
- return new ITexture[] {Textures.BlockIcons.getCasingTextureForId(CASING_INDEX)};
+ return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX) };
}
@Override
@@ -256,7 +217,7 @@ public class GT_MetaTileEntity_DistillationTower
getBaseMetaTileEntity(),
false,
gregtech.api.enums.GT_Values.V[tTier],
- new FluidStack[] {tFluid},
+ new FluidStack[] { tFluid },
inputs);
if (tRecipe != null) {
if (tRecipe.isRecipeInputEqual(true, tFluids, inputs)) {
@@ -269,7 +230,7 @@ public class GT_MetaTileEntity_DistillationTower
this.mEUt = (-this.mEUt);
}
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
- this.mOutputItems = new ItemStack[] {tRecipe.getOutput(0)};
+ this.mOutputItems = new ItemStack[] { tRecipe.getOutput(0) };
this.mOutputFluids = tRecipe.mFluidOutputs.clone();
updateSlots();
return true;
@@ -291,15 +252,14 @@ public class GT_MetaTileEntity_DistillationTower
}
protected int getCurrentLayerOutputHatchCount() {
- return mOutputHatchesByLayer.size() < mHeight || mHeight <= 0
- ? 0
+ return mOutputHatchesByLayer.size() < mHeight || mHeight <= 0 ? 0
: mOutputHatchesByLayer.get(mHeight - 1).size();
}
protected boolean addLayerOutputHatch(IGregTechTileEntity aTileEntity, int aBaseCasingIndex) {
- if (aTileEntity == null
- || aTileEntity.isDead()
- || !(aTileEntity.getMetaTileEntity() instanceof GT_MetaTileEntity_Hatch_Output)) return false;
+ if (aTileEntity == null || aTileEntity.isDead()
+ || !(aTileEntity.getMetaTileEntity() instanceof GT_MetaTileEntity_Hatch_Output))
+ return false;
while (mOutputHatchesByLayer.size() < mHeight) mOutputHatchesByLayer.add(new ArrayList<>());
GT_MetaTileEntity_Hatch_Output tHatch = (GT_MetaTileEntity_Hatch_Output) aTileEntity.getMetaTileEntity();
tHatch.updateTexture(aBaseCasingIndex);
@@ -333,8 +293,7 @@ public class GT_MetaTileEntity_DistillationTower
if (!checkPiece(STRUCTURE_PIECE_LAYER, 1, mHeight, 0)) {
return false;
}
- if (mOutputHatchesByLayer.size() < mHeight
- || mOutputHatchesByLayer.get(mHeight - 1).isEmpty())
+ if (mOutputHatchesByLayer.size() < mHeight || mOutputHatchesByLayer.get(mHeight - 1).isEmpty())
// layer without output hatch
return false;
if (mTopLayerFound) {
@@ -394,11 +353,27 @@ public class GT_MetaTileEntity_DistillationTower
for (int i = 1; i < tTotalHeight - 1; i++) {
mHeight = i;
built = survivialBuildPiece(
- STRUCTURE_PIECE_LAYER_HINT, stackSize, 1, i, 0, elementBudget, env, false, true);
+ STRUCTURE_PIECE_LAYER_HINT,
+ stackSize,
+ 1,
+ i,
+ 0,
+ elementBudget,
+ env,
+ false,
+ true);
if (built >= 0) return built;
}
mHeight = tTotalHeight - 1;
return survivialBuildPiece(
- STRUCTURE_PIECE_TOP_HINT, stackSize, 1, tTotalHeight - 1, 0, elementBudget, env, false, true);
+ STRUCTURE_PIECE_TOP_HINT,
+ stackSize,
+ 1,
+ tTotalHeight - 1,
+ 0,
+ elementBudget,
+ env,
+ false,
+ true);
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DrillerBase.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DrillerBase.java
index ba5c28b3a4..55ccfd6230 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DrillerBase.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_DrillerBase.java
@@ -13,12 +13,27 @@ import static gregtech.api.enums.Textures.BlockIcons.getCasingTextureForId;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofFrame;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.world.ChunkCoordIntPair;
+import net.minecraftforge.common.util.FakePlayer;
+import net.minecraftforge.common.util.ForgeDirection;
+
import com.google.common.collect.ImmutableList;
import com.gtnewhorizon.structurelib.alignment.IAlignmentLimits;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Materials;
@@ -33,58 +48,46 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.IGT_HatchAdder;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.world.ChunkCoordIntPair;
-import net.minecraftforge.common.util.FakePlayer;
-import net.minecraftforge.common.util.ForgeDirection;
public abstract class GT_MetaTileEntity_DrillerBase
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_DrillerBase>
implements IChunkLoader, ISurvivalConstructable {
+
private static final ItemStack miningPipe = GT_ModHandler.getIC2Item("miningPipe", 0);
private static final ItemStack miningPipeTip = GT_ModHandler.getIC2Item("miningPipeTip", 0);
private static final Block miningPipeBlock = GT_Utility.getBlockFromStack(miningPipe);
private static final Block miningPipeTipBlock = GT_Utility.getBlockFromStack(miningPipeTip);
protected static final String STRUCTURE_PIECE_MAIN = "main";
- protected static final ClassValue<IStructureDefinition<GT_MetaTileEntity_DrillerBase>> STRUCTURE_DEFINITION =
- new ClassValue<IStructureDefinition<GT_MetaTileEntity_DrillerBase>>() {
- @Override
- protected IStructureDefinition<GT_MetaTileEntity_DrillerBase> computeValue(Class<?> type) {
- return StructureDefinition.<GT_MetaTileEntity_DrillerBase>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {" ", " f ", " "},
- {" ", " f ", " "},
- {" ", " f ", " "},
- {" f ", "fcf", " f "},
- {" f ", "fcf", " f "},
- {" f ", "fcf", " f "},
- {"b~b", "bbb", "bbb"},
- }))
- .addElement('f', lazy(t -> ofFrame(t.getFrameMaterial())))
- .addElement(
- 'c',
- lazy(t -> ofBlock(
- t.getCasingBlockItem().getBlock(),
- t.getCasingBlockItem().get(0).getItemDamage())))
- .addElement('b', lazy(t -> buildHatchAdder(GT_MetaTileEntity_DrillerBase.class)
- .atLeastList(t.getAllowedHatches())
- .adder(GT_MetaTileEntity_DrillerBase::addToMachineList)
- .casingIndex(t.casingTextureIndex)
- .dot(1)
- .buildAndChain(
+ protected static final ClassValue<IStructureDefinition<GT_MetaTileEntity_DrillerBase>> STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_DrillerBase>>() {
+
+ @Override
+ protected IStructureDefinition<GT_MetaTileEntity_DrillerBase> computeValue(Class<?> type) {
+ return StructureDefinition.<GT_MetaTileEntity_DrillerBase>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { " ", " f ", " " }, { " ", " f ", " " },
+ { " ", " f ", " " }, { " f ", "fcf", " f " }, { " f ", "fcf", " f " },
+ { " f ", "fcf", " f " }, { "b~b", "bbb", "bbb" }, }))
+ .addElement('f', lazy(t -> ofFrame(t.getFrameMaterial())))
+ .addElement(
+ 'c',
+ lazy(
+ t -> ofBlock(
t.getCasingBlockItem().getBlock(),
t.getCasingBlockItem().get(0).getItemDamage())))
- .build();
- }
- };
+ .addElement(
+ 'b',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_DrillerBase.class)
+ .atLeastList(t.getAllowedHatches())
+ .adder(GT_MetaTileEntity_DrillerBase::addToMachineList)
+ .casingIndex(t.casingTextureIndex).dot(1).buildAndChain(
+ t.getCasingBlockItem().getBlock(),
+ t.getCasingBlockItem().get(0).getItemDamage())))
+ .build();
+ }
+ };
private Block casingBlock;
private int casingMeta;
@@ -133,41 +136,17 @@ public abstract class GT_MetaTileEntity_DrillerBase
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- getCasingTextureForId(casingTextureIndex),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ORE_DRILL_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ORE_DRILL_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- getCasingTextureForId(casingTextureIndex),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ORE_DRILL)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ORE_DRILL_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { getCasingTextureForId(casingTextureIndex),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ORE_DRILL_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ORE_DRILL_ACTIVE_GLOW).extFacing().glow().build() };
+ return new ITexture[] { getCasingTextureForId(casingTextureIndex),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ORE_DRILL).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ORE_DRILL_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {getCasingTextureForId(casingTextureIndex)};
+ return new ITexture[] { getCasingTextureForId(casingTextureIndex) };
}
@Override
@@ -190,20 +169,20 @@ public abstract class GT_MetaTileEntity_DrillerBase
workState = aNBT.getBoolean("isPickingPipes") ? STATE_UPWARD : STATE_DOWNWARD;
if (aNBT.hasKey("chunkLoadingEnabled")) mChunkLoadingEnabled = aNBT.getBoolean("chunkLoadingEnabled");
if (aNBT.getBoolean("isChunkloading")) {
- mCurrentChunk =
- new ChunkCoordIntPair(aNBT.getInteger("loadedChunkXPos"), aNBT.getInteger("loadedChunkZPos"));
+ mCurrentChunk = new ChunkCoordIntPair(
+ aNBT.getInteger("loadedChunkXPos"),
+ aNBT.getInteger("loadedChunkZPos"));
}
}
@Override
- public boolean onSolderingToolRightClick(
- byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public boolean onSolderingToolRightClick(byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY,
+ float aZ) {
if (aSide == getBaseMetaTileEntity().getFrontFacing()) {
mChunkLoadingEnabled = !mChunkLoadingEnabled;
GT_Utility.sendChatToPlayer(
aPlayer,
- mChunkLoadingEnabled
- ? GT_Utility.trans("502", "Mining chunk loading enabled")
+ mChunkLoadingEnabled ? GT_Utility.trans("502", "Mining chunk loading enabled")
: GT_Utility.trans("503", "Mining chunk loading disabled"));
return true;
}
@@ -219,8 +198,7 @@ public abstract class GT_MetaTileEntity_DrillerBase
@Override
public void onPostTick(IGregTechTileEntity aBaseMetaTileEntity, long aTick) {
super.onPostTick(aBaseMetaTileEntity, aTick);
- if (aBaseMetaTileEntity.isServerSide()
- && mCurrentChunk != null
+ if (aBaseMetaTileEntity.isServerSide() && mCurrentChunk != null
&& !mWorkChunkNeedsReload
&& !aBaseMetaTileEntity.isAllowedToWork()) {
// if machine has stopped, stop chunkloading
@@ -242,6 +220,7 @@ public abstract class GT_MetaTileEntity_DrillerBase
/**
* Added for compability reasons
+ *
* @return true if the state is 0 false otherwise.
* @deprecated compatibility reason
*/
@@ -270,19 +249,18 @@ public abstract class GT_MetaTileEntity_DrillerBase
}
Block b = getBaseMetaTileEntity().getBlock(xPipe, yHead - 1, zPipe);
- if (b != miningPipeTipBlock
- && !GT_Utility.setBlockByFakePlayer(
- getFakePlayer(getBaseMetaTileEntity()),
- xPipe,
- yHead - 1,
- zPipe,
- miningPipeTipBlock,
- 0,
- isSimulating)) return 3;
+ if (b != miningPipeTipBlock && !GT_Utility.setBlockByFakePlayer(
+ getFakePlayer(getBaseMetaTileEntity()),
+ xPipe,
+ yHead - 1,
+ zPipe,
+ miningPipeTipBlock,
+ 0,
+ isSimulating))
+ return 3;
if (!isSimulating) {
if (yHead != yDrill) getBaseMetaTileEntity().getWorld().setBlock(xPipe, yHead, zPipe, miningPipeBlock);
- if (b != miningPipeBlock && b != miningPipeTipBlock)
- getBaseMetaTileEntity().decrStackSize(1, 1);
+ if (b != miningPipeBlock && b != miningPipeTipBlock) getBaseMetaTileEntity().decrStackSize(1, 1);
}
return 0;
@@ -315,7 +293,7 @@ public abstract class GT_MetaTileEntity_DrillerBase
private boolean tryOutputPipe() {
if (!getBaseMetaTileEntity().addStackToSlot(1, GT_Utility.copyAmount(1, miningPipe)))
- mOutputItems = new ItemStack[] {GT_Utility.copyAmount(1, miningPipe)};
+ mOutputItems = new ItemStack[] { GT_Utility.copyAmount(1, miningPipe) };
return true;
}
@@ -361,8 +339,8 @@ public abstract class GT_MetaTileEntity_DrillerBase
return false;
}
- protected boolean workingDownward(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingDownward(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
switch (tryLowerPipeState()) {
case 2:
mMaxProgresstime = 0;
@@ -378,8 +356,8 @@ public abstract class GT_MetaTileEntity_DrillerBase
}
}
- protected boolean workingAtBottom(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingAtBottom(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
switch (tryLowerPipeState(true)) {
case 0:
workState = STATE_DOWNWARD;
@@ -390,8 +368,8 @@ public abstract class GT_MetaTileEntity_DrillerBase
}
}
- protected boolean workingUpward(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingUpward(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
if (tryPickPipe()) {
return true;
} else {
@@ -436,8 +414,7 @@ public abstract class GT_MetaTileEntity_DrillerBase
@Override
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
updateCoordinates();
- return checkPiece(STRUCTURE_PIECE_MAIN, 1, 6, 0)
- && checkHatches()
+ return checkPiece(STRUCTURE_PIECE_MAIN, 1, 6, 0) && checkHatches()
&& GT_Utility.getTier(getMaxInputVoltage()) >= getMinTier()
&& mMaintenanceHatches.size() == 1;
}
@@ -465,6 +442,7 @@ public abstract class GT_MetaTileEntity_DrillerBase
protected boolean checkCasingBlock(int xOff, int yOff, int zOff) {
return checkBlockAndMetaOffset(xOff, yOff, zOff, casingBlock, casingMeta);
}
+
// meta of frame is getTileEntityBaseType; frame should be checked using its drops (possible a high weight
// operation)
@Deprecated
@@ -612,6 +590,7 @@ public abstract class GT_MetaTileEntity_DrillerBase
}
protected enum DataHatchElement implements IHatchElement<GT_MetaTileEntity_DrillerBase> {
+
DataAccess;
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ElectricBlastFurnace.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ElectricBlastFurnace.java
index 15f04c5fda..37a9b924e8 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ElectricBlastFurnace.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ElectricBlastFurnace.java
@@ -8,10 +8,20 @@ import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofCoil;
+import java.util.ArrayList;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.HeatingCoilLevel;
@@ -24,59 +34,44 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_ElectricBlastFurnace
extends GT_MetaTileEntity_AbstractMultiFurnace<GT_MetaTileEntity_ElectricBlastFurnace>
implements ISurvivalConstructable {
+
private int mHeatingCapacity = 0;
private boolean isBussesSeparate = false;
protected final ArrayList<GT_MetaTileEntity_Hatch_Output> mPollutionOutputHatches = new ArrayList<>();
- protected final FluidStack[] pollutionFluidStacks = {
- Materials.CarbonDioxide.getGas(1000),
- Materials.CarbonMonoxide.getGas(1000),
- Materials.SulfurDioxide.getGas(1000)
- };
+ protected final FluidStack[] pollutionFluidStacks = { Materials.CarbonDioxide.getGas(1000),
+ Materials.CarbonMonoxide.getGas(1000), Materials.SulfurDioxide.getGas(1000) };
protected static final int CASING_INDEX = 11;
protected static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_ElectricBlastFurnace> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_ElectricBlastFurnace>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {"ttt", "tmt", "ttt"},
- {"CCC", "C-C", "CCC"},
- {"CCC", "C-C", "CCC"},
- {"b~b", "bbb", "bbb"}
- }))
- .addElement(
- 't',
- buildHatchAdder(GT_MetaTileEntity_ElectricBlastFurnace.class)
- .atLeast(OutputHatch.withAdder(
- GT_MetaTileEntity_ElectricBlastFurnace::addOutputHatchToTopList)
- .withCount(t -> t.mPollutionOutputHatches.size()))
- .casingIndex(CASING_INDEX)
- .dot(1)
- .buildAndChain(GregTech_API.sBlockCasings1, CASING_INDEX))
- .addElement('m', Muffler.newAny(CASING_INDEX, 2))
- .addElement(
- 'C',
- ofCoil(
- GT_MetaTileEntity_ElectricBlastFurnace::setCoilLevel,
- GT_MetaTileEntity_ElectricBlastFurnace::getCoilLevel))
- .addElement(
- 'b',
- buildHatchAdder(GT_MetaTileEntity_ElectricBlastFurnace.class)
- .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Maintenance, Energy)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .buildAndChain(GregTech_API.sBlockCasings1, CASING_INDEX))
- .build();
+ private static final IStructureDefinition<GT_MetaTileEntity_ElectricBlastFurnace> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_ElectricBlastFurnace>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "ttt", "tmt", "ttt" }, { "CCC", "C-C", "CCC" }, { "CCC", "C-C", "CCC" },
+ { "b~b", "bbb", "bbb" } }))
+ .addElement(
+ 't',
+ buildHatchAdder(GT_MetaTileEntity_ElectricBlastFurnace.class).atLeast(
+ OutputHatch.withAdder(GT_MetaTileEntity_ElectricBlastFurnace::addOutputHatchToTopList)
+ .withCount(t -> t.mPollutionOutputHatches.size()))
+ .casingIndex(CASING_INDEX).dot(1).buildAndChain(GregTech_API.sBlockCasings1, CASING_INDEX))
+ .addElement('m', Muffler.newAny(CASING_INDEX, 2))
+ .addElement(
+ 'C',
+ ofCoil(
+ GT_MetaTileEntity_ElectricBlastFurnace::setCoilLevel,
+ GT_MetaTileEntity_ElectricBlastFurnace::getCoilLevel))
+ .addElement(
+ 'b',
+ buildHatchAdder(GT_MetaTileEntity_ElectricBlastFurnace.class)
+ .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Maintenance, Energy)
+ .casingIndex(CASING_INDEX).dot(1).buildAndChain(GregTech_API.sBlockCasings1, CASING_INDEX))
+ .build();
public GT_MetaTileEntity_ElectricBlastFurnace(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
@@ -94,69 +89,39 @@ public class GT_MetaTileEntity_ElectricBlastFurnace
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Blast Furnace")
- .addInfo("Controller block for the Electric Blast Furnace")
+ tt.addMachineType("Blast Furnace").addInfo("Controller block for the Electric Blast Furnace")
.addInfo("You can use some fluids to reduce recipe time. Place the circuit in the Input Bus")
.addInfo("Each 900K over the min. Heat required reduces power consumption by 5% (multiplicatively)")
.addInfo("Each 1800K over the min. Heat required grants one perfect overclock")
.addInfo(
"For each perfect overclock the EBF will reduce recipe time 4 times (instead of 2) (100% efficiency)")
.addInfo("Additionally gives +100K for every tier past MV")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 4, 3, true)
- .addController("Front bottom")
- .addCasingInfo("Heat Proof Machine Casing", 0)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 4, 3, true)
+ .addController("Front bottom").addCasingInfo("Heat Proof Machine Casing", 0)
.addOtherStructurePart("Heating Coils", "Two middle Layers")
- .addEnergyHatch("Any bottom layer casing", 3)
- .addMaintenanceHatch("Any bottom layer casing", 3)
- .addMufflerHatch("Top middle", 2)
- .addInputBus("Any bottom layer casing", 3)
- .addInputHatch("Any bottom layer casing", 3)
- .addOutputBus("Any bottom layer casing", 3)
+ .addEnergyHatch("Any bottom layer casing", 3).addMaintenanceHatch("Any bottom layer casing", 3)
+ .addMufflerHatch("Top middle", 2).addInputBus("Any bottom layer casing", 3)
+ .addInputHatch("Any bottom layer casing", 3).addOutputBus("Any bottom layer casing", 3)
.addOutputHatch("Liquid form of fluids, Any bottom layer casing")
.addOutputHatch("Gas form of fluids, Any top layer casing", 1)
- .addStructureInfo("Recovery amount scales with Muffler Hatch tier")
- .toolTipFinisher("Gregtech");
+ .addStructureInfo("Recovery amount scales with Muffler Hatch tier").toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE_GLOW).extFacing()
+ .glow().build() };
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_GLOW).extFacing().glow()
+ .build() };
}
- return new ITexture[] {casingTexturePages[0][CASING_INDEX]};
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX] };
}
@Override
@@ -211,8 +176,8 @@ public class GT_MetaTileEntity_ElectricBlastFurnace
long tVoltage = getMaxInputVoltage();
byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sBlastRecipes.findRecipe(
- getBaseMetaTileEntity(), false, V[tTier], tFluids, tItems);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sBlastRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, V[tTier], tFluids, tItems);
if (tRecipe == null) return false;
if (this.mHeatingCapacity < tRecipe.mSpecialValue) return false;
@@ -230,16 +195,17 @@ public class GT_MetaTileEntity_ElectricBlastFurnace
}
if (tHeatCapacityDivTiers > 0) {
this.mEUt = (int) (this.mEUt * (Math.pow(0.95, tHeatCapacityDivTiers)));
- this.mMaxProgresstime >>=
- Math.min(tHeatCapacityDivTiers / 2, overclockCount); // extra free overclocking if possible
+ this.mMaxProgresstime >>= Math.min(tHeatCapacityDivTiers / 2, overclockCount); // extra free overclocking if
+ // possible
if (this.mMaxProgresstime < 1) this.mMaxProgresstime = 1; // no eu efficiency correction
}
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
- this.mOutputItems = new ItemStack[] {tRecipe.getOutput(0), tRecipe.getOutput(1)};
- this.mOutputFluids = new FluidStack[] {tRecipe.getFluidOutput(0)};
+ this.mOutputItems = new ItemStack[] { tRecipe.getOutput(0), tRecipe.getOutput(1) };
+ this.mOutputFluids = new FluidStack[] { tRecipe.getFluidOutput(0) };
updateSlots();
return true;
}
+
/**
* Calcualtes overclocked ness using long integers
*
@@ -272,9 +238,8 @@ public class GT_MetaTileEntity_ElectricBlastFurnace
tempEUt <<= 2; // this actually controls overclocking
// xEUt *= 4;//this is effect of everclocking
mMaxProgresstime >>= 1; // this is effect of overclocking
- xEUt = mMaxProgresstime == 0
- ? xEUt >> 1
- : xEUt << 2; // U know, if the time is less than 1 tick make the machine use less power
+ xEUt = mMaxProgresstime == 0 ? xEUt >> 1 : xEUt << 2; // U know, if the time is less than 1 tick make
+ // the machine use less power
timesOverclocked++;
}
if (xEUt > Integer.MAX_VALUE - 1) {
@@ -362,31 +327,60 @@ public class GT_MetaTileEntity_ElectricBlastFurnace
}
return new String[] {
- StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mProgresstime / 20) + EnumChatFormatting.RESET + " s / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(mMaxProgresstime / 20) + EnumChatFormatting.RESET + " s",
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.multiblock.usage") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(-mEUt) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.multiblock.mei") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(getMaxInputVoltage()) + EnumChatFormatting.RESET + " EU/t(*2A) "
- + StatCollector.translateToLocal("GT5U.machines.tier")
- + ": " + EnumChatFormatting.YELLOW
- + VN[GT_Utility.getTier(getMaxInputVoltage())] + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.multiblock.problems") + ": " + EnumChatFormatting.RED
- + (getIdealStatus() - getRepairStatus()) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
- + ": " + EnumChatFormatting.YELLOW
- + mEfficiency / 100.0F + EnumChatFormatting.RESET + " %",
- StatCollector.translateToLocal("GT5U.EBF.heat") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mHeatingCapacity) + EnumChatFormatting.RESET + " K",
- StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %"
- };
+ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(mMaxProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s",
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.multiblock.usage") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(-mEUt)
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.multiblock.mei") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getMaxInputVoltage())
+ + EnumChatFormatting.RESET
+ + " EU/t(*2A) "
+ + StatCollector.translateToLocal("GT5U.machines.tier")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + VN[GT_Utility.getTier(getMaxInputVoltage())]
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.multiblock.problems") + ": "
+ + EnumChatFormatting.RED
+ + (getIdealStatus() - getRepairStatus())
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + mEfficiency / 100.0F
+ + EnumChatFormatting.RESET
+ + " %",
+ StatCollector.translateToLocal("GT5U.EBF.heat") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mHeatingCapacity)
+ + EnumChatFormatting.RESET
+ + " K",
+ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %" };
}
@Override
@@ -404,7 +398,8 @@ public class GT_MetaTileEntity_ElectricBlastFurnace
public void onScrewdriverRightClick(byte aSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
isBussesSeparate = !isBussesSeparate;
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + isBussesSeparate);
+ aPlayer,
+ StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + isBussesSeparate);
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ExtremeDieselEngine.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ExtremeDieselEngine.java
index 407e661c57..66951a889d 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ExtremeDieselEngine.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ExtremeDieselEngine.java
@@ -6,6 +6,11 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_EXTREME_DIESE
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.casingTexturePages;
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
@@ -18,10 +23,6 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
public class GT_MetaTileEntity_ExtremeDieselEngine extends GT_MetaTileEntity_DieselEngine {
@@ -36,28 +37,21 @@ public class GT_MetaTileEntity_ExtremeDieselEngine extends GT_MetaTileEntity_Die
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Combustion Generator")
- .addInfo("Controller block for the Extreme Combustion Engine")
+ tt.addMachineType("Combustion Generator").addInfo("Controller block for the Extreme Combustion Engine")
.addInfo("Supply high rating fuel and 8000L of Lubricant per hour to run")
.addInfo("Supply 40L/s of Liquid Oxygen to boost output (optional)")
.addInfo("Default: Produces 10900EU/t at 100% fuel efficiency")
.addInfo("Boosted: Produces 32700EU/t at 150% fuel efficiency")
.addInfo("You need to wait for it to reach 300% to output full power")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 3, 4, false)
- .addController("Front center")
- .addCasingInfo("Robust Tungstensteel Machine Casing", 16)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 3, 4, false)
+ .addController("Front center").addCasingInfo("Robust Tungstensteel Machine Casing", 16)
.addOtherStructurePart("Titanium Gear Box Machine Casing", "Inner 2 blocks")
.addOtherStructurePart("Extreme Engine Intake Machine Casing", "8x, ring around controller")
.addStructureInfo("Extreme Engine Intake Casings must not be obstructed in front (only air blocks)")
- .addDynamoHatch("Back center", 2)
- .addMaintenanceHatch("One of the casings next to a Gear Box", 1)
+ .addDynamoHatch("Back center", 2).addMaintenanceHatch("One of the casings next to a Gear Box", 1)
.addMufflerHatch("Top middle back, above the rear Gear Box", 1)
- .addInputHatch("HOG, next to a Gear Box", 1)
- .addInputHatch("Lubricant, next to a Gear Box", 1)
- .addInputHatch("Liquid Oxygen, optional, next to a Gear Box", 1)
- .toolTipFinisher("Gregtech");
+ .addInputHatch("HOG, next to a Gear Box", 1).addInputHatch("Lubricant, next to a Gear Box", 1)
+ .addInputHatch("Liquid Oxygen, optional, next to a Gear Box", 1).toolTipFinisher("Gregtech");
return tt;
}
@@ -67,41 +61,19 @@ public class GT_MetaTileEntity_ExtremeDieselEngine extends GT_MetaTileEntity_Die
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][60],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][60],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[0][60],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { casingTexturePages[0][60],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_EXTREME_DIESEL_ENGINE_GLOW).extFacing().glow()
+ .build() };
}
- return new ITexture[] {casingTexturePages[0][60]};
+ return new ITexture[] { casingTexturePages[0][60] };
}
@Override
@@ -197,31 +169,50 @@ public class GT_MetaTileEntity_ExtremeDieselEngine extends GT_MetaTileEntity_Die
}
}
- return new String[] {
- EnumChatFormatting.BLUE + "Extreme Diesel Engine" + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- getIdealStatus() == getRepairStatus()
- ? EnumChatFormatting.GREEN
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
- + EnumChatFormatting.RESET
- : EnumChatFormatting.RED
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.engine.output") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(-mEUt * mEfficiency / 10000) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.engine.consumption") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(fuelConsumption) + EnumChatFormatting.RESET + " L/t",
- StatCollector.translateToLocal("GT5U.engine.value") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(fuelValue) + EnumChatFormatting.RESET + " EU/L",
- StatCollector.translateToLocal("GT5U.turbine.fuel") + ": " + EnumChatFormatting.GOLD
- + GT_Utility.formatNumbers(fuelRemaining) + EnumChatFormatting.RESET + " L",
- StatCollector.translateToLocal("GT5U.engine.efficiency") + ": " + EnumChatFormatting.YELLOW
- + (mEfficiency / 100F) + EnumChatFormatting.YELLOW + " %",
- StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %"
- };
+ return new String[] { EnumChatFormatting.BLUE + "Extreme Diesel Engine" + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ getIdealStatus() == getRepairStatus()
+ ? EnumChatFormatting.GREEN + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
+ + EnumChatFormatting.RESET
+ : EnumChatFormatting.RED + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.engine.output") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(-mEUt * mEfficiency / 10000)
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.engine.consumption") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(fuelConsumption)
+ + EnumChatFormatting.RESET
+ + " L/t",
+ StatCollector.translateToLocal("GT5U.engine.value") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(fuelValue)
+ + EnumChatFormatting.RESET
+ + " EU/L",
+ StatCollector.translateToLocal("GT5U.turbine.fuel") + ": "
+ + EnumChatFormatting.GOLD
+ + GT_Utility.formatNumbers(fuelRemaining)
+ + EnumChatFormatting.RESET
+ + " L",
+ StatCollector.translateToLocal("GT5U.engine.efficiency") + ": "
+ + EnumChatFormatting.YELLOW
+ + (mEfficiency / 100F)
+ + EnumChatFormatting.YELLOW
+ + " %",
+ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %" };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer.java
index adfefee6c1..1f2b4f8222 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer.java
@@ -12,6 +12,15 @@ import static gregtech.api.enums.Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.filterByMTETier;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidStack;
+
import com.google.common.collect.ImmutableMap;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
@@ -25,6 +34,7 @@ import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.FakeSyncWidget;
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.GT_Mod;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.Textures;
@@ -41,101 +51,65 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidStack;
public abstract class GT_MetaTileEntity_FusionComputer
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_FusionComputer>
implements ISurvivalConstructable, IAddUIWidgets {
+
public static final String STRUCTURE_PIECE_MAIN = "main";
- private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_FusionComputer>> STRUCTURE_DEFINITION =
- new ClassValue<IStructureDefinition<GT_MetaTileEntity_FusionComputer>>() {
- @Override
- protected IStructureDefinition<GT_MetaTileEntity_FusionComputer> computeValue(Class<?> type) {
- return StructureDefinition.<GT_MetaTileEntity_FusionComputer>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {
- " ",
- " ihi ",
- " hh hh ",
- " h h ",
- " h h ",
- " h h ",
- " i i ",
- " h h ",
- " i i ",
- " h h ",
- " h h ",
- " h h ",
- " hh hh ",
- " ihi ",
- " ",
- },
- {
- " xhx ",
- " hhccchh ",
- " eccxhxcce ",
- " eceh hece ",
- " hce ech ",
- " hch hch ",
- "xcx xcx",
- "hch hch",
- "xcx xcx",
- " hch hch ",
- " hce ech ",
- " eceh hece ",
- " eccx~xcce ",
- " hhccchh ",
- " xhx ",
- },
- {
- " ",
- " ihi ",
- " hh hh ",
- " h h ",
- " h h ",
- " h h ",
- " i i ",
- " h h ",
- " i i ",
- " h h ",
- " h h ",
- " h h ",
- " hh hh ",
- " ihi ",
- " ",
- }
- }))
- .addElement('c', lazy(t -> ofBlock(t.getFusionCoil(), t.getFusionCoilMeta())))
- .addElement('h', lazy(t -> ofBlock(t.getCasing(), t.getCasingMeta())))
- .addElement('i', lazy(t -> buildHatchAdder(GT_MetaTileEntity_FusionComputer.class)
- .atLeast(ImmutableMap.of(
- InputHatch.withAdder(GT_MetaTileEntity_FusionComputer::addInjector), 2))
- .hatchItemFilterAnd(t2 -> filterByMTETier(t2.tier(), Integer.MAX_VALUE))
- .casingIndex(53)
- .dot(1)
- .buildAndChain(t.getCasing(), t.getCasingMeta())))
- .addElement('e', lazy(t -> buildHatchAdder(GT_MetaTileEntity_FusionComputer.class)
- .atLeast(ImmutableMap.of(
- Energy.withAdder(GT_MetaTileEntity_FusionComputer::addEnergyInjector), 16))
- .hatchItemFilterAnd(t2 -> filterByMTETier(t2.tier(), Integer.MAX_VALUE))
- .casingIndex(53)
- .dot(2)
- .buildAndChain(t.getCasing(), t.getCasingMeta())))
- .addElement('x', lazy(t -> buildHatchAdder(GT_MetaTileEntity_FusionComputer.class)
- .atLeast(OutputHatch.withAdder(GT_MetaTileEntity_FusionComputer::addExtractor))
- .hatchItemFilterAnd(t2 -> filterByMTETier(t2.tier(), Integer.MAX_VALUE))
- .casingIndex(53)
- .dot(3)
- .buildAndChain(t.getCasing(), t.getCasingMeta())))
- .build();
- }
- };
+ private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_FusionComputer>> STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_FusionComputer>>() {
+
+ @Override
+ protected IStructureDefinition<GT_MetaTileEntity_FusionComputer> computeValue(Class<?> type) {
+ return StructureDefinition.<GT_MetaTileEntity_FusionComputer>builder().addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] {
+ { " ", " ihi ", " hh hh ", " h h ",
+ " h h ", " h h ", " i i ", " h h ",
+ " i i ", " h h ", " h h ", " h h ",
+ " hh hh ", " ihi ", " ", },
+ { " xhx ", " hhccchh ", " eccxhxcce ", " eceh hece ",
+ " hce ech ", " hch hch ", "xcx xcx", "hch hch",
+ "xcx xcx", " hch hch ", " hce ech ", " eceh hece ",
+ " eccx~xcce ", " hhccchh ", " xhx ", },
+ { " ", " ihi ", " hh hh ", " h h ",
+ " h h ", " h h ", " i i ", " h h ",
+ " i i ", " h h ", " h h ", " h h ",
+ " hh hh ", " ihi ", " ", } }))
+ .addElement('c', lazy(t -> ofBlock(t.getFusionCoil(), t.getFusionCoilMeta())))
+ .addElement('h', lazy(t -> ofBlock(t.getCasing(), t.getCasingMeta())))
+ .addElement(
+ 'i',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_FusionComputer.class)
+ .atLeast(
+ ImmutableMap.of(
+ InputHatch.withAdder(
+ GT_MetaTileEntity_FusionComputer::addInjector),
+ 2))
+ .hatchItemFilterAnd(t2 -> filterByMTETier(t2.tier(), Integer.MAX_VALUE))
+ .casingIndex(53).dot(1).buildAndChain(t.getCasing(), t.getCasingMeta())))
+ .addElement(
+ 'e',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_FusionComputer.class).atLeast(
+ ImmutableMap.of(
+ Energy.withAdder(
+ GT_MetaTileEntity_FusionComputer::addEnergyInjector),
+ 16))
+ .hatchItemFilterAnd(t2 -> filterByMTETier(t2.tier(), Integer.MAX_VALUE))
+ .casingIndex(53).dot(2).buildAndChain(t.getCasing(), t.getCasingMeta())))
+ .addElement(
+ 'x',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_FusionComputer.class).atLeast(
+ OutputHatch.withAdder(GT_MetaTileEntity_FusionComputer::addExtractor))
+ .hatchItemFilterAnd(t2 -> filterByMTETier(t2.tier(), Integer.MAX_VALUE))
+ .casingIndex(53).dot(3).buildAndChain(t.getCasing(), t.getCasingMeta())))
+ .build();
+ }
+ };
public GT_Recipe mLastRecipe;
public long mEUStore;
@@ -143,14 +117,8 @@ public abstract class GT_MetaTileEntity_FusionComputer
Textures.BlockIcons.setCasingTextureForId(
52,
TextureFactory.of(
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW)
- .extFacing()
- .glow()
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW).extFacing().build(),
+ TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS_YELLOW_GLOW).extFacing().glow()
.build()));
}
@@ -194,20 +162,16 @@ public abstract class GT_MetaTileEntity_FusionComputer
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addController("Fusion Reactor")
- .addInfo("Some kind of fusion reactor, maybe")
- .addSeparator()
+ tt.addController("Fusion Reactor").addInfo("Some kind of fusion reactor, maybe").addSeparator()
.addInfo("Some kind of fusion reactor, maybe")
.addStructureInfo("Should probably be built similar to other fusions")
- .addStructureInfo("See controller tooltip for details")
- .toolTipFinisher("Gregtech");
+ .addStructureInfo("See controller tooltip for details").toolTipFinisher("Gregtech");
return tt;
}
@Override
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
- if (checkPiece(STRUCTURE_PIECE_MAIN, 7, 1, 12)
- && mInputHatches.size() > 1
+ if (checkPiece(STRUCTURE_PIECE_MAIN, 7, 1, 12) && mInputHatches.size() > 1
&& !mOutputHatches.isEmpty()
&& !mEnergyHatches.isEmpty()) {
mWrench = true;
@@ -262,28 +226,13 @@ public abstract class GT_MetaTileEntity_FusionComputer
public abstract int getFusionCoilMeta();
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing)
- return new ITexture[] {
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS)
- .extFacing()
- .build(),
- getTextureOverlay()
- };
- if (aActive) return new ITexture[] {Textures.BlockIcons.getCasingTextureForId(52)};
- return new ITexture[] {
- TextureFactory.builder()
- .addIcon(MACHINE_CASING_FUSION_GLASS)
- .extFacing()
- .build()
- };
+ return new ITexture[] { TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS).extFacing().build(),
+ getTextureOverlay() };
+ if (aActive) return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(52) };
+ return new ITexture[] { TextureFactory.builder().addIcon(MACHINE_CASING_FUSION_GLASS).extFacing().build() };
}
/**
@@ -331,11 +280,15 @@ public abstract class GT_MetaTileEntity_FusionComputer
FluidStack[] tFluids = tFluidList.toArray(new FluidStack[0]);
GT_Recipe tRecipe;
- tRecipe = GT_Recipe.GT_Recipe_Map.sFusionRecipes.findRecipe(
- this.getBaseMetaTileEntity(), this.mLastRecipe, false, GT_Values.V[tier()], tFluids);
+ tRecipe = GT_Recipe.GT_Recipe_Map.sFusionRecipes
+ .findRecipe(this.getBaseMetaTileEntity(), this.mLastRecipe, false, GT_Values.V[tier()], tFluids);
if (tRecipe == null) {
tRecipe = GT_Recipe.GT_Recipe_Map.sComplexFusionRecipes.findRecipe(
- this.getBaseMetaTileEntity(), this.mLastRecipe, false, GT_Values.V[tier()], tFluids);
+ this.getBaseMetaTileEntity(),
+ this.mLastRecipe,
+ false,
+ GT_Values.V[tier()],
+ tFluids);
}
if ((tRecipe == null && !mRunningOnLoad) || (maxEUStore() < tRecipe.mSpecialValue)) {
@@ -400,9 +353,8 @@ public abstract class GT_MetaTileEntity_FusionComputer
for (GT_MetaTileEntity_Hatch_Energy tHatch : mEnergyHatches)
if (isValidMetaTileEntity(tHatch)) {
long energyToMove = GT_Values.V[tier()] / 16;
- if (aBaseMetaTileEntity.getStoredEU() + energyToMove < maxEUStore()
- && tHatch.getBaseMetaTileEntity()
- .decreaseStoredEnergyUnits(energyToMove, false)) {
+ if (aBaseMetaTileEntity.getStoredEU() + energyToMove < maxEUStore() && tHatch
+ .getBaseMetaTileEntity().decreaseStoredEnergyUnits(energyToMove, false)) {
aBaseMetaTileEntity.increaseStoredEnergyUnits(energyToMove, true);
}
}
@@ -418,7 +370,8 @@ public abstract class GT_MetaTileEntity_FusionComputer
if (mOutputFluids != null)
for (FluidStack tStack : mOutputFluids) if (tStack != null) addOutput(tStack);
mEfficiency = Math.max(
- 0, Math.min(mEfficiency + mEfficiencyIncrease, getMaxEfficiency(mInventory[1])));
+ 0,
+ Math.min(mEfficiency + mEfficiencyIncrease, getMaxEfficiency(mInventory[1])));
mOutputItems = null;
mProgresstime = 0;
mMaxProgresstime = 0;
@@ -426,19 +379,16 @@ public abstract class GT_MetaTileEntity_FusionComputer
if (mOutputFluids != null && mOutputFluids.length > 0) {
try {
GT_Mod.achievements.issueAchivementHatchFluid(
- aBaseMetaTileEntity
- .getWorld()
+ aBaseMetaTileEntity.getWorld()
.getPlayerEntityByName(aBaseMetaTileEntity.getOwnerName()),
mOutputFluids[0]);
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
this.mEUStore = aBaseMetaTileEntity.getStoredEU();
if (aBaseMetaTileEntity.isAllowedToWork()) checkRecipe();
}
} else {
- if (aTick % 100 == 0
- || aBaseMetaTileEntity.hasWorkJustBeenEnabled()
+ if (aTick % 100 == 0 || aBaseMetaTileEntity.hasWorkJustBeenEnabled()
|| aBaseMetaTileEntity.hasInventoryBeenModified()) {
turnCasingActive(mMaxProgresstime > 0);
if (aBaseMetaTileEntity.isAllowedToWork()) {
@@ -448,7 +398,8 @@ public abstract class GT_MetaTileEntity_FusionComputer
criticalStopMachine();
}
aBaseMetaTileEntity.decreaseStoredEnergyUnits(
- this.mLastRecipe.mSpecialValue - this.mEUt, true);
+ this.mLastRecipe.mSpecialValue - this.mEUt,
+ true);
}
}
if (mMaxProgresstime <= 0) mEfficiency = Math.max(0, mEfficiency - 1000);
@@ -459,8 +410,8 @@ public abstract class GT_MetaTileEntity_FusionComputer
stopMachine();
}
}
- aBaseMetaTileEntity.setErrorDisplayID(
- (aBaseMetaTileEntity.getErrorDisplayID() & ~127) | (mMachine ? 0 : 64));
+ aBaseMetaTileEntity
+ .setErrorDisplayID((aBaseMetaTileEntity.getErrorDisplayID() & ~127) | (mMachine ? 0 : 64));
aBaseMetaTileEntity.setActive(mMaxProgresstime > 0);
}
}
@@ -510,10 +461,8 @@ public abstract class GT_MetaTileEntity_FusionComputer
@Override
public String[] getInfoData() {
- String tier = tier() == 6
- ? EnumChatFormatting.RED + "I" + EnumChatFormatting.RESET
- : tier() == 7
- ? EnumChatFormatting.YELLOW + "II" + EnumChatFormatting.RESET
+ String tier = tier() == 6 ? EnumChatFormatting.RED + "I" + EnumChatFormatting.RESET
+ : tier() == 7 ? EnumChatFormatting.YELLOW + "II" + EnumChatFormatting.RESET
: tier() == 8 ? EnumChatFormatting.GRAY + "III" + EnumChatFormatting.RESET : "IV";
float plasmaOut = 0;
int powerRequired = 0;
@@ -524,17 +473,26 @@ public abstract class GT_MetaTileEntity_FusionComputer
}
}
- return new String[] {
- EnumChatFormatting.BLUE + "Fusion Reactor MK " + EnumChatFormatting.RESET + tier,
- StatCollector.translateToLocal("GT5U.fusion.req") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(powerRequired) + EnumChatFormatting.RESET + "EU/t",
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mEUStore) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEUStore()) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.fusion.plasma") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(plasmaOut) + EnumChatFormatting.RESET + "L/t"
- };
+ return new String[] { EnumChatFormatting.BLUE + "Fusion Reactor MK " + EnumChatFormatting.RESET + tier,
+ StatCollector.translateToLocal("GT5U.fusion.req") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(powerRequired)
+ + EnumChatFormatting.RESET
+ + "EU/t",
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mEUStore)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEUStore())
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.fusion.plasma") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(plasmaOut)
+ + EnumChatFormatting.RESET
+ + "L/t" };
}
@Override
@@ -560,10 +518,9 @@ public abstract class GT_MetaTileEntity_FusionComputer
@Override
public void addGregTechLogo(ModularWindow.Builder builder) {
- builder.widget(new DrawableWidget()
- .setDrawable(getGUITextureSet().getGregTechLogo())
- .setSize(17, 17)
- .setPos(155, 145));
+ builder.widget(
+ new DrawableWidget().setDrawable(getGUITextureSet().getGregTechLogo()).setSize(17, 17)
+ .setPos(155, 145));
}
@Override
@@ -573,63 +530,61 @@ public abstract class GT_MetaTileEntity_FusionComputer
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new TextWidget(GT_Utility.trans("138", "Incomplete Structure."))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setEnabled(widget -> !mMachine)
- .setPos(10, 8))
+ builder.widget(
+ new TextWidget(GT_Utility.trans("138", "Incomplete Structure.")).setDefaultColor(COLOR_TEXT_WHITE.get())
+ .setEnabled(widget -> !mMachine).setPos(10, 8))
.widget(new FakeSyncWidget.BooleanSyncer(() -> mMachine, val -> mMachine = val))
- .widget(new TextWidget("Hit with Soft Mallet to (re-)start the Machine if it doesn't start.")
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setTextAlignment(Alignment.Center)
- .setEnabled(widget -> getBaseMetaTileEntity().getErrorDisplayID() == 0
- && !getBaseMetaTileEntity().isActive())
- .setPos(-getGUIWidth() / 2, 170)
- .setSize(getGUIWidth() * 2, 9))
- .widget(new FakeSyncWidget.IntegerSyncer(
- () -> getBaseMetaTileEntity().getErrorDisplayID(),
- val -> getBaseMetaTileEntity().setErrorDisplayID(val)))
- .widget(new FakeSyncWidget.BooleanSyncer(
- () -> getBaseMetaTileEntity().isActive(),
- val -> getBaseMetaTileEntity().setActive(val)))
- .widget(new TextWidget("Running perfectly.")
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setTextAlignment(Alignment.Center)
- .setEnabled(widget -> getBaseMetaTileEntity().getErrorDisplayID() == 0
- && getBaseMetaTileEntity().isActive())
- .setPos(0, 170)
- .setSize(getGUIWidth(), 9))
- .widget(new FakeSyncWidget.IntegerSyncer(
- () -> getBaseMetaTileEntity().getErrorDisplayID(),
- val -> getBaseMetaTileEntity().setErrorDisplayID(val)))
- .widget(new ProgressBar()
- .setProgress(() -> (float) getBaseMetaTileEntity().getStoredEU()
- / getBaseMetaTileEntity().getEUCapacity())
- .setDirection(ProgressBar.Direction.RIGHT)
- .setTexture(GT_UITextures.PROGRESSBAR_STORED_EU, 147)
- .setPos(5, 156)
- .setSize(147, 5))
+ .widget(
+ new TextWidget("Hit with Soft Mallet to (re-)start the Machine if it doesn't start.")
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setTextAlignment(Alignment.Center)
+ .setEnabled(
+ widget -> getBaseMetaTileEntity().getErrorDisplayID() == 0
+ && !getBaseMetaTileEntity().isActive())
+ .setPos(-getGUIWidth() / 2, 170).setSize(getGUIWidth() * 2, 9))
+ .widget(
+ new FakeSyncWidget.IntegerSyncer(
+ () -> getBaseMetaTileEntity().getErrorDisplayID(),
+ val -> getBaseMetaTileEntity().setErrorDisplayID(val)))
+ .widget(
+ new FakeSyncWidget.BooleanSyncer(
+ () -> getBaseMetaTileEntity().isActive(),
+ val -> getBaseMetaTileEntity().setActive(val)))
+ .widget(
+ new TextWidget("Running perfectly.").setDefaultColor(COLOR_TEXT_WHITE.get())
+ .setTextAlignment(Alignment.Center)
+ .setEnabled(
+ widget -> getBaseMetaTileEntity().getErrorDisplayID() == 0
+ && getBaseMetaTileEntity().isActive())
+ .setPos(0, 170).setSize(getGUIWidth(), 9))
+ .widget(
+ new FakeSyncWidget.IntegerSyncer(
+ () -> getBaseMetaTileEntity().getErrorDisplayID(),
+ val -> getBaseMetaTileEntity().setErrorDisplayID(val)))
+ .widget(
+ new ProgressBar()
+ .setProgress(
+ () -> (float) getBaseMetaTileEntity().getStoredEU()
+ / getBaseMetaTileEntity().getEUCapacity())
+ .setDirection(ProgressBar.Direction.RIGHT)
+ .setTexture(GT_UITextures.PROGRESSBAR_STORED_EU, 147).setPos(5, 156).setSize(147, 5))
.widget(TextWidget.dynamicString(() -> {
- long energy = getBaseMetaTileEntity().getStoredEU();
- if (energy > 160_000_000L && energy < 160_010_000L) {
- energy = 160_000_000L;
- }
- if (energy > 320_000_000L && energy < 320_010_000L) {
- energy = 320_000_000L;
- }
- if (energy > 640_000_000L && energy < 640_010_000L) {
- energy = 640_000_000L;
- }
- if (energy > 5_120_000_000L && energy < 5_120_080_000L) {
- energy = 5_120_000_000L;
- }
- return GT_Utility.formatNumbers(energy) + " EU";
- })
- .setDefaultColor(COLOR_TEXT_RED.get())
- .setPos(50, 155))
- .widget(new ButtonWidget()
- .setNEITransferRect(GT_Recipe.GT_Recipe_Map.sFusionRecipes.mNEIName)
- .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_NEI)
- .setPos(154, 4)
- .setSize(18, 18));
+ long energy = getBaseMetaTileEntity().getStoredEU();
+ if (energy > 160_000_000L && energy < 160_010_000L) {
+ energy = 160_000_000L;
+ }
+ if (energy > 320_000_000L && energy < 320_010_000L) {
+ energy = 320_000_000L;
+ }
+ if (energy > 640_000_000L && energy < 640_010_000L) {
+ energy = 640_000_000L;
+ }
+ if (energy > 5_120_000_000L && energy < 5_120_080_000L) {
+ energy = 5_120_000_000L;
+ }
+ return GT_Utility.formatNumbers(energy) + " EU";
+ }).setDefaultColor(COLOR_TEXT_RED.get()).setPos(50, 155)).widget(
+ new ButtonWidget().setNEITransferRect(GT_Recipe.GT_Recipe_Map.sFusionRecipes.mNEIName)
+ .setBackground(GT_UITextures.BUTTON_STANDARD, GT_UITextures.OVERLAY_BUTTON_NEI)
+ .setPos(154, 4).setSize(18, 18));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer1.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer1.java
index ef218cb643..f032a9b53e 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer1.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer1.java
@@ -3,23 +3,20 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FUSION1;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FUSION1_GLOW;
+import net.minecraft.block.Block;
+
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_FusionComputer1 extends GT_MetaTileEntity_FusionComputer {
private static final ITexture textureOverlay = TextureFactory.of(
TextureFactory.builder().addIcon(OVERLAY_FUSION1).extFacing().build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FUSION1_GLOW)
- .extFacing()
- .glow()
- .build());
+ TextureFactory.builder().addIcon(OVERLAY_FUSION1_GLOW).extFacing().glow().build());
public GT_MetaTileEntity_FusionComputer1(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, 6);
@@ -67,22 +64,16 @@ public class GT_MetaTileEntity_FusionComputer1 extends GT_MetaTileEntity_FusionC
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Fusion Reactor")
- .addInfo("It's over 9000!!!")
+ tt.addMachineType("Fusion Reactor").addInfo("It's over 9000!!!")
.addInfo("Controller block for the Fusion Reactor Mk I")
.addInfo("2048EU/t and 10M EU capacity per Energy Hatch")
.addInfo("If the recipe has a startup cost greater than the")
- .addInfo("number of energy hatches * cap, you can't do it")
- .addSeparator()
- .beginStructureBlock(15, 3, 15, false)
- .addController("See diagram when placed")
- .addCasingInfo("LuV Machine Casing", 79)
- .addStructureInfo("Cover the coils with casing")
+ .addInfo("number of energy hatches * cap, you can't do it").addSeparator()
+ .beginStructureBlock(15, 3, 15, false).addController("See diagram when placed")
+ .addCasingInfo("LuV Machine Casing", 79).addStructureInfo("Cover the coils with casing")
.addOtherStructurePart("Superconducting Coil Block", "Center part of the ring")
- .addEnergyHatch("1-16, Specified casings", 2)
- .addInputHatch("2-16, Specified casings", 1)
- .addOutputHatch("1-16, Specified casings", 3)
- .addStructureInfo("ALL Hatches must be LuV or better")
+ .addEnergyHatch("1-16, Specified casings", 2).addInputHatch("2-16, Specified casings", 1)
+ .addOutputHatch("1-16, Specified casings", 3).addStructureInfo("ALL Hatches must be LuV or better")
.toolTipFinisher("Gregtech");
return tt;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer2.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer2.java
index a763e1f639..6d95abd1cb 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer2.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer2.java
@@ -3,23 +3,20 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FUSION2;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FUSION2_GLOW;
+import net.minecraft.block.Block;
+
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_FusionComputer2 extends GT_MetaTileEntity_FusionComputer {
private static final ITexture textureOverlay = TextureFactory.of(
TextureFactory.builder().addIcon(OVERLAY_FUSION2).extFacing().build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FUSION2_GLOW)
- .extFacing()
- .glow()
- .build());
+ TextureFactory.builder().addIcon(OVERLAY_FUSION2_GLOW).extFacing().glow().build());
public GT_MetaTileEntity_FusionComputer2(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, 6);
@@ -67,22 +64,16 @@ public class GT_MetaTileEntity_FusionComputer2 extends GT_MetaTileEntity_FusionC
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Fusion Reactor")
- .addInfo("It's over 9000!!!")
+ tt.addMachineType("Fusion Reactor").addInfo("It's over 9000!!!")
.addInfo("Controller block for the Fusion Reactor Mk II")
.addInfo("8192EU/t and 20M EU capacity per Energy Hatch")
.addInfo("If the recipe has a startup cost greater than the")
- .addInfo("number of energy hatches * cap, you can't do it")
- .addSeparator()
- .beginStructureBlock(15, 3, 15, false)
- .addController("See diagram when placed")
- .addCasingInfo("Fusion Machine Casing", 79)
- .addStructureInfo("Cover the coils with casing")
+ .addInfo("number of energy hatches * cap, you can't do it").addSeparator()
+ .beginStructureBlock(15, 3, 15, false).addController("See diagram when placed")
+ .addCasingInfo("Fusion Machine Casing", 79).addStructureInfo("Cover the coils with casing")
.addOtherStructurePart("Fusion Coil Block", "Center part of the ring")
- .addEnergyHatch("1-16, Specified casings", 2)
- .addInputHatch("2-16, Specified casings", 1)
- .addOutputHatch("1-16, Specified casings", 3)
- .addStructureInfo("ALL Hatches must be ZPM or better")
+ .addEnergyHatch("1-16, Specified casings", 2).addInputHatch("2-16, Specified casings", 1)
+ .addOutputHatch("1-16, Specified casings", 3).addStructureInfo("ALL Hatches must be ZPM or better")
.toolTipFinisher("Gregtech");
return tt;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer3.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer3.java
index c2c0367d61..210a427f32 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer3.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_FusionComputer3.java
@@ -3,23 +3,20 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FUSION3;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FUSION3_GLOW;
+import net.minecraft.block.Block;
+
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_FusionComputer3 extends GT_MetaTileEntity_FusionComputer {
private static final ITexture textureOverlay = TextureFactory.of(
TextureFactory.builder().addIcon(OVERLAY_FUSION3).extFacing().build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FUSION3_GLOW)
- .extFacing()
- .glow()
- .build());
+ TextureFactory.builder().addIcon(OVERLAY_FUSION3_GLOW).extFacing().glow().build());
public GT_MetaTileEntity_FusionComputer3(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, 6);
@@ -67,22 +64,16 @@ public class GT_MetaTileEntity_FusionComputer3 extends GT_MetaTileEntity_FusionC
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Fusion Reactor")
- .addInfo("A SUN DOWN ON EARTH")
+ tt.addMachineType("Fusion Reactor").addInfo("A SUN DOWN ON EARTH")
.addInfo("Controller block for the Fusion Reactor Mk III")
.addInfo("32768EU/t and 40M EU capacity per Energy Hatch")
.addInfo("If the recipe has a startup cost greater than the")
- .addInfo("number of energy hatches * cap, you can't do it")
- .addSeparator()
- .beginStructureBlock(15, 3, 15, false)
- .addController("See diagram when placed")
- .addCasingInfo("Fusion Machine Casing Mk II", 79)
- .addStructureInfo("Cover the coils with casing")
+ .addInfo("number of energy hatches * cap, you can't do it").addSeparator()
+ .beginStructureBlock(15, 3, 15, false).addController("See diagram when placed")
+ .addCasingInfo("Fusion Machine Casing Mk II", 79).addStructureInfo("Cover the coils with casing")
.addOtherStructurePart("Fusion Coil Block", "Center part of the ring")
- .addEnergyHatch("1-16, Specified casings", 2)
- .addInputHatch("2-16, Specified casings", 1)
- .addOutputHatch("1-16, Specified casings", 3)
- .addStructureInfo("ALL Hatches must be UV or better")
+ .addEnergyHatch("1-16, Specified casings", 2).addInputHatch("2-16, Specified casings", 1)
+ .addOutputHatch("1-16, Specified casings", 3).addStructureInfo("ALL Hatches must be UV or better")
.toolTipFinisher("Gregtech");
return tt;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_HeatExchanger.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_HeatExchanger.java
index 6c35a3e9c2..e5921aaf32 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_HeatExchanger.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_HeatExchanger.java
@@ -7,11 +7,19 @@ import static gregtech.api.enums.GT_HatchElement.*;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.IAlignmentLimits;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
import gregtech.api.interfaces.ITexture;
@@ -26,49 +34,41 @@ import gregtech.api.util.GT_Log;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
-public class GT_MetaTileEntity_HeatExchanger
- extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_HeatExchanger>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_HeatExchanger extends
+ GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_HeatExchanger> implements ISurvivalConstructable {
+
private int dryHeatCounter = 0; // Counts up to dryHeatMaximum to check for explosion conditions
private static final int dryHeatMaximum = 2000; // 2000 ticks = 100 seconds
private static final int CASING_INDEX = 50;
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_HeatExchanger> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_HeatExchanger>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {"ccc", "cCc", "ccc"},
- {"ccc", "cPc", "ccc"},
- {"ccc", "cPc", "ccc"},
- {"c~c", "cHc", "ccc"},
- }))
- .addElement('P', ofBlock(GregTech_API.sBlockCasings2, 14))
- .addElement(
- 'C',
- OutputHatch.withAdder(GT_MetaTileEntity_HeatExchanger::addColdFluidOutputToMachineList)
- .withCount(t -> isValidMetaTileEntity(t.mOutputColdFluidHatch) ? 1 : 0)
- .newAny(CASING_INDEX, 3))
- .addElement(
- 'H',
- OutputHatch.withAdder(GT_MetaTileEntity_HeatExchanger::addHotFluidInputToMachineList)
- .withCount(t -> isValidMetaTileEntity(t.mInputHotFluidHatch) ? 1 : 0)
- .newAny(CASING_INDEX, 3))
- .addElement(
- 'c',
- buildHatchAdder(GT_MetaTileEntity_HeatExchanger.class)
- .atLeast(InputBus, InputHatch, OutputBus, OutputHatch, Maintenance)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .buildAndChain(onElementPass(
+ private static final IStructureDefinition<GT_MetaTileEntity_HeatExchanger> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_HeatExchanger>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "ccc", "cCc", "ccc" }, { "ccc", "cPc", "ccc" }, { "ccc", "cPc", "ccc" },
+ { "c~c", "cHc", "ccc" }, }))
+ .addElement('P', ofBlock(GregTech_API.sBlockCasings2, 14))
+ .addElement(
+ 'C',
+ OutputHatch.withAdder(GT_MetaTileEntity_HeatExchanger::addColdFluidOutputToMachineList)
+ .withCount(t -> isValidMetaTileEntity(t.mOutputColdFluidHatch) ? 1 : 0)
+ .newAny(CASING_INDEX, 3))
+ .addElement(
+ 'H',
+ OutputHatch.withAdder(GT_MetaTileEntity_HeatExchanger::addHotFluidInputToMachineList)
+ .withCount(t -> isValidMetaTileEntity(t.mInputHotFluidHatch) ? 1 : 0)
+ .newAny(CASING_INDEX, 3))
+ .addElement(
+ 'c',
+ buildHatchAdder(GT_MetaTileEntity_HeatExchanger.class)
+ .atLeast(InputBus, InputHatch, OutputBus, OutputHatch, Maintenance)
+ .casingIndex(CASING_INDEX).dot(1).buildAndChain(
+ onElementPass(
GT_MetaTileEntity_HeatExchanger::onCasingAdded,
ofBlock(GregTech_API.sBlockCasings4, (byte) 2))))
- .build();
+ .build();
public static float penalty_per_config = 0.015f; // penalize 1.5% efficiency per circuitry level (1-25)
private GT_MetaTileEntity_Hatch_Input mInputHotFluidHatch;
@@ -93,23 +93,16 @@ public class GT_MetaTileEntity_HeatExchanger
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Heat Exchanger")
- .addInfo("Controller Block for the Large Heat Exchanger")
- .addInfo("More complicated than a Fusion Reactor. Seriously")
- .addInfo("Inputs are Hot Coolant or Lava")
+ tt.addMachineType("Heat Exchanger").addInfo("Controller Block for the Large Heat Exchanger")
+ .addInfo("More complicated than a Fusion Reactor. Seriously").addInfo("Inputs are Hot Coolant or Lava")
.addInfo("Outputs Coolant or Pahoehoe Lava and SH Steam/Steam")
.addInfo("Read the wiki article to understand how it works")
- .addInfo("Then go to the Discord to understand the wiki")
- .addSeparator()
- .beginStructureBlock(3, 4, 3, false)
- .addController("Front bottom")
+ .addInfo("Then go to the Discord to understand the wiki").addSeparator()
+ .beginStructureBlock(3, 4, 3, false).addController("Front bottom")
.addCasingInfo("Stable Titanium Machine Casing", 20)
- .addOtherStructurePart("Titanium Pipe Casing", "Center 2 blocks")
- .addMaintenanceHatch("Any casing", 1)
- .addInputHatch("Hot fluid, bottom center", 2)
- .addInputHatch("Distilled water, any casing", 1)
- .addOutputHatch("Cold fluid, top center", 3)
- .addOutputHatch("Steam/SH Steam, any casing", 1)
+ .addOtherStructurePart("Titanium Pipe Casing", "Center 2 blocks").addMaintenanceHatch("Any casing", 1)
+ .addInputHatch("Hot fluid, bottom center", 2).addInputHatch("Distilled water, any casing", 1)
+ .addOutputHatch("Cold fluid, top center", 3).addOutputHatch("Steam/SH Steam, any casing", 1)
.toolTipFinisher("Gregtech");
return tt;
}
@@ -129,41 +122,18 @@ public class GT_MetaTileEntity_HeatExchanger
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_HEAT_EXCHANGER_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_HEAT_EXCHANGER_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_HEAT_EXCHANGER)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_HEAT_EXCHANGER_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_HEAT_EXCHANGER_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_HEAT_EXCHANGER_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_HEAT_EXCHANGER).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_HEAT_EXCHANGER_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {casingTexturePages[0][CASING_INDEX]};
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX] };
}
@Override
@@ -221,11 +191,11 @@ public class GT_MetaTileEntity_HeatExchanger
return false;
}
- superheated = fluidAmountToConsume
- >= superheated_threshold; // set the internal superheated flag if we have enough hot fluid. Used in the
+ superheated = fluidAmountToConsume >= superheated_threshold; // set the internal superheated flag if we have
+ // enough hot fluid. Used in the
// onRunningTick method.
- fluidAmountToConsume = Math.min(
- fluidAmountToConsume, superheated_threshold * 2); // Don't consume too much hot fluid per second
+ fluidAmountToConsume = Math.min(fluidAmountToConsume, superheated_threshold * 2); // Don't consume too much hot
+ // fluid per second
mInputHotFluidHatch.drain(fluidAmountToConsume, true);
this.mMaxProgresstime = 20;
this.mEUt = (int) (fluidAmountToConsume * steam_output_multiplier * efficiency);
@@ -253,8 +223,8 @@ public class GT_MetaTileEntity_HeatExchanger
@Override
public boolean onRunningTick(ItemStack aStack) {
if (this.mEUt > 0) {
- int tGeneratedEU =
- (int) (this.mEUt * 2L * this.mEfficiency / 10000L); // APPROXIMATELY how much steam to generate.
+ int tGeneratedEU = (int) (this.mEUt * 2L * this.mEfficiency / 10000L); // APPROXIMATELY how much steam to
+ // generate.
if (tGeneratedEU > 0) {
if (superheated) tGeneratedEU /= 2; // We produce half as much superheated steam if necessary
@@ -267,8 +237,9 @@ public class GT_MetaTileEntity_HeatExchanger
if (depleteInput(distilledStack)) // Consume the distilled water
{
if (superheated) {
- addOutput(FluidRegistry.getFluidStack(
- "ic2superheatedsteam", tGeneratedEU)); // Generate superheated steam
+ addOutput(FluidRegistry.getFluidStack("ic2superheatedsteam", tGeneratedEU)); // Generate
+ // superheated
+ // steam
} else {
addOutput(GT_ModHandler.getSteam(tGeneratedEU)); // Generate regular steam
}
@@ -357,26 +328,43 @@ public class GT_MetaTileEntity_HeatExchanger
@Override
public String[] getInfoData() {
return new String[] {
- StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mProgresstime / 20) + EnumChatFormatting.RESET + " s / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(mMaxProgresstime / 20) + EnumChatFormatting.RESET + " s",
- StatCollector.translateToLocal("GT5U.multiblock.usage") + " "
- + StatCollector.translateToLocal("GT5U.LHE.steam") + ": "
- + (superheated ? EnumChatFormatting.RED : EnumChatFormatting.YELLOW)
- + GT_Utility.formatNumbers(superheated ? -2 * mEUt : -mEUt) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.multiblock.problems") + ": " + EnumChatFormatting.RED
- + (getIdealStatus() - getRepairStatus()) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
- + ": " + EnumChatFormatting.YELLOW
- + mEfficiency / 100.0F + EnumChatFormatting.RESET + " %",
- StatCollector.translateToLocal("GT5U.LHE.superheated") + ": "
- + (superheated ? EnumChatFormatting.RED : EnumChatFormatting.BLUE) + superheated
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.LHE.superheated") + " "
- + StatCollector.translateToLocal("GT5U.LHE.threshold") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(superheated_threshold) + EnumChatFormatting.RESET
- };
+ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(mMaxProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s",
+ StatCollector.translateToLocal("GT5U.multiblock.usage") + " "
+ + StatCollector.translateToLocal("GT5U.LHE.steam")
+ + ": "
+ + (superheated ? EnumChatFormatting.RED : EnumChatFormatting.YELLOW)
+ + GT_Utility.formatNumbers(superheated ? -2 * mEUt : -mEUt)
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.multiblock.problems") + ": "
+ + EnumChatFormatting.RED
+ + (getIdealStatus() - getRepairStatus())
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + mEfficiency / 100.0F
+ + EnumChatFormatting.RESET
+ + " %",
+ StatCollector.translateToLocal("GT5U.LHE.superheated") + ": "
+ + (superheated ? EnumChatFormatting.RED : EnumChatFormatting.BLUE)
+ + superheated
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.LHE.superheated") + " "
+ + StatCollector.translateToLocal("GT5U.LHE.threshold")
+ + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(superheated_threshold)
+ + EnumChatFormatting.RESET };
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ImplosionCompressor.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ImplosionCompressor.java
index 1b2c690a57..ed7ca009c5 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ImplosionCompressor.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ImplosionCompressor.java
@@ -4,7 +4,12 @@ import static com.gtnewhorizon.structurelib.structure.StructureUtility.ofBlock;
import static com.gtnewhorizon.structurelib.structure.StructureUtility.ofChain;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.ArrayList;
+
+import net.minecraft.item.ItemStack;
+
import com.gtnewhorizon.structurelib.structure.IStructureElement;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.SoundResource;
@@ -18,11 +23,10 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_ImplosionCompressor
extends GT_MetaTileEntity_CubicMultiBlockBase<GT_MetaTileEntity_ImplosionCompressor> {
+
public GT_MetaTileEntity_ImplosionCompressor(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
@@ -39,21 +43,13 @@ public class GT_MetaTileEntity_ImplosionCompressor
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Implosion Compressor")
- .addInfo("Explosions are fun")
+ tt.addMachineType("Implosion Compressor").addInfo("Explosions are fun")
.addInfo("Controller block for the Implosion Compressor")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 3, 3, true)
- .addController("Front center")
- .addCasingInfo("Solid Steel Machine Casing", 16)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 3, 3, true)
+ .addController("Front center").addCasingInfo("Solid Steel Machine Casing", 16)
.addStructureInfo("Casings can be replaced with Explosion Warning Signs")
- .addEnergyHatch("Any casing", 1)
- .addMaintenanceHatch("Any casing", 1)
- .addMufflerHatch("Any casing", 1)
- .addInputBus("Any casing", 1)
- .addOutputBus("Any casing", 1)
- .toolTipFinisher("Gregtech");
+ .addEnergyHatch("Any casing", 1).addMaintenanceHatch("Any casing", 1).addMufflerHatch("Any casing", 1)
+ .addInputBus("Any casing", 1).addOutputBus("Any casing", 1).toolTipFinisher("Gregtech");
return tt;
}
@@ -64,41 +60,19 @@ public class GT_MetaTileEntity_ImplosionCompressor
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- BlockIcons.casingTexturePages[0][16],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- BlockIcons.casingTexturePages[0][16],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { BlockIcons.casingTexturePages[0][16],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { BlockIcons.casingTexturePages[0][16],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_IMPLOSION_COMPRESSOR_GLOW).extFacing().glow()
+ .build() };
}
- return new ITexture[] {Textures.BlockIcons.casingTexturePages[0][16]};
+ return new ITexture[] { Textures.BlockIcons.casingTexturePages[0][16] };
}
@Override
@@ -131,8 +105,8 @@ public class GT_MetaTileEntity_ImplosionCompressor
}
ItemStack[] tInputs = tInputList.toArray(new ItemStack[0]);
if (!tInputList.isEmpty()) {
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sImplosionRecipes.findRecipe(
- getBaseMetaTileEntity(), false, 9223372036854775807L, null, tInputs);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sImplosionRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, 9223372036854775807L, null, tInputs);
if ((tRecipe != null) && (tRecipe.isRecipeInputEqual(true, null, tInputs))) {
this.mEfficiency = (10000 - (getIdealStatus() - getRepairStatus()) * 1000);
this.mEfficiencyIncrease = 10000;
@@ -143,7 +117,7 @@ public class GT_MetaTileEntity_ImplosionCompressor
if (this.mEUt > 0) {
this.mEUt = (-this.mEUt);
}
- this.mOutputItems = new ItemStack[] {tRecipe.getOutput(0), tRecipe.getOutput(1)};
+ this.mOutputItems = new ItemStack[] { tRecipe.getOutput(0), tRecipe.getOutput(1) };
sendLoopStart((byte) 20);
updateSlots();
return true;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_IntegratedOreFactory.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_IntegratedOreFactory.java
index 1d52753a8c..8b7c5cdf99 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_IntegratedOreFactory.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_IntegratedOreFactory.java
@@ -6,11 +6,23 @@ import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofFrame;
+import java.util.*;
+import java.util.stream.Collectors;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.oredict.OreDictionary;
+
import com.gtnewhorizon.structurelib.alignment.IAlignmentLimits;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import cpw.mods.fml.common.registry.GameRegistry;
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
@@ -28,15 +40,6 @@ import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.*;
-import java.util.stream.Collectors;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.oredict.OreDictionary;
public class GT_MetaTileEntity_IntegratedOreFactory
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_IntegratedOreFactory>
@@ -52,57 +55,58 @@ public class GT_MetaTileEntity_IntegratedOreFactory
private static final String SIFTER = "Sifter";
private static final String CHEM_WASH = "Chemical Bathing";
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_IntegratedOreFactory> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_IntegratedOreFactory>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {" ", " ", " WWW ", " WWW ", " ", " "},
- {" ", " sss ", " sppps", " sppps", " sss ", " "},
- {" ", " sss ", " s s", " s s", " sss ", " "},
- {" ", " sss ", " sppps", " sppps", " sss ", " "},
- {" ", " sss ", " s s", " s s", " sss ", " "},
- {" ", " sss ", " sppps", " sppps", " sss ", " "},
- {"iiiiii ", "iIIIIiisssi", "iIIIIis s", "iIIIIis s", "iIIIIiisssi", "iiiiii "},
- {"iggggi ", "gt t isssi", "g xx sppps", "g xx sppps", "gt t isssi", "iggggi "},
- {"iggggi ", "gt t isssi", "g xx s s", "g xx s s", "gt t isssi", "iggggi "},
- {"iggggi ", "gt t is~si", "g xx spppO", "g xx spppO", "gt t isssi", "iggggi "},
- {"iggggi ", "gt t isssi", "g xx s O", "g xx s O", "gt t isssi", "iggggi "},
- {"EEEEEE ", "EEEEEEEEEEE", "EEEEEEEEEEE", "EEEEEEEEEEE", "EEEEEEEEEEE", "EEEEEE "}
- }))
- .addElement('i', ofBlock(GregTech_API.sBlockCasings8, 7))
- .addElement('s', ofBlock(GregTech_API.sBlockCasings4, 1))
- .addElement('g', ofBlockAnyMeta(GameRegistry.findBlock("IC2", "blockAlloyGlass")))
- .addElement('x', ofBlock(GregTech_API.sBlockCasings2, 3))
- .addElement('p', ofBlock(GregTech_API.sBlockCasings2, 15))
- .addElement('t', ofFrame(Materials.TungstenSteel))
- .addElement(
- 'E',
- buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class)
- .atLeast(Energy, Maintenance)
- .casingIndex(CASING_INDEX1)
- .dot(1)
- .buildAndChain(GregTech_API.sBlockCasings8, 7))
- .addElement(
- 'I',
- buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class)
- .atLeast(InputBus)
- .casingIndex(CASING_INDEX1)
- .dot(2)
- .buildAndChain(GregTech_API.sBlockCasings8, 7))
- .addElement(
- 'W',
- buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class)
- .atLeast(InputHatch, Muffler)
- .casingIndex(CASING_INDEX2)
- .dot(3)
- .buildAndChain(GregTech_API.sBlockCasings4, 1))
- .addElement(
- 'O',
- buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class)
- .atLeast(OutputBus, OutputHatch)
- .casingIndex(CASING_INDEX2)
- .dot(4)
- .buildAndChain(GregTech_API.sBlockCasings4, 1))
- .build();
+ private static final IStructureDefinition<GT_MetaTileEntity_IntegratedOreFactory> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_IntegratedOreFactory>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] {
+ { " ", " ", " WWW ", " WWW ", " ",
+ " " },
+ { " ", " sss ", " sppps", " sppps", " sss ",
+ " " },
+ { " ", " sss ", " s s", " s s", " sss ",
+ " " },
+ { " ", " sss ", " sppps", " sppps", " sss ",
+ " " },
+ { " ", " sss ", " s s", " s s", " sss ",
+ " " },
+ { " ", " sss ", " sppps", " sppps", " sss ",
+ " " },
+ { "iiiiii ", "iIIIIiisssi", "iIIIIis s", "iIIIIis s", "iIIIIiisssi",
+ "iiiiii " },
+ { "iggggi ", "gt t isssi", "g xx sppps", "g xx sppps", "gt t isssi",
+ "iggggi " },
+ { "iggggi ", "gt t isssi", "g xx s s", "g xx s s", "gt t isssi",
+ "iggggi " },
+ { "iggggi ", "gt t is~si", "g xx spppO", "g xx spppO", "gt t isssi",
+ "iggggi " },
+ { "iggggi ", "gt t isssi", "g xx s O", "g xx s O", "gt t isssi",
+ "iggggi " },
+ { "EEEEEE ", "EEEEEEEEEEE", "EEEEEEEEEEE", "EEEEEEEEEEE", "EEEEEEEEEEE",
+ "EEEEEE " } }))
+ .addElement('i', ofBlock(GregTech_API.sBlockCasings8, 7))
+ .addElement('s', ofBlock(GregTech_API.sBlockCasings4, 1))
+ .addElement('g', ofBlockAnyMeta(GameRegistry.findBlock("IC2", "blockAlloyGlass")))
+ .addElement('x', ofBlock(GregTech_API.sBlockCasings2, 3))
+ .addElement('p', ofBlock(GregTech_API.sBlockCasings2, 15)).addElement('t', ofFrame(Materials.TungstenSteel))
+ .addElement(
+ 'E',
+ buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class).atLeast(Energy, Maintenance)
+ .casingIndex(CASING_INDEX1).dot(1).buildAndChain(GregTech_API.sBlockCasings8, 7))
+ .addElement(
+ 'I',
+ buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class).atLeast(InputBus)
+ .casingIndex(CASING_INDEX1).dot(2).buildAndChain(GregTech_API.sBlockCasings8, 7))
+ .addElement(
+ 'W',
+ buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class).atLeast(InputHatch, Muffler)
+ .casingIndex(CASING_INDEX2).dot(3).buildAndChain(GregTech_API.sBlockCasings4, 1))
+ .addElement(
+ 'O',
+ buildHatchAdder(GT_MetaTileEntity_IntegratedOreFactory.class).atLeast(OutputBus, OutputHatch)
+ .casingIndex(CASING_INDEX2).dot(4).buildAndChain(GregTech_API.sBlockCasings4, 1))
+ .build();
private static final HashSet<Integer> isCrushedOre = new HashSet<>();
private static final HashSet<Integer> isCrushedPureOre = new HashSet<>();
@@ -178,31 +182,20 @@ public class GT_MetaTileEntity_IntegratedOreFactory
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Ore Processor")
- .addInfo("Controller Block for the Integrated Ore Factory")
- .addInfo("It is OP. I mean ore processor.")
- .addInfo("Do all ore procession in one step.")
+ tt.addMachineType("Ore Processor").addInfo("Controller Block for the Integrated Ore Factory")
+ .addInfo("It is OP. I mean ore processor.").addInfo("Do all ore procession in one step.")
.addInfo("Can process up to 1024 ores per time.")
.addInfo("Every ore costs 30EU/t, 2L lubricant, 200L distilled water.")
- .addInfo("Process time is depend on mode.")
- .addInfo("Use a screwdriver to switch mode.")
- .addInfo("Sneak click with screwdriver to void the stone dusts.")
- .addSeparator()
- .beginStructureBlock(6, 12, 11, false)
- .addController("The third layer")
+ .addInfo("Process time is depend on mode.").addInfo("Use a screwdriver to switch mode.")
+ .addInfo("Sneak click with screwdriver to void the stone dusts.").addSeparator()
+ .beginStructureBlock(6, 12, 11, false).addController("The third layer")
.addStructureInfo("128 advanced iridium plated machine casing")
- .addStructureInfo("105 clean stainless steel machine casing")
- .addStructureInfo("48 reinforced glass")
- .addStructureInfo("30 tungstensteel pipe casing")
- .addStructureInfo("16 tungstensteel frame box")
- .addStructureInfo("16 steel gear box casing")
- .addEnergyHatch("Button Casing", 1)
- .addMaintenanceHatch("Button Casing", 1)
- .addInputBus("Input ore/crushed ore", 2)
+ .addStructureInfo("105 clean stainless steel machine casing").addStructureInfo("48 reinforced glass")
+ .addStructureInfo("30 tungstensteel pipe casing").addStructureInfo("16 tungstensteel frame box")
+ .addStructureInfo("16 steel gear box casing").addEnergyHatch("Button Casing", 1)
+ .addMaintenanceHatch("Button Casing", 1).addInputBus("Input ore/crushed ore", 2)
.addInputHatch("Input lubricant/distilled water/washing chemicals", 3)
- .addMufflerHatch("Output Pollution", 3)
- .addOutputBus("Output products", 4)
- .toolTipFinisher("Gregtech");
+ .addMufflerHatch("Output Pollution", 3).addOutputBus("Output products", 4).toolTipFinisher("Gregtech");
return tt;
}
@@ -276,8 +269,7 @@ public class GT_MetaTileEntity_IntegratedOreFactory
if (tCharged <= 0) break;
int tID = GT_Utility.stackToInt(ore);
if (tID == 0) continue;
- if (isPureDust.contains(tID)
- || isImpureDust.contains(tID)
+ if (isPureDust.contains(tID) || isImpureDust.contains(tID)
|| isCrushedPureOre.contains(tID)
|| isThermal.contains(tID)
|| isCrushedOre.contains(tID)
@@ -369,7 +361,8 @@ public class GT_MetaTileEntity_IntegratedOreFactory
if (aPlayer.isSneaking()) {
sVoidStone = !sVoidStone;
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocalFormatted("GT5U.machines.oreprocessor.void", sVoidStone));
+ aPlayer,
+ StatCollector.translateToLocalFormatted("GT5U.machines.oreprocessor.void", sVoidStone));
return;
}
sMode = (sMode + 1) % 5;
@@ -394,7 +387,8 @@ public class GT_MetaTileEntity_IntegratedOreFactory
des = "";
}
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocalFormatted("GT5U.machines.oreprocessor", des, getTime() / 20));
+ aPlayer,
+ StatCollector.translateToLocalFormatted("GT5U.machines.oreprocessor", des, getTime() / 20));
}
@Override
@@ -420,8 +414,8 @@ public class GT_MetaTileEntity_IntegratedOreFactory
for (ItemStack aStack : sMidProduct) {
int tID = GT_Utility.stackToInt(aStack);
if (checkTypes(tID, aTables)) {
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sMaceratorRecipes.findRecipe(
- getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sMaceratorRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
if (tRecipe != null) {
tProduct.addAll(getOutputStack(tRecipe, aStack.stackSize));
} else {
@@ -446,7 +440,7 @@ public class GT_MetaTileEntity_IntegratedOreFactory
getBaseMetaTileEntity(),
false,
GT_Values.V[15],
- new FluidStack[] {GT_ModHandler.getDistilledWater(Integer.MAX_VALUE)},
+ new FluidStack[] { GT_ModHandler.getDistilledWater(Integer.MAX_VALUE) },
aStack);
if (tRecipe != null) {
tProduct.addAll(getOutputStack(tRecipe, aStack.stackSize));
@@ -468,8 +462,8 @@ public class GT_MetaTileEntity_IntegratedOreFactory
for (ItemStack aStack : sMidProduct) {
int tID = GT_Utility.stackToInt(aStack);
if (checkTypes(tID, aTables)) {
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sThermalCentrifugeRecipes.findRecipe(
- getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sThermalCentrifugeRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
if (tRecipe != null) {
tProduct.addAll(getOutputStack(tRecipe, aStack.stackSize));
} else {
@@ -490,8 +484,8 @@ public class GT_MetaTileEntity_IntegratedOreFactory
for (ItemStack aStack : sMidProduct) {
int tID = GT_Utility.stackToInt(aStack);
if (checkTypes(tID, aTables)) {
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sCentrifugeRecipes.findRecipe(
- getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sCentrifugeRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
if (tRecipe != null) {
tProduct.addAll(getOutputStack(tRecipe, aStack.stackSize));
} else {
@@ -512,8 +506,8 @@ public class GT_MetaTileEntity_IntegratedOreFactory
for (ItemStack aStack : sMidProduct) {
int tID = GT_Utility.stackToInt(aStack);
if (checkTypes(tID, aTables)) {
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sSifterRecipes.findRecipe(
- getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sSifterRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, GT_Values.V[15], null, aStack);
if (tRecipe != null) {
tProduct.addAll(getOutputStack(tRecipe, aStack.stackSize));
} else {
@@ -541,8 +535,7 @@ public class GT_MetaTileEntity_IntegratedOreFactory
getStoredFluids().toArray(new FluidStack[0]),
aStack);
if (tRecipe != null && tRecipe.getRepresentativeFluidInput(0) != null) {
- FluidStack tInputFluid =
- tRecipe.getRepresentativeFluidInput(0).copy();
+ FluidStack tInputFluid = tRecipe.getRepresentativeFluidInput(0).copy();
int tStored = getFluidAmount(tInputFluid);
int tWashed = Math.min(tStored / tInputFluid.amount, aStack.stackSize);
depleteInput(new FluidStack(tInputFluid.getFluid(), tWashed * tInputFluid.amount));
@@ -622,8 +615,7 @@ public class GT_MetaTileEntity_IntegratedOreFactory
@Override
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
- return checkPiece(STRUCTURE_PIECE_MAIN, 8, 9, 1)
- && mMaintenanceHatches.size() <= 1
+ return checkPiece(STRUCTURE_PIECE_MAIN, 8, 9, 1) && mMaintenanceHatches.size() <= 1
&& !mMufflerHatches.isEmpty();
}
@@ -664,46 +656,25 @@ public class GT_MetaTileEntity_IntegratedOreFactory
public String[] getInfoData() {
List<String> informationData = new ArrayList<>(Arrays.asList(super.getInfoData()));
String parallelism = StatCollector.translateToLocal("GT5U.multiblock.parallelism") + ": "
- + EnumChatFormatting.BLUE + getCurrentParallelism() + EnumChatFormatting.RESET;
+ + EnumChatFormatting.BLUE
+ + getCurrentParallelism()
+ + EnumChatFormatting.RESET;
informationData.add(parallelism);
return informationData.toArray(new String[0]);
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- Textures.BlockIcons.getCasingTextureForId(CASING_INDEX2),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- Textures.BlockIcons.getCasingTextureForId(CASING_INDEX2),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX2),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX2),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {Textures.BlockIcons.getCasingTextureForId(CASING_INDEX2)};
+ return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(CASING_INDEX2) };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler.java
index b0c9e55a81..93d42acec0 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler.java
@@ -14,10 +14,19 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_LARGE_BOILER_
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_Utility.formatNumbers;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.GT_Mod;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
@@ -33,47 +42,41 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_OreDictUnificator;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
-public abstract class GT_MetaTileEntity_LargeBoiler
- extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_LargeBoiler>
- implements ISurvivalConstructable {
+public abstract class GT_MetaTileEntity_LargeBoiler extends
+ GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_LargeBoiler> implements ISurvivalConstructable {
+
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeBoiler>> STRUCTURE_DEFINITION =
- new ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeBoiler>>() {
- @Override
- protected IStructureDefinition<GT_MetaTileEntity_LargeBoiler> computeValue(Class<?> type) {
- return StructureDefinition.<GT_MetaTileEntity_LargeBoiler>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {"ccc", "ccc", "ccc"},
- {"ccc", "cPc", "ccc"},
- {"ccc", "cPc", "ccc"},
- {"ccc", "cPc", "ccc"},
- {"f~f", "fff", "fff"},
- }))
- .addElement('P', lazy(t -> ofBlock(t.getPipeBlock(), t.getPipeMeta())))
- .addElement('c', lazy(t -> buildHatchAdder(GT_MetaTileEntity_LargeBoiler.class)
- .atLeast(OutputHatch)
- .casingIndex(t.getCasingTextureIndex())
- .dot(2)
- .buildAndChain(onElementPass(
- GT_MetaTileEntity_LargeBoiler::onCasingAdded,
- ofBlock(t.getCasingBlock(), t.getCasingMeta())))))
- .addElement('f', lazy(t -> buildHatchAdder(GT_MetaTileEntity_LargeBoiler.class)
- .atLeast(Maintenance, InputHatch, InputBus, Muffler)
- .casingIndex(t.getFireboxTextureIndex())
- .dot(1)
- .buildAndChain(onElementPass(
- GT_MetaTileEntity_LargeBoiler::onFireboxAdded,
- ofBlock(t.getFireboxBlock(), t.getFireboxMeta())))))
- .build();
- }
- };
+ private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeBoiler>> STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeBoiler>>() {
+
+ @Override
+ protected IStructureDefinition<GT_MetaTileEntity_LargeBoiler> computeValue(Class<?> type) {
+ return StructureDefinition.<GT_MetaTileEntity_LargeBoiler>builder().addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "ccc", "ccc", "ccc" }, { "ccc", "cPc", "ccc" }, { "ccc", "cPc", "ccc" },
+ { "ccc", "cPc", "ccc" }, { "f~f", "fff", "fff" }, }))
+ .addElement('P', lazy(t -> ofBlock(t.getPipeBlock(), t.getPipeMeta())))
+ .addElement(
+ 'c',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_LargeBoiler.class).atLeast(OutputHatch)
+ .casingIndex(t.getCasingTextureIndex()).dot(2).buildAndChain(
+ onElementPass(
+ GT_MetaTileEntity_LargeBoiler::onCasingAdded,
+ ofBlock(t.getCasingBlock(), t.getCasingMeta())))))
+ .addElement(
+ 'f',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_LargeBoiler.class)
+ .atLeast(Maintenance, InputHatch, InputBus, Muffler)
+ .casingIndex(t.getFireboxTextureIndex()).dot(1).buildAndChain(
+ onElementPass(
+ GT_MetaTileEntity_LargeBoiler::onFireboxAdded,
+ ofBlock(t.getFireboxBlock(), t.getFireboxMeta())))))
+ .build();
+ }
+ };
private boolean firstRun = true;
private int mSuperEfficencyIncrease = 0;
private int integratedCircuitConfig = 0; // Steam output is reduced by 1000L per config
@@ -100,7 +103,8 @@ public abstract class GT_MetaTileEntity_LargeBoiler
// Tooltip differs between the boilers that output Superheated Steam (Titanium and Tungstensteel) and the ones
// that do not (Bronze and Steel)
if (isSuperheated()) {
- tt.addInfo("Produces " + formatNumbers((getEUt() * 40) * ((runtimeBoost(20) / (20f)) / superToNormalSteam))
+ tt.addInfo(
+ "Produces " + formatNumbers((getEUt() * 40) * ((runtimeBoost(20) / (20f)) / superToNormalSteam))
+ "L of Superheated Steam with 1 Coal at "
+ formatNumbers((getEUt() * 40L) / superToNormalSteam)
+ "L/s") // ?
@@ -108,29 +112,27 @@ public abstract class GT_MetaTileEntity_LargeBoiler
.addInfo("Only some solid fuels are allowed (check the NEI Large Boiler tab for details)")
.addInfo("If there are any disallowed fuels in the input bus, the boiler won't run!");
} else {
- tt.addInfo("Produces " + formatNumbers((getEUt() * 40) * (runtimeBoost(20) / 20f))
- + "L of Steam with 1 Coal at " + formatNumbers(getEUt() * 40) + "L/s") // ?
+ tt.addInfo(
+ "Produces " + formatNumbers((getEUt() * 40) * (runtimeBoost(20) / 20f))
+ + "L of Steam with 1 Coal at "
+ + formatNumbers(getEUt() * 40)
+ + "L/s") // ?
.addInfo("A programmed circuit in the main block throttles the boiler (-1000L/s per config)")
.addInfo("Solid Fuels with a burn value that is too high or too low will not work");
}
- tt.addInfo(String.format(
+ tt.addInfo(
+ String.format(
"Diesel fuels have 1/4 efficiency - Takes %s seconds to heat up",
formatNumbers(500.0 / getEfficiencyIncrease()))) // ? check semifluid again
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 5, 3, false)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 5, 3, false)
.addController("Front bottom")
.addCasingInfo(getCasingMaterial() + " " + getCasingBlockType() + " Casing", 24) // ?
.addOtherStructurePart(getCasingMaterial() + " Fire Boxes", "Bottom layer, 3 minimum")
.addOtherStructurePart(getCasingMaterial() + " Pipe Casing Blocks", "Inner 3 blocks")
- .addMaintenanceHatch("Any firebox", 1)
- .addMufflerHatch("Any firebox", 1)
- .addInputBus("Solid fuel, Any firebox", 1)
- .addInputHatch("Liquid fuel, Any firebox", 1)
- .addStructureInfo("You can use either, or both")
- .addInputHatch("Water, Any firebox", 1)
- .addOutputHatch("Steam, any casing", 2)
- .toolTipFinisher("Gregtech");
+ .addMaintenanceHatch("Any firebox", 1).addMufflerHatch("Any firebox", 1)
+ .addInputBus("Solid fuel, Any firebox", 1).addInputHatch("Liquid fuel, Any firebox", 1)
+ .addStructureInfo("You can use either, or both").addInputHatch("Water, Any firebox", 1)
+ .addOutputHatch("Steam, any casing", 2).toolTipFinisher("Gregtech");
return tt;
}
@@ -166,46 +168,25 @@ public abstract class GT_MetaTileEntity_LargeBoiler
@Override
public int getPollutionPerSecond(ItemStack aStack) {
// allows for 0 pollution if circuit throttle is too high
- return Math.max(0, (int) (pollutionPerSecond
- * (1 - GT_Mod.gregtechproxy.mPollutionReleasedByThrottle * getIntegratedCircuitConfig())));
+ return Math.max(
+ 0,
+ (int) (pollutionPerSecond
+ * (1 - GT_Mod.gregtechproxy.mPollutionReleasedByThrottle * getIntegratedCircuitConfig())));
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- BlockIcons.getCasingTextureForId(getCasingTextureIndex()),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_BOILER_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_BOILER_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- BlockIcons.getCasingTextureForId(getCasingTextureIndex()),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_BOILER)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_BOILER_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { BlockIcons.getCasingTextureForId(getCasingTextureIndex()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_BOILER_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_BOILER_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { BlockIcons.getCasingTextureForId(getCasingTextureIndex()),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_BOILER).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_BOILER_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {Textures.BlockIcons.getCasingTextureForId(getCasingTextureIndex())};
+ return new ITexture[] { Textures.BlockIcons.getCasingTextureForId(getCasingTextureIndex()) };
}
@Override
@@ -262,8 +243,8 @@ public abstract class GT_MetaTileEntity_LargeBoiler
if (tFluid != null) {
tFluid.amount = 1000;
if (depleteInput(tFluid)) {
- this.mMaxProgresstime =
- adjustBurnTimeForConfig(Math.max(1, runtimeBoost(tRecipe.mSpecialValue * 2)));
+ this.mMaxProgresstime = adjustBurnTimeForConfig(
+ Math.max(1, runtimeBoost(tRecipe.mSpecialValue * 2)));
this.mEUt = adjustEUtForConfig(getEUt());
this.mEfficiencyIncrease = this.mMaxProgresstime * getEfficiencyIncrease();
return true;
@@ -285,7 +266,7 @@ public abstract class GT_MetaTileEntity_LargeBoiler
this.mMaxProgresstime = adjustBurnTimeForConfig(runtimeBoost(this.mMaxProgresstime));
this.mEUt = adjustEUtForConfig(getEUt());
this.mEfficiencyIncrease = this.mMaxProgresstime * getEfficiencyIncrease();
- this.mOutputItems = new ItemStack[] {GT_Utility.getContainerItem(tInput, true)};
+ this.mOutputItems = new ItemStack[] { GT_Utility.getContainerItem(tInput, true) };
tInput.stackSize -= 1;
updateSlots();
if (this.mEfficiencyIncrease > 5000) {
@@ -311,7 +292,7 @@ public abstract class GT_MetaTileEntity_LargeBoiler
this.mMaxProgresstime = adjustBurnTimeForConfig(runtimeBoost(this.mMaxProgresstime));
this.mEUt = adjustEUtForConfig(getEUt());
this.mEfficiencyIncrease = this.mMaxProgresstime * getEfficiencyIncrease();
- this.mOutputItems = new ItemStack[] {GT_Utility.getContainerItem(tInput, true)};
+ this.mOutputItems = new ItemStack[] { GT_Utility.getContainerItem(tInput, true) };
tInput.stackSize -= 1;
updateSlots();
if (this.mEfficiencyIncrease > 5000) {
@@ -338,12 +319,11 @@ public abstract class GT_MetaTileEntity_LargeBoiler
@Override
public boolean onRunningTick(ItemStack aStack) {
if (this.mEUt > 0) {
- if (this.mSuperEfficencyIncrease > 0)
- mEfficiency = Math.max(
- 0,
- Math.min(
- mEfficiency + mSuperEfficencyIncrease,
- getMaxEfficiency(mInventory[1]) - ((getIdealStatus() - getRepairStatus()) * 1000)));
+ if (this.mSuperEfficencyIncrease > 0) mEfficiency = Math.max(
+ 0,
+ Math.min(
+ mEfficiency + mSuperEfficencyIncrease,
+ getMaxEfficiency(mInventory[1]) - ((getIdealStatus() - getRepairStatus()) * 1000)));
int tGeneratedEU = (int) (this.mEUt * 2L * this.mEfficiency / 10000L);
if (tGeneratedEU > 0) {
long amount = (tGeneratedEU + STEAM_PER_WATER) / STEAM_PER_WATER;
@@ -422,8 +402,7 @@ public abstract class GT_MetaTileEntity_LargeBoiler
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
mCasingAmount = 0;
mFireboxAmount = 0;
- return checkPiece(STRUCTURE_PIECE_MAIN, 1, 4, 0)
- && mCasingAmount >= 24
+ return checkPiece(STRUCTURE_PIECE_MAIN, 1, 4, 0) && mCasingAmount >= 24
&& mFireboxAmount >= 3
&& mMaintenanceHatches.size() == 1
&& !mMufflerHatches.isEmpty();
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Bronze.java
index 970000da11..2effcf7966 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Bronze.java
@@ -1,10 +1,11 @@
package gregtech.common.tileentities.machines.multi;
+import net.minecraft.block.Block;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_LargeBoiler_Bronze extends GT_MetaTileEntity_LargeBoiler {
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Steel.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Steel.java
index bc30228b3a..c7bd766945 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Steel.java
@@ -1,12 +1,14 @@
package gregtech.common.tileentities.machines.multi;
+import net.minecraft.block.Block;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_LargeBoiler_Steel extends GT_MetaTileEntity_LargeBoiler {
+
public GT_MetaTileEntity_LargeBoiler_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
pollutionPerSecond = GT_Mod.gregtechproxy.mPollutionLargeSteelBoilerPerSecond;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Titanium.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Titanium.java
index bda83f7210..61f2756622 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Titanium.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_Titanium.java
@@ -1,12 +1,14 @@
package gregtech.common.tileentities.machines.multi;
+import net.minecraft.block.Block;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_LargeBoiler_Titanium extends GT_MetaTileEntity_LargeBoiler {
+
public GT_MetaTileEntity_LargeBoiler_Titanium(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
pollutionPerSecond = GT_Mod.gregtechproxy.mPollutionLargeTitaniumBoilerPerSecond;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_TungstenSteel.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_TungstenSteel.java
index 3b73b4f407..f00ea287b2 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_TungstenSteel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeBoiler_TungstenSteel.java
@@ -1,12 +1,14 @@
package gregtech.common.tileentities.machines.multi;
+import net.minecraft.block.Block;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import net.minecraft.block.Block;
public class GT_MetaTileEntity_LargeBoiler_TungstenSteel extends GT_MetaTileEntity_LargeBoiler {
+
public GT_MetaTileEntity_LargeBoiler_TungstenSteel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
pollutionPerSecond = GT_Mod.gregtechproxy.mPollutionLargeTungstenSteelBoilerPerSecond;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeChemicalReactor.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeChemicalReactor.java
index ce1031e284..a6739e6fa2 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeChemicalReactor.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeChemicalReactor.java
@@ -7,10 +7,23 @@ import static gregtech.api.enums.GT_HatchElement.*;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
+import java.util.ArrayList;
+import java.util.function.Consumer;
+import java.util.stream.Collectors;
+import java.util.stream.IntStream;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.IChatComponent;
+import net.minecraft.world.World;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.StructureLibAPI;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.*;
import com.gtnewhorizon.structurelib.util.ItemStackPredicate;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.HeatingCoilLevel;
import gregtech.api.interfaces.IHeatingCoil;
@@ -23,51 +36,39 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Single_Recipe_Check;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.function.Consumer;
-import java.util.stream.Collectors;
-import java.util.stream.IntStream;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.IChatComponent;
-import net.minecraft.world.World;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_LargeChemicalReactor
extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_LargeChemicalReactor>
implements ISurvivalConstructable {
+
private static final int CASING_INDEX = 176;
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_LargeChemicalReactor> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_LargeChemicalReactor>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {"ccc", "cxc", "ccc"},
- {"c~c", "xPx", "cxc"},
- {"ccc", "cxc", "ccc"},
- }))
- .addElement('P', ofBlock(GregTech_API.sBlockCasings8, 1))
- .addElement(
- 'c',
- buildHatchAdder(GT_MetaTileEntity_LargeChemicalReactor.class)
- .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Maintenance, Energy)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .buildAndChain(onElementPass(
+ private static final IStructureDefinition<GT_MetaTileEntity_LargeChemicalReactor> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_LargeChemicalReactor>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "ccc", "cxc", "ccc" }, { "c~c", "xPx", "cxc" },
+ { "ccc", "cxc", "ccc" }, }))
+ .addElement('P', ofBlock(GregTech_API.sBlockCasings8, 1))
+ .addElement(
+ 'c',
+ buildHatchAdder(GT_MetaTileEntity_LargeChemicalReactor.class)
+ .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Maintenance, Energy)
+ .casingIndex(CASING_INDEX).dot(1).buildAndChain(
+ onElementPass(
GT_MetaTileEntity_LargeChemicalReactor::onCasingAdded,
ofBlock(GregTech_API.sBlockCasings8, 0))))
- .addElement(
- 'x',
- buildHatchAdder(GT_MetaTileEntity_LargeChemicalReactor.class)
- .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Maintenance, Energy)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .buildAndChain(
- CoilStructureElement.INSTANCE,
- onElementPass(
- GT_MetaTileEntity_LargeChemicalReactor::onCasingAdded,
- ofBlock(GregTech_API.sBlockCasings8, 0))))
- .build();
+ .addElement(
+ 'x',
+ buildHatchAdder(GT_MetaTileEntity_LargeChemicalReactor.class)
+ .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Maintenance, Energy)
+ .casingIndex(CASING_INDEX).dot(1).buildAndChain(
+ CoilStructureElement.INSTANCE,
+ onElementPass(
+ GT_MetaTileEntity_LargeChemicalReactor::onCasingAdded,
+ ofBlock(GregTech_API.sBlockCasings8, 0))))
+ .build();
private int mCasingAmount;
private int mCoilAmount;
@@ -88,63 +89,33 @@ public class GT_MetaTileEntity_LargeChemicalReactor
@Override
public GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Chemical Reactor")
- .addInfo("Controller block for the Large Chemical Reactor")
- .addInfo("Does not lose efficiency when overclocked")
- .addInfo("Accepts fluids instead of fluid cells")
- .addSeparator()
- .beginStructureBlock(3, 3, 3, false)
- .addController("Front center")
+ tt.addMachineType("Chemical Reactor").addInfo("Controller block for the Large Chemical Reactor")
+ .addInfo("Does not lose efficiency when overclocked").addInfo("Accepts fluids instead of fluid cells")
+ .addSeparator().beginStructureBlock(3, 3, 3, false).addController("Front center")
.addCasingInfo("Chemically Inert Machine Casing", 8)
.addOtherStructurePart("PTFE Pipe Machine Casing", "Center")
.addOtherStructurePart("Heating Coil", "Adjacent to the PTFE Pipe Machine Casing", 1)
- .addEnergyHatch("Any casing", 1, 2)
- .addMaintenanceHatch("Any casing", 1, 2)
- .addInputBus("Any casing", 1, 2)
- .addInputHatch("Any casing", 1, 2)
- .addOutputBus("Any casing", 1, 2)
- .addOutputHatch("Any casing", 1, 2)
- .addStructureInfo("You can have multiple hatches/busses")
+ .addEnergyHatch("Any casing", 1, 2).addMaintenanceHatch("Any casing", 1, 2)
+ .addInputBus("Any casing", 1, 2).addInputHatch("Any casing", 1, 2).addOutputBus("Any casing", 1, 2)
+ .addOutputHatch("Any casing", 1, 2).addStructureInfo("You can have multiple hatches/busses")
.toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[1][48],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[1][48],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[1][48],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_ACTIVE_GLOW).extFacing()
+ .glow().build() };
+ return new ITexture[] { casingTexturePages[1][48],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_LARGE_CHEMICAL_REACTOR_GLOW).extFacing().glow()
+ .build() };
}
- return new ITexture[] {casingTexturePages[1][48]};
+ return new ITexture[] { casingTexturePages[1][48] };
}
@Override
@@ -187,15 +158,19 @@ public class GT_MetaTileEntity_LargeChemicalReactor
}
tRecipe = GT_Recipe.GT_Recipe_Map.sMultiblockChemicalRecipes.findRecipe(
- getBaseMetaTileEntity(), false, false, gregtech.api.enums.GT_Values.V[tier], fluids, inputs);
+ getBaseMetaTileEntity(),
+ false,
+ false,
+ gregtech.api.enums.GT_Values.V[tier],
+ fluids,
+ inputs);
if (tRecipe == null || !tRecipe.isRecipeInputEqual(true, fluids, inputs)) {
return false;
}
if (mLockedToSingleRecipe) {
- mSingleRecipeCheck =
- tSingleRecipeCheckBuilder.setAfter().setRecipe(tRecipe).build();
+ mSingleRecipeCheck = tSingleRecipeCheckBuilder.setAfter().setRecipe(tRecipe).build();
}
}
@@ -232,8 +207,7 @@ public class GT_MetaTileEntity_LargeChemicalReactor
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
mCasingAmount = 0;
mCoilAmount = 0;
- return checkPiece(STRUCTURE_PIECE_MAIN, 1, 1, 0)
- && mCasingAmount >= 8
+ return checkPiece(STRUCTURE_PIECE_MAIN, 1, 1, 0) && mCasingAmount >= 8
&& mCoilAmount == 1
&& !mEnergyHatches.isEmpty()
&& mMaintenanceHatches.size() == 1;
@@ -268,6 +242,7 @@ public class GT_MetaTileEntity_LargeChemicalReactor
}
private enum CoilStructureElement implements IStructureElement<GT_MetaTileEntity_LargeChemicalReactor> {
+
INSTANCE;
@Override
@@ -282,15 +257,15 @@ public class GT_MetaTileEntity_LargeChemicalReactor
}
@Override
- public boolean spawnHint(
- GT_MetaTileEntity_LargeChemicalReactor t, World world, int x, int y, int z, ItemStack trigger) {
+ public boolean spawnHint(GT_MetaTileEntity_LargeChemicalReactor t, World world, int x, int y, int z,
+ ItemStack trigger) {
StructureLibAPI.hintParticle(world, x, y, z, GregTech_API.sBlockCasings5, 0);
return true;
}
@Override
- public boolean placeBlock(
- GT_MetaTileEntity_LargeChemicalReactor t, World world, int x, int y, int z, ItemStack trigger) {
+ public boolean placeBlock(GT_MetaTileEntity_LargeChemicalReactor t, World world, int x, int y, int z,
+ ItemStack trigger) {
if (t.mCoilAmount > 0) return false;
boolean b = world.setBlock(x, y, z, GregTech_API.sBlockCasings5, 0, 3);
if (b) t.mCoilAmount++;
@@ -298,42 +273,23 @@ public class GT_MetaTileEntity_LargeChemicalReactor
}
@Override
- public PlaceResult survivalPlaceBlock(
- GT_MetaTileEntity_LargeChemicalReactor t,
- World world,
- int x,
- int y,
- int z,
- ItemStack trigger,
- IItemSource s,
- EntityPlayerMP actor,
- Consumer<IChatComponent> chatter) {
+ public PlaceResult survivalPlaceBlock(GT_MetaTileEntity_LargeChemicalReactor t, World world, int x, int y,
+ int z, ItemStack trigger, IItemSource s, EntityPlayerMP actor, Consumer<IChatComponent> chatter) {
return survivalPlaceBlock(t, world, x, y, z, trigger, AutoPlaceEnvironment.fromLegacy(s, actor, chatter));
}
@Override
public BlocksToPlace getBlocksToPlace(
- GT_MetaTileEntity_LargeChemicalReactor gt_metaTileEntity_largeChemicalReactor,
- World world,
- int x,
- int y,
- int z,
- ItemStack trigger,
- AutoPlaceEnvironment env) {
- return BlocksToPlace.create(IntStream.range(0, 8)
- .mapToObj(i -> new ItemStack(GregTech_API.sBlockCasings5, 1, i))
- .collect(Collectors.toList()));
+ GT_MetaTileEntity_LargeChemicalReactor gt_metaTileEntity_largeChemicalReactor, World world, int x,
+ int y, int z, ItemStack trigger, AutoPlaceEnvironment env) {
+ return BlocksToPlace.create(
+ IntStream.range(0, 8).mapToObj(i -> new ItemStack(GregTech_API.sBlockCasings5, 1, i))
+ .collect(Collectors.toList()));
}
@Override
- public PlaceResult survivalPlaceBlock(
- GT_MetaTileEntity_LargeChemicalReactor t,
- World world,
- int x,
- int y,
- int z,
- ItemStack trigger,
- AutoPlaceEnvironment env) {
+ public PlaceResult survivalPlaceBlock(GT_MetaTileEntity_LargeChemicalReactor t, World world, int x, int y,
+ int z, ItemStack trigger, AutoPlaceEnvironment env) {
if (t.mCoilAmount > 0) return PlaceResult.SKIP;
if (check(t, world, x, y, z)) return PlaceResult.SKIP;
if (!StructureLibAPI.isBlockTriviallyReplaceable(world, x, y, z, env.getActor())) return PlaceResult.REJECT;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java
index 84e6ab520c..0f700950f2 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java
@@ -9,11 +9,25 @@ import static gregtech.api.enums.Textures.BlockIcons.TURBINE_NEW_ACTIVE;
import static gregtech.api.enums.Textures.BlockIcons.TURBINE_NEW_EMPTY;
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.client.renderer.RenderBlocks;
+import net.minecraft.client.renderer.Tessellator;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.IBlockAccess;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.alignment.enumerable.ExtendedFacing;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.enums.Dyes;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
@@ -25,54 +39,36 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.LightingHelper;
import gregtech.common.items.GT_MetaGenerated_Tool_01;
import gregtech.common.render.GT_RenderUtil;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.client.renderer.RenderBlocks;
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.IBlockAccess;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
-public abstract class GT_MetaTileEntity_LargeTurbine
- extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_LargeTurbine>
- implements ISurvivalConstructable {
+public abstract class GT_MetaTileEntity_LargeTurbine extends
+ GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_LargeTurbine> implements ISurvivalConstructable {
+
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeTurbine>> STRUCTURE_DEFINITION =
- new ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeTurbine>>() {
- @Override
- protected IStructureDefinition<GT_MetaTileEntity_LargeTurbine> computeValue(Class<?> type) {
- return StructureDefinition.<GT_MetaTileEntity_LargeTurbine>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {
- " ", " ", " ", " ", " ",
- },
- {
- " --- ", " ccc ", " hhh ", " hhh ", " hhh ",
- },
- {
- " --- ", " c~c ", " h-h ", " h-h ", " hdh ",
- },
- {
- " --- ", " ccc ", " hhh ", " hhh ", " hhh ",
- },
- {
- " ", " ", " ", " ", " ",
- },
- }))
- .addElement('c', lazy(t -> ofBlock(t.getCasingBlock(), t.getCasingMeta())))
- .addElement('d', lazy(t -> Dynamo.newAny(t.getCasingTextureIndex(), 1)))
- .addElement('h', lazy(t -> buildHatchAdder(GT_MetaTileEntity_LargeTurbine.class)
- .atLeast(Maintenance, InputHatch, OutputHatch, OutputBus, InputBus, Muffler)
- .casingIndex(t.getCasingTextureIndex())
- .dot(2)
- .buildAndChain(t.getCasingBlock(), t.getCasingMeta())))
- .build();
- }
- };
+ private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeTurbine>> STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_LargeTurbine>>() {
+
+ @Override
+ protected IStructureDefinition<GT_MetaTileEntity_LargeTurbine> computeValue(Class<?> type) {
+ return StructureDefinition.<GT_MetaTileEntity_LargeTurbine>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { " ", " ", " ", " ", " ", },
+ { " --- ", " ccc ", " hhh ", " hhh ", " hhh ", },
+ { " --- ", " c~c ", " h-h ", " h-h ", " hdh ", },
+ { " --- ", " ccc ", " hhh ", " hhh ", " hhh ", },
+ { " ", " ", " ", " ", " ", }, }))
+ .addElement('c', lazy(t -> ofBlock(t.getCasingBlock(), t.getCasingMeta())))
+ .addElement('d', lazy(t -> Dynamo.newAny(t.getCasingTextureIndex(), 1)))
+ .addElement(
+ 'h',
+ lazy(
+ t -> buildHatchAdder(GT_MetaTileEntity_LargeTurbine.class)
+ .atLeast(Maintenance, InputHatch, OutputHatch, OutputBus, InputBus, Muffler)
+ .casingIndex(t.getCasingTextureIndex()).dot(2)
+ .buildAndChain(t.getCasingBlock(), t.getCasingMeta())))
+ .build();
+ }
+ };
protected int baseEff = 0;
protected int optFlow = 0;
@@ -81,7 +77,7 @@ public abstract class GT_MetaTileEntity_LargeTurbine
protected int counter = 0;
protected boolean looseFit = false;
protected int overflowMultiplier = 0;
- protected float[] flowMultipliers = new float[] {1, 1, 1};
+ protected float[] flowMultipliers = new float[] { 1, 1, 1 };
// client side stuff
protected boolean mHasTurbine;
@@ -106,8 +102,7 @@ public abstract class GT_MetaTileEntity_LargeTurbine
@Override
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
- return checkPiece(STRUCTURE_PIECE_MAIN, 2, 2, 1)
- && mMaintenanceHatches.size() == 1
+ return checkPiece(STRUCTURE_PIECE_MAIN, 2, 2, 1) && mMaintenanceHatches.size() == 1
&& mMufflerHatches.isEmpty() == (getPollutionPerTick(null) == 0);
}
@@ -136,7 +131,7 @@ public abstract class GT_MetaTileEntity_LargeTurbine
@Override
public boolean renderInWorld(IBlockAccess aWorld, int aX, int aY, int aZ, Block aBlock, RenderBlocks aRenderer) {
if (!isNewStyleRendering() || !mMachine) return false;
- int[] tABCCoord = new int[] {-1, -1, 0};
+ int[] tABCCoord = new int[] { -1, -1, 0 };
int[] tXYZOffset = new int[3];
byte tFacing = getBaseMetaTileEntity().getFrontFacing();
ExtendedFacing tExtendedFacing = getExtendedFacing();
@@ -163,8 +158,12 @@ public abstract class GT_MetaTileEntity_LargeTurbine
int tZ = tXYZOffset[2] + aZ;
// we skip the occlusion test, as we always require a working turbine to have a block of air before it
// so the front face cannot be occluded whatsoever in the most cases.
- Tessellator.instance.setBrightness(tBlock.getMixedBrightnessForBlock(
- aWorld, aX + tDirection.offsetX, tY + tDirection.offsetY, aZ + tDirection.offsetZ));
+ Tessellator.instance.setBrightness(
+ tBlock.getMixedBrightnessForBlock(
+ aWorld,
+ aX + tDirection.offsetX,
+ tY + tDirection.offsetY,
+ aZ + tDirection.offsetZ));
tLighting.setupLighting(tBlock, tX, tY, tZ, tFacing).setupColor(tFacing, Dyes._NULL.mRGBa);
GT_RenderUtil.renderBlockIcon(
aRenderer,
@@ -217,32 +216,28 @@ public abstract class GT_MetaTileEntity_LargeTurbine
@Override
public boolean checkRecipe(ItemStack aStack) {
- if ((counter & 7) == 0
- && (aStack == null
- || !(aStack.getItem() instanceof GT_MetaGenerated_Tool)
- || aStack.getItemDamage() < 170
- || aStack.getItemDamage() > 179)) {
+ if ((counter & 7) == 0 && (aStack == null || !(aStack.getItem() instanceof GT_MetaGenerated_Tool)
+ || aStack.getItemDamage() < 170
+ || aStack.getItemDamage() > 179)) {
stopMachine();
return false;
}
ArrayList<FluidStack> tFluids = getStoredFluids();
if (!tFluids.isEmpty()) {
- if (baseEff == 0
- || optFlow == 0
+ if (baseEff == 0 || optFlow == 0
|| counter >= 512
|| this.getBaseMetaTileEntity().hasWorkJustBeenEnabled()
|| this.getBaseMetaTileEntity().hasInventoryBeenModified()) {
counter = 0;
baseEff = GT_Utility.safeInt(
(long) ((5F + ((GT_MetaGenerated_Tool) aStack.getItem()).getToolCombatDamage(aStack)) * 1000F));
- optFlow = GT_Utility.safeInt((long) Math.max(
- Float.MIN_NORMAL,
- ((GT_MetaGenerated_Tool) aStack.getItem())
- .getToolStats(aStack)
- .getSpeedMultiplier()
- * GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mToolSpeed
- * 50));
+ optFlow = GT_Utility.safeInt(
+ (long) Math.max(
+ Float.MIN_NORMAL,
+ ((GT_MetaGenerated_Tool) aStack.getItem()).getToolStats(aStack).getSpeedMultiplier()
+ * GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mToolSpeed
+ * 50));
overflowMultiplier = getOverflowMultiplier(aStack);
@@ -259,12 +254,10 @@ public abstract class GT_MetaTileEntity_LargeTurbine
}
}
- int newPower = fluidIntoPower(
- tFluids,
- optFlow,
- baseEff,
- overflowMultiplier,
- flowMultipliers); // How much the turbine should be producing with this flow
+ int newPower = fluidIntoPower(tFluids, optFlow, baseEff, overflowMultiplier, flowMultipliers); // How much the
+ // turbine should
+ // be producing
+ // with this flow
int difference = newPower - this.mEUt; // difference between current output and new output
// Magic numbers: can always change by at least 10 eu/t, but otherwise by at most 1 percent of the difference in
@@ -285,13 +278,13 @@ public abstract class GT_MetaTileEntity_LargeTurbine
} else {
this.mMaxProgresstime = 1;
this.mEfficiencyIncrease = 10;
- // Overvoltage is handled inside the MultiBlockBase when pushing out to dynamos. no need to do it here.
+ // Overvoltage is handled inside the MultiBlockBase when pushing out to dynamos. no need to do it here.
return true;
}
}
- abstract int fluidIntoPower(
- ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowMultiplier, float[] flowMultipliers);
+ abstract int fluidIntoPower(ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowMultiplier,
+ float[] flowMultipliers);
abstract float getOverflowEfficiency(int totalFlow, int actualOptimalFlow, int overflowMultiplier);
@@ -351,26 +344,21 @@ public abstract class GT_MetaTileEntity_LargeTurbine
}
String tRunning = mMaxProgresstime > 0
- ? EnumChatFormatting.GREEN
- + StatCollector.translateToLocal("GT5U.turbine.running.true")
+ ? EnumChatFormatting.GREEN + StatCollector.translateToLocal("GT5U.turbine.running.true")
+ EnumChatFormatting.RESET
- : EnumChatFormatting.RED
- + StatCollector.translateToLocal("GT5U.turbine.running.false")
+ : EnumChatFormatting.RED + StatCollector.translateToLocal("GT5U.turbine.running.false")
+ EnumChatFormatting.RESET;
String tMaintainance = getIdealStatus() == getRepairStatus()
- ? EnumChatFormatting.GREEN
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
+ ? EnumChatFormatting.GREEN + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
+ EnumChatFormatting.RESET
- : EnumChatFormatting.RED
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
+ : EnumChatFormatting.RED + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
+ EnumChatFormatting.RESET;
int tDura = 0;
if (mInventory[1] != null && mInventory[1].getItem() instanceof GT_MetaGenerated_Tool_01) {
- tDura = GT_Utility.safeInt((long) (100.0f
- / GT_MetaGenerated_Tool.getToolMaxDamage(mInventory[1])
- * (GT_MetaGenerated_Tool.getToolDamage(mInventory[1]))
- + 1));
+ tDura = GT_Utility.safeInt(
+ (long) (100.0f / GT_MetaGenerated_Tool.getToolMaxDamage(mInventory[1])
+ * (GT_MetaGenerated_Tool.getToolDamage(mInventory[1])) + 1));
}
long storedEnergy = 0;
@@ -382,40 +370,64 @@ public abstract class GT_MetaTileEntity_LargeTurbine
}
}
String[] ret = new String[] {
- // 8 Lines available for information panels
- tRunning + ": " + EnumChatFormatting.RED + GT_Utility.formatNumbers(((long) mEUt * mEfficiency) / 10000)
- + EnumChatFormatting.RESET + " EU/t", /* 1 */
- tMaintainance, /* 2 */
- StatCollector.translateToLocal("GT5U.turbine.efficiency") + ": " + EnumChatFormatting.YELLOW
- + (mEfficiency / 100F) + EnumChatFormatting.RESET + "%", /* 2 */
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + /* 3 */ EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.turbine.flow") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(GT_Utility.safeInt((long) realOptFlow)) + EnumChatFormatting.RESET
- + " L/t" + /* 4 */ EnumChatFormatting.YELLOW
- + " ("
- + (looseFit
- ? StatCollector.translateToLocal("GT5U.turbine.loose")
- : StatCollector.translateToLocal("GT5U.turbine.tight"))
- + ")", /* 5 */
- StatCollector.translateToLocal("GT5U.turbine.fuel") + ": " + EnumChatFormatting.GOLD
- + GT_Utility.formatNumbers(storedFluid) + EnumChatFormatting.RESET + "L", /* 6 */
- StatCollector.translateToLocal("GT5U.turbine.dmg") + ": " + EnumChatFormatting.RED + tDura
- + EnumChatFormatting.RESET + "%", /* 7 */
- StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %" /* 8 */
+ // 8 Lines available for information panels
+ tRunning + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(((long) mEUt * mEfficiency) / 10000)
+ + EnumChatFormatting.RESET
+ + " EU/t", /* 1 */
+ tMaintainance, /* 2 */
+ StatCollector.translateToLocal("GT5U.turbine.efficiency") + ": "
+ + EnumChatFormatting.YELLOW
+ + (mEfficiency / 100F)
+ + EnumChatFormatting.RESET
+ + "%", /* 2 */
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + /* 3 */ EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.turbine.flow") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(GT_Utility.safeInt((long) realOptFlow))
+ + EnumChatFormatting.RESET
+ + " L/t"
+ + /* 4 */ EnumChatFormatting.YELLOW
+ + " ("
+ + (looseFit ? StatCollector.translateToLocal("GT5U.turbine.loose")
+ : StatCollector.translateToLocal("GT5U.turbine.tight"))
+ + ")", /* 5 */
+ StatCollector.translateToLocal("GT5U.turbine.fuel") + ": "
+ + EnumChatFormatting.GOLD
+ + GT_Utility.formatNumbers(storedFluid)
+ + EnumChatFormatting.RESET
+ + "L", /* 6 */
+ StatCollector.translateToLocal("GT5U.turbine.dmg") + ": "
+ + EnumChatFormatting.RED
+ + tDura
+ + EnumChatFormatting.RESET
+ + "%", /* 7 */
+ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %" /* 8 */
};
if (!this.getClass().getName().contains("Steam"))
- ret[4] = StatCollector.translateToLocal("GT5U.turbine.flow") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.safeInt((long) realOptFlow) + EnumChatFormatting.RESET + " L/t";
+ ret[4] = StatCollector.translateToLocal("GT5U.turbine.flow") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.safeInt((long) realOptFlow)
+ + EnumChatFormatting.RESET
+ + " L/t";
return ret;
}
public boolean hasTurbine() {
- return getBaseMetaTileEntity() != null && getBaseMetaTileEntity().isClientSide()
- ? mHasTurbine
+ return getBaseMetaTileEntity() != null && getBaseMetaTileEntity().isClientSide() ? mHasTurbine
: this.getMaxEfficiency(mInventory[1]) > 0;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java
index ad56dd7be4..79078febec 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java
@@ -2,6 +2,12 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
@@ -12,10 +18,6 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeTurbine {
@@ -28,49 +30,28 @@ public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeT
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- MACHINE_CASINGS[1][aColorIndex + 1],
- aFacing == aSide
- ? (aActive
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_ACTIVE5)
- .build()
- : hasTurbine()
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW5)
- .build()
- : TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_EMPTY5)
- .build())
- : casingTexturePages[0][58]
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { MACHINE_CASINGS[1][aColorIndex + 1],
+ aFacing == aSide
+ ? (aActive ? TextureFactory.builder().addIcon(LARGETURBINE_NEW_ACTIVE5).build()
+ : hasTurbine() ? TextureFactory.builder().addIcon(LARGETURBINE_NEW5).build()
+ : TextureFactory.builder().addIcon(LARGETURBINE_NEW_EMPTY5).build())
+ : casingTexturePages[0][58] };
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Gas Turbine")
- .addInfo("Controller block for the Large Gas Turbine")
+ tt.addMachineType("Gas Turbine").addInfo("Controller block for the Large Gas Turbine")
.addInfo("Needs a Turbine, place inside controller")
.addInfo("Warning: Will be capped at 8192 EU/t in a future update")
.addInfo("See the Advanced Large Gas Turbine as the next, uncapped, option")
// .addInfo("The excess fuel that gets consumed will be voided!")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 3, 4, true)
- .addController("Front center")
- .addCasingInfo("Stainless Steel Turbine Casing", 24)
- .addDynamoHatch("Back center", 1)
- .addMaintenanceHatch("Side centered", 2)
- .addMufflerHatch("Side centered", 2)
- .addInputHatch("Gas Fuel, Side centered", 2)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 3, 4, true)
+ .addController("Front center").addCasingInfo("Stainless Steel Turbine Casing", 24)
+ .addDynamoHatch("Back center", 1).addMaintenanceHatch("Side centered", 2)
+ .addMufflerHatch("Side centered", 2).addInputHatch("Gas Fuel, Side centered", 2)
.toolTipFinisher("Gregtech");
return tt;
}
@@ -113,19 +94,14 @@ public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeT
}
@Override
- int fluidIntoPower(
- ArrayList<FluidStack> aFluids,
- int aOptFlow,
- int aBaseEff,
- int overflowMultiplier,
+ int fluidIntoPower(ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowMultiplier,
float[] flowMultipliers) {
if (aFluids.size() >= 1) {
int tEU = 0;
int actualOptimalFlow = 0;
- FluidStack firstFuelType = new FluidStack(
- aFluids.get(0),
- 0); // Identify a SINGLE type of fluid to process. Doesn't matter which one. Ignore the rest!
+ FluidStack firstFuelType = new FluidStack(aFluids.get(0), 0); // Identify a SINGLE type of fluid to process.
+ // Doesn't matter which one. Ignore the rest!
int fuelValue = getFuelValue(firstFuelType);
if (aOptFlow < fuelValue) {
@@ -177,9 +153,9 @@ public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeT
// EU/t output cap to properly tier the LGT against the Advanced LGT, will be implemented in a future dev
// update
- /*if (tEU > 8192) {
- tEU = 8192;
- }*/
+ /*
+ * if (tEU > 8192) { tEU = 8192; }
+ */
// If next output is above the maximum the dynamo can handle, set it to the maximum instead of exploding the
// turbine
@@ -203,9 +179,8 @@ public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeT
float efficiency = 0;
if (totalFlow > actualOptimalFlow) {
- efficiency = 1.0f
- - Math.abs((totalFlow - actualOptimalFlow))
- / ((float) actualOptimalFlow * ((overflowMultiplier * 3) - 1));
+ efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow))
+ / ((float) actualOptimalFlow * ((overflowMultiplier * 3) - 1));
} else {
efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow) / (float) actualOptimalFlow);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_GasAdvanced.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_GasAdvanced.java
index 185da58b28..fbad39dd32 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_GasAdvanced.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_GasAdvanced.java
@@ -2,6 +2,12 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
@@ -12,12 +18,9 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_LargeTurbine_GasAdvanced extends GT_MetaTileEntity_LargeTurbine {
+
public GT_MetaTileEntity_LargeTurbine_GasAdvanced(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
@@ -27,49 +30,27 @@ public class GT_MetaTileEntity_LargeTurbine_GasAdvanced extends GT_MetaTileEntit
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- MACHINE_CASINGS[1][aColorIndex + 1],
- aFacing == aSide
- ? (aActive
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_ACTIVE5)
- .build()
- : hasTurbine()
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW5)
- .build()
- : TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_EMPTY5)
- .build())
- : casingTexturePages[1][57]
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { MACHINE_CASINGS[1][aColorIndex + 1],
+ aFacing == aSide
+ ? (aActive ? TextureFactory.builder().addIcon(LARGETURBINE_NEW_ACTIVE5).build()
+ : hasTurbine() ? TextureFactory.builder().addIcon(LARGETURBINE_NEW5).build()
+ : TextureFactory.builder().addIcon(LARGETURBINE_NEW_EMPTY5).build())
+ : casingTexturePages[1][57] };
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Gas Turbine")
- .addInfo("Warning: This is an experimental multiblock, subject to changes ")
+ tt.addMachineType("Gas Turbine").addInfo("Warning: This is an experimental multiblock, subject to changes ")
.addInfo("Controller block for the Large Advanced Gas Turbine")
- .addInfo("Needs a Turbine, place inside controller")
- .addInfo("Only accepts gases above 800k EU/bucket")
+ .addInfo("Needs a Turbine, place inside controller").addInfo("Only accepts gases above 800k EU/bucket")
.addInfo("Has no maximum EU/t output, only depends on the Dynamo Hatch")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 3, 4, true)
- .addController("Front center")
- .addCasingInfo("Advanced Gas Turbine Casing", 24)
- .addDynamoHatch("Back center", 1)
- .addMaintenanceHatch("Side centered", 2)
- .addMufflerHatch("Side centered", 2)
- .addInputHatch("Gas Fuel, Side centered", 2)
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 3, 4, true)
+ .addController("Front center").addCasingInfo("Advanced Gas Turbine Casing", 24)
+ .addDynamoHatch("Back center", 1).addMaintenanceHatch("Side centered", 2)
+ .addMufflerHatch("Side centered", 2).addInputHatch("Gas Fuel, Side centered", 2)
.toolTipFinisher("Gregtech");
return tt;
}
@@ -112,19 +93,14 @@ public class GT_MetaTileEntity_LargeTurbine_GasAdvanced extends GT_MetaTileEntit
}
@Override
- int fluidIntoPower(
- ArrayList<FluidStack> aFluids,
- int aOptFlow,
- int aBaseEff,
- int overflowMultiplier,
+ int fluidIntoPower(ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowMultiplier,
float[] flowMultipliers) {
if (aFluids.size() >= 1) {
int tEU = 0;
int actualOptimalFlow = 0;
- FluidStack firstFuelType = new FluidStack(
- aFluids.get(0),
- 0); // Identify a SINGLE type of fluid to process. Doesn't matter which one. Ignore the rest!
+ FluidStack firstFuelType = new FluidStack(aFluids.get(0), 0); // Identify a SINGLE type of fluid to process.
+ // Doesn't matter which one. Ignore the rest!
int fuelValue = getFuelValue(firstFuelType);
if (fuelValue < 100) {
@@ -200,9 +176,8 @@ public class GT_MetaTileEntity_LargeTurbine_GasAdvanced extends GT_MetaTileEntit
float efficiency = 0;
if (totalFlow > actualOptimalFlow) {
- efficiency = 1.0f
- - Math.abs((totalFlow - actualOptimalFlow))
- / ((float) actualOptimalFlow * ((overflowMultiplier * 3) - 1));
+ efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow))
+ / ((float) actualOptimalFlow * ((overflowMultiplier * 3) - 1));
} else {
efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow) / (float) actualOptimalFlow);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java
index 779de1a17a..a28c28518c 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java
@@ -4,6 +4,14 @@ import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
import static gregtech.common.tileentities.machines.multi.GT_MetaTileEntity_LargeTurbine_Steam.calculateLooseFlow;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
@@ -13,12 +21,6 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_LargeTurbine {
@@ -34,49 +36,27 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- MACHINE_CASINGS[1][aColorIndex + 1],
- aFacing == aSide
- ? (aActive
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_ACTIVE5)
- .build()
- : hasTurbine()
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW5)
- .build()
- : TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_EMPTY5)
- .build())
- : casingTexturePages[0][59]
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { MACHINE_CASINGS[1][aColorIndex + 1],
+ aFacing == aSide
+ ? (aActive ? TextureFactory.builder().addIcon(LARGETURBINE_NEW_ACTIVE5).build()
+ : hasTurbine() ? TextureFactory.builder().addIcon(LARGETURBINE_NEW5).build()
+ : TextureFactory.builder().addIcon(LARGETURBINE_NEW_EMPTY5).build())
+ : casingTexturePages[0][59] };
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Steam Turbine")
- .addInfo("Controller block for the Large High Pressure Steam Turbine")
- .addInfo("Needs a Turbine, place inside controller")
- .addInfo("Outputs Steam as well as producing power")
+ tt.addMachineType("Steam Turbine").addInfo("Controller block for the Large High Pressure Steam Turbine")
+ .addInfo("Needs a Turbine, place inside controller").addInfo("Outputs Steam as well as producing power")
.addInfo("Power output depends on turbine and fitting")
- .addInfo("Use screwdriver to adjust fitting of turbine")
- .addSeparator()
- .beginStructureBlock(3, 3, 4, true)
- .addController("Front center")
- .addCasingInfo("Titanium Turbine Casing", 24)
- .addDynamoHatch("Back center", 1)
- .addMaintenanceHatch("Side centered", 2)
- .addInputHatch("Superheated Steam, Side centered", 2)
- .addOutputHatch("Steam, Side centered", 2)
- .toolTipFinisher("Gregtech");
+ .addInfo("Use screwdriver to adjust fitting of turbine").addSeparator()
+ .beginStructureBlock(3, 3, 4, true).addController("Front center")
+ .addCasingInfo("Titanium Turbine Casing", 24).addDynamoHatch("Back center", 1)
+ .addMaintenanceHatch("Side centered", 2).addInputHatch("Superheated Steam, Side centered", 2)
+ .addOutputHatch("Steam, Side centered", 2).toolTipFinisher("Gregtech");
return tt;
}
@@ -106,11 +86,7 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La
}
@Override
- int fluidIntoPower(
- ArrayList<FluidStack> aFluids,
- int aOptFlow,
- int aBaseEff,
- int overflowEfficiency,
+ int fluidIntoPower(ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowEfficiency,
float[] flowMultipliers) {
if (looseFit) {
long[] calculatedFlow = calculateLooseFlow(aOptFlow, aBaseEff);
@@ -145,13 +121,10 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La
if (!achievement) {
try {
GT_Mod.achievements.issueAchievement(
- this.getBaseMetaTileEntity()
- .getWorld()
- .getPlayerEntityByName(
- this.getBaseMetaTileEntity().getOwnerName()),
+ this.getBaseMetaTileEntity().getWorld()
+ .getPlayerEntityByName(this.getBaseMetaTileEntity().getOwnerName()),
"efficientsteam");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
achievement = true;
}
} else if (GT_ModHandler.isAnySteam(aFluidStack)) {
@@ -164,8 +137,10 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La
if (totalFlow == (GT_Utility.safeInt((long) realOptFlow))) {
tEU = GT_Utility.safeInt((long) tEU * (long) aBaseEff / 10000L);
} else {
- float efficiency =
- getOverflowEfficiency(totalFlow, (GT_Utility.safeInt((long) realOptFlow)), overflowMultiplier);
+ float efficiency = getOverflowEfficiency(
+ totalFlow,
+ (GT_Utility.safeInt((long) realOptFlow)),
+ overflowMultiplier);
tEU *= efficiency;
tEU = Math.max(1, GT_Utility.safeInt((long) tEU * (long) aBaseEff / 10000L));
}
@@ -192,9 +167,8 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La
float efficiency = 0;
if (totalFlow > actualOptimalFlow) {
- efficiency = 1.0f
- - Math.abs((totalFlow - actualOptimalFlow))
- / ((float) actualOptimalFlow * (overflowMultiplier + 2));
+ efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow))
+ / ((float) actualOptimalFlow * (overflowMultiplier + 2));
} else {
efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow) / (float) actualOptimalFlow);
}
@@ -208,8 +182,7 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La
looseFit ^= true;
GT_Utility.sendChatToPlayer(
aPlayer,
- looseFit
- ? GT_Utility.trans("500", "Fitting: Loose - More Flow")
+ looseFit ? GT_Utility.trans("500", "Fitting: Loose - More Flow")
: GT_Utility.trans("501", "Fitting: Tight - More Efficiency"));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java
index 272a3ddcc1..5479d277e2 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java
@@ -2,6 +2,15 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -15,13 +24,6 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import gregtech.api.util.GT_Utility;
import gregtech.common.items.GT_MetaGenerated_Tool_01;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_LargeTurbine {
@@ -34,47 +36,26 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- MACHINE_CASINGS[1][aColorIndex + 1],
- aFacing == aSide
- ? (aActive
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_ACTIVE5)
- .build()
- : hasTurbine()
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW5)
- .build()
- : TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_EMPTY5)
- .build())
- : casingTexturePages[0][60]
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { MACHINE_CASINGS[1][aColorIndex + 1],
+ aFacing == aSide
+ ? (aActive ? TextureFactory.builder().addIcon(LARGETURBINE_NEW_ACTIVE5).build()
+ : hasTurbine() ? TextureFactory.builder().addIcon(LARGETURBINE_NEW5).build()
+ : TextureFactory.builder().addIcon(LARGETURBINE_NEW_EMPTY5).build())
+ : casingTexturePages[0][60] };
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Plasma Turbine")
- .addInfo("Controller block for the Large Plasma Generator")
+ tt.addMachineType("Plasma Turbine").addInfo("Controller block for the Large Plasma Generator")
.addInfo("Needs a Turbine, place inside controller")
- .addInfo("Use your Fusion Reactor to produce the Plasma")
- .addSeparator()
- .beginStructureBlock(3, 3, 4, true)
- .addController("Front center")
- .addCasingInfo("Tungstensteel Turbine Casing", 24)
- .addDynamoHatch("Back center", 1)
- .addMaintenanceHatch("Side centered", 2)
- .addInputHatch("Plasma Fluid, Side centered", 2)
- .addOutputHatch("Molten Fluid, optional, Side centered", 2)
- .toolTipFinisher("Gregtech");
+ .addInfo("Use your Fusion Reactor to produce the Plasma").addSeparator()
+ .beginStructureBlock(3, 3, 4, true).addController("Front center")
+ .addCasingInfo("Tungstensteel Turbine Casing", 24).addDynamoHatch("Back center", 1)
+ .addMaintenanceHatch("Side centered", 2).addInputHatch("Plasma Fluid, Side centered", 2)
+ .addOutputHatch("Molten Fluid, optional, Side centered", 2).toolTipFinisher("Gregtech");
return tt;
}
@@ -111,11 +92,7 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
}
@Override
- int fluidIntoPower(
- ArrayList<FluidStack> aFluids,
- int aOptFlow,
- int aBaseEff,
- int overflowMultiplier,
+ int fluidIntoPower(ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowMultiplier,
float[] flowMultipliers) {
if (aFluids.size() >= 1) {
aOptFlow *= 800; // CHANGED THINGS HERE, check recipe runs once per 20 ticks
@@ -123,12 +100,11 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
int actualOptimalFlow = 0;
- FluidStack firstFuelType = new FluidStack(
- aFluids.get(0),
- 0); // Identify a SINGLE type of fluid to process. Doesn't matter which one. Ignore the rest!
+ FluidStack firstFuelType = new FluidStack(aFluids.get(0), 0); // Identify a SINGLE type of fluid to process.
+ // Doesn't matter which one. Ignore the rest!
int fuelValue = getFuelValue(firstFuelType);
- actualOptimalFlow =
- GT_Utility.safeInt((long) Math.ceil((double) aOptFlow * flowMultipliers[2] / (double) fuelValue));
+ actualOptimalFlow = GT_Utility
+ .safeInt((long) Math.ceil((double) aOptFlow * flowMultipliers[2] / (double) fuelValue));
this.realOptFlow = actualOptimalFlow; // For scanner info
// Allowed to use up to 550% optimal flow rate, depending on the value of overflowMultiplier.
@@ -202,9 +178,8 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
float efficiency = 0;
if (totalFlow > actualOptimalFlow) {
- efficiency = 1.0f
- - Math.abs((totalFlow - actualOptimalFlow))
- / ((float) actualOptimalFlow * ((overflowMultiplier * 3) + 1));
+ efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow))
+ / ((float) actualOptimalFlow * ((overflowMultiplier * 3) + 1));
} else {
efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow) / (float) actualOptimalFlow);
}
@@ -214,31 +189,28 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
@Override
public boolean checkRecipe(ItemStack aStack) {
- if ((counter & 7) == 0
- && (aStack == null
- || !(aStack.getItem() instanceof GT_MetaGenerated_Tool)
- || aStack.getItemDamage() < 170
- || aStack.getItemDamage() > 179)) {
+ if ((counter & 7) == 0 && (aStack == null || !(aStack.getItem() instanceof GT_MetaGenerated_Tool)
+ || aStack.getItemDamage() < 170
+ || aStack.getItemDamage() > 179)) {
stopMachine();
return false;
}
ArrayList<FluidStack> tFluids = getStoredFluids();
if (!tFluids.isEmpty()) {
- if (baseEff == 0
- || optFlow == 0
+ if (baseEff == 0 || optFlow == 0
|| counter >= 512
|| this.getBaseMetaTileEntity().hasWorkJustBeenEnabled()
|| this.getBaseMetaTileEntity().hasInventoryBeenModified()) {
counter = 0;
baseEff = GT_Utility.safeInt(
(long) ((5F + ((GT_MetaGenerated_Tool) aStack.getItem()).getToolCombatDamage(aStack)) * 1000F));
- optFlow = GT_Utility.safeInt((long) Math.max(
- Float.MIN_NORMAL,
- ((GT_MetaGenerated_Tool) aStack.getItem())
- .getToolStats(aStack)
- .getSpeedMultiplier()
- * ((GT_MetaGenerated_Tool) aStack.getItem()).getPrimaryMaterial(aStack).mToolSpeed
- * 50));
+ optFlow = GT_Utility.safeInt(
+ (long) Math.max(
+ Float.MIN_NORMAL,
+ ((GT_MetaGenerated_Tool) aStack.getItem()).getToolStats(aStack).getSpeedMultiplier()
+ * ((GT_MetaGenerated_Tool) aStack.getItem())
+ .getPrimaryMaterial(aStack).mToolSpeed
+ * 50));
overflowMultiplier = getOverflowMultiplier(aStack);
flowMultipliers[0] = GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mSteamMultiplier;
@@ -254,12 +226,10 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
return false;
}
- int newPower = fluidIntoPower(
- tFluids,
- optFlow,
- baseEff,
- overflowMultiplier,
- flowMultipliers); // How much the turbine should be producing with this flow
+ int newPower = fluidIntoPower(tFluids, optFlow, baseEff, overflowMultiplier, flowMultipliers); // How much the
+ // turbine should
+ // be producing
+ // with this flow
int difference = newPower - this.mEUt; // difference between current output and new output
@@ -281,7 +251,7 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
} else {
this.mMaxProgresstime = 20;
this.mEfficiencyIncrease = 200;
- // Overvoltage is handled inside the MultiBlockBase when pushing out to dynamos. no need to do it here.
+ // Overvoltage is handled inside the MultiBlockBase when pushing out to dynamos. no need to do it here.
return true;
}
@@ -297,26 +267,21 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
}
String tRunning = mMaxProgresstime > 0
- ? EnumChatFormatting.GREEN
- + StatCollector.translateToLocal("GT5U.turbine.running.true")
+ ? EnumChatFormatting.GREEN + StatCollector.translateToLocal("GT5U.turbine.running.true")
+ EnumChatFormatting.RESET
- : EnumChatFormatting.RED
- + StatCollector.translateToLocal("GT5U.turbine.running.false")
+ : EnumChatFormatting.RED + StatCollector.translateToLocal("GT5U.turbine.running.false")
+ EnumChatFormatting.RESET;
String tMaintainance = getIdealStatus() == getRepairStatus()
- ? EnumChatFormatting.GREEN
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
+ ? EnumChatFormatting.GREEN + StatCollector.translateToLocal("GT5U.turbine.maintenance.false")
+ EnumChatFormatting.RESET
- : EnumChatFormatting.RED
- + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
+ : EnumChatFormatting.RED + StatCollector.translateToLocal("GT5U.turbine.maintenance.true")
+ EnumChatFormatting.RESET;
int tDura = 0;
if (mInventory[1] != null && mInventory[1].getItem() instanceof GT_MetaGenerated_Tool_01) {
- tDura = GT_Utility.safeInt((long) (100.0f
- / GT_MetaGenerated_Tool.getToolMaxDamage(mInventory[1])
- * (GT_MetaGenerated_Tool.getToolDamage(mInventory[1]))
- + 1));
+ tDura = GT_Utility.safeInt(
+ (long) (100.0f / GT_MetaGenerated_Tool.getToolMaxDamage(mInventory[1])
+ * (GT_MetaGenerated_Tool.getToolDamage(mInventory[1])) + 1));
}
long storedEnergy = 0;
@@ -328,34 +293,59 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar
}
}
String[] ret = new String[] {
- // 8 Lines available for information panels
- tRunning + ": " + EnumChatFormatting.RED + GT_Utility.formatNumbers(((long) mEUt * mEfficiency) / 10000)
- + EnumChatFormatting.RESET + " EU/t", /* 1 */
- tMaintainance, /* 2 */
- StatCollector.translateToLocal("GT5U.turbine.efficiency") + ": " + EnumChatFormatting.YELLOW
- + (mEfficiency / 100F) + EnumChatFormatting.RESET + "%", /* 2 */
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + /* 3 */ EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.turbine.flow") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(GT_Utility.safeInt((long) realOptFlow)) + EnumChatFormatting.RESET
- + " L/s" + /* 4 */ EnumChatFormatting.YELLOW
- + " ("
- + (looseFit
- ? StatCollector.translateToLocal("GT5U.turbine.loose")
- : StatCollector.translateToLocal("GT5U.turbine.tight"))
- + ")", /* 5 */
- StatCollector.translateToLocal("GT5U.turbine.fuel") + ": " + EnumChatFormatting.GOLD
- + GT_Utility.formatNumbers(storedFluid) + EnumChatFormatting.RESET + "L", /* 6 */
- StatCollector.translateToLocal("GT5U.turbine.dmg") + ": " + EnumChatFormatting.RED + Integer.toString(tDura)
- + EnumChatFormatting.RESET + "%", /* 7 */
- StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %" /* 8 */
+ // 8 Lines available for information panels
+ tRunning + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(((long) mEUt * mEfficiency) / 10000)
+ + EnumChatFormatting.RESET
+ + " EU/t", /* 1 */
+ tMaintainance, /* 2 */
+ StatCollector.translateToLocal("GT5U.turbine.efficiency") + ": "
+ + EnumChatFormatting.YELLOW
+ + (mEfficiency / 100F)
+ + EnumChatFormatting.RESET
+ + "%", /* 2 */
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + /* 3 */ EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.turbine.flow") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(GT_Utility.safeInt((long) realOptFlow))
+ + EnumChatFormatting.RESET
+ + " L/s"
+ + /* 4 */ EnumChatFormatting.YELLOW
+ + " ("
+ + (looseFit ? StatCollector.translateToLocal("GT5U.turbine.loose")
+ : StatCollector.translateToLocal("GT5U.turbine.tight"))
+ + ")", /* 5 */
+ StatCollector.translateToLocal("GT5U.turbine.fuel") + ": "
+ + EnumChatFormatting.GOLD
+ + GT_Utility.formatNumbers(storedFluid)
+ + EnumChatFormatting.RESET
+ + "L", /* 6 */
+ StatCollector.translateToLocal("GT5U.turbine.dmg") + ": "
+ + EnumChatFormatting.RED
+ + Integer.toString(tDura)
+ + EnumChatFormatting.RESET
+ + "%", /* 7 */
+ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %" /* 8 */
};
if (!this.getClass().getName().contains("Steam"))
- ret[4] = StatCollector.translateToLocal("GT5U.turbine.flow") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.safeInt((long) realOptFlow) + EnumChatFormatting.RESET + " L/s";
+ ret[4] = StatCollector.translateToLocal("GT5U.turbine.flow") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.safeInt((long) realOptFlow)
+ + EnumChatFormatting.RESET
+ + " L/s";
return ret;
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java
index b66bf85fb7..35deef3fed 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java
@@ -4,6 +4,14 @@ import static gregtech.api.enums.GT_Values.STEAM_PER_WATER;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import java.util.ArrayList;
+
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
@@ -13,12 +21,6 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_LargeTurbine {
@@ -35,48 +37,27 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- return new ITexture[] {
- MACHINE_CASINGS[1][aColorIndex + 1],
- aFacing == aSide
- ? (aActive
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_ACTIVE5)
- .build()
- : hasTurbine()
- ? TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW5)
- .build()
- : TextureFactory.builder()
- .addIcon(LARGETURBINE_NEW_EMPTY5)
- .build())
- : casingTexturePages[0][57]
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ return new ITexture[] { MACHINE_CASINGS[1][aColorIndex + 1],
+ aFacing == aSide
+ ? (aActive ? TextureFactory.builder().addIcon(LARGETURBINE_NEW_ACTIVE5).build()
+ : hasTurbine() ? TextureFactory.builder().addIcon(LARGETURBINE_NEW5).build()
+ : TextureFactory.builder().addIcon(LARGETURBINE_NEW_EMPTY5).build())
+ : casingTexturePages[0][57] };
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Steam Turbine")
- .addInfo("Controller block for the Large Steam Turbine")
+ tt.addMachineType("Steam Turbine").addInfo("Controller block for the Large Steam Turbine")
.addInfo("Needs a Turbine, place inside controller")
.addInfo("Outputs Distilled Water as well as producing power")
.addInfo("Power output depends on turbine and fitting")
- .addInfo("Use screwdriver to adjust fitting of turbine")
- .addSeparator()
- .beginStructureBlock(3, 3, 4, true)
- .addController("Front center")
- .addCasingInfo("Turbine Casing", 24)
- .addDynamoHatch("Back center", 1)
- .addMaintenanceHatch("Side centered", 2)
- .addInputHatch("Steam, Side centered", 2)
- .addOutputHatch("Distilled Water, Side centered", 2)
+ .addInfo("Use screwdriver to adjust fitting of turbine").addSeparator()
+ .beginStructureBlock(3, 3, 4, true).addController("Front center").addCasingInfo("Turbine Casing", 24)
+ .addDynamoHatch("Back center", 1).addMaintenanceHatch("Side centered", 2)
+ .addInputHatch("Steam, Side centered", 2).addOutputHatch("Distilled Water, Side centered", 2)
.toolTipFinisher("Gregtech");
return tt;
}
@@ -114,11 +95,7 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
}
@Override
- int fluidIntoPower(
- ArrayList<FluidStack> aFluids,
- int aOptFlow,
- int aBaseEff,
- int overflowEfficiency,
+ int fluidIntoPower(ArrayList<FluidStack> aFluids, int aOptFlow, int aBaseEff, int overflowEfficiency,
float[] flowMultipliers) {
if (looseFit) {
long[] calculatedFlow = calculateLooseFlow(aOptFlow, aBaseEff);
@@ -142,9 +119,8 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
int remainingFlow = GT_Utility.safeInt((long) (realOptFlow * (0.5f * overflowMultiplier + 1)));
storedFluid = 0;
- for (int i = 0;
- i < aFluids.size() && remainingFlow > 0;
- i++) { // loop through each hatch; extract inputs and track totals.
+ for (int i = 0; i < aFluids.size() && remainingFlow > 0; i++) { // loop through each hatch; extract inputs and
+ // track totals.
final FluidStack aFluidStack = aFluids.get(i);
if (GT_ModHandler.isAnySteam(aFluidStack)) {
flow = Math.min(aFluidStack.amount, remainingFlow); // try to use up to the max flow defined just above
@@ -154,10 +130,8 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
totalFlow += flow; // track total input used
if (!achievement) {
GT_Mod.achievements.issueAchievement(
- this.getBaseMetaTileEntity()
- .getWorld()
- .getPlayerEntityByName(
- this.getBaseMetaTileEntity().getOwnerName()),
+ this.getBaseMetaTileEntity().getWorld()
+ .getPlayerEntityByName(this.getBaseMetaTileEntity().getOwnerName()),
"muchsteam");
achievement = true;
}
@@ -172,8 +146,10 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
if (totalFlow == (GT_Utility.safeInt((long) realOptFlow))) {
tEU = GT_Utility.safeInt((long) tEU * (long) aBaseEff / 20000L);
} else {
- float efficiency =
- getOverflowEfficiency(totalFlow, (GT_Utility.safeInt((long) realOptFlow)), overflowMultiplier);
+ float efficiency = getOverflowEfficiency(
+ totalFlow,
+ (GT_Utility.safeInt((long) realOptFlow)),
+ overflowMultiplier);
tEU *= efficiency;
tEU = Math.max(1, GT_Utility.safeInt((long) tEU * (long) aBaseEff / 20000L));
}
@@ -199,9 +175,8 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
float efficiency = 0;
if (totalFlow > actualOptimalFlow) {
- efficiency = 1.0f
- - Math.abs((totalFlow - actualOptimalFlow))
- / ((float) actualOptimalFlow * (overflowMultiplier + 1));
+ efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow))
+ / ((float) actualOptimalFlow * (overflowMultiplier + 1));
} else {
efficiency = 1.0f - Math.abs((totalFlow - actualOptimalFlow) / (float) actualOptimalFlow);
}
@@ -249,8 +224,7 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg
looseFit ^= true;
GT_Utility.sendChatToPlayer(
aPlayer,
- looseFit
- ? GT_Utility.trans("500", "Fitting: Loose - More Flow")
+ looseFit ? GT_Utility.trans("500", "Fitting: Loose - More Flow")
: GT_Utility.trans("501", "Fitting: Tight - More Efficiency"));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_MultiFurnace.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_MultiFurnace.java
index 466e741fed..aec44c664d 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_MultiFurnace.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_MultiFurnace.java
@@ -11,10 +11,18 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_MULTI_SMELTER
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_MULTI_SMELTER_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.casingTexturePages;
+import java.util.ArrayList;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.common.util.ForgeDirection;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.HeatingCoilLevel;
@@ -32,44 +40,37 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_StructureUtility;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.common.util.ForgeDirection;
-public class GT_MetaTileEntity_MultiFurnace
- extends GT_MetaTileEntity_AbstractMultiFurnace<GT_MetaTileEntity_MultiFurnace>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_MultiFurnace extends
+ GT_MetaTileEntity_AbstractMultiFurnace<GT_MetaTileEntity_MultiFurnace> implements ISurvivalConstructable {
+
private int mLevel = 0;
private int mCostDiscount = 1;
private static final int CASING_INDEX = 11;
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_MultiFurnace> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_MultiFurnace>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {"ccc", "cmc", "ccc"},
- {"CCC", "C-C", "CCC"},
- {"b~b", "bbb", "bbb"}
- }))
- .addElement('c', ofBlock(GregTech_API.sBlockCasings1, CASING_INDEX))
- .addElement('m', Muffler.newAny(CASING_INDEX, 2))
- .addElement(
- 'C',
- GT_StructureUtility.ofCoil(
- GT_MetaTileEntity_MultiFurnace::setCoilLevel,
- GT_MetaTileEntity_MultiFurnace::getCoilLevel))
- .addElement(
- 'b',
- ofChain(
- GT_StructureUtility.<GT_MetaTileEntity_MultiFurnace>buildHatchAdder()
- .atLeast(Maintenance, InputBus, OutputBus, Energy)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .build(),
- ofBlock(GregTech_API.sBlockCasings1, CASING_INDEX)))
- .build();
+ private static final IStructureDefinition<GT_MetaTileEntity_MultiFurnace> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_MultiFurnace>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "ccc", "cmc", "ccc" }, { "CCC", "C-C", "CCC" },
+ { "b~b", "bbb", "bbb" } }))
+ .addElement('c', ofBlock(GregTech_API.sBlockCasings1, CASING_INDEX))
+ .addElement('m', Muffler.newAny(CASING_INDEX, 2))
+ .addElement(
+ 'C',
+ GT_StructureUtility.ofCoil(
+ GT_MetaTileEntity_MultiFurnace::setCoilLevel,
+ GT_MetaTileEntity_MultiFurnace::getCoilLevel))
+ .addElement(
+ 'b',
+ ofChain(
+ GT_StructureUtility.<GT_MetaTileEntity_MultiFurnace>buildHatchAdder()
+ .atLeast(Maintenance, InputBus, OutputBus, Energy).casingIndex(CASING_INDEX).dot(1)
+ .build(),
+ ofBlock(GregTech_API.sBlockCasings1, CASING_INDEX)))
+ .build();
public GT_MetaTileEntity_MultiFurnace(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
@@ -87,59 +88,26 @@ public class GT_MetaTileEntity_MultiFurnace
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Furnace")
- .addInfo("Controller Block for the Multi Smelter")
- .addInfo("Smelts up to 8-8192 items at once")
- .addInfo("Items smelted increases with coil tier")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(3, 3, 3, true)
- .addController("Front bottom")
- .addCasingInfo("Heat Proof Machine Casing", 8)
- .addOtherStructurePart("Heating Coils", "Middle layer")
- .addEnergyHatch("Any bottom casing", 1)
- .addMaintenanceHatch("Any bottom casing", 1)
- .addMufflerHatch("Top Middle", 2)
- .addInputBus("Any bottom casing", 1)
- .addOutputBus("Any bottom casing", 1)
- .toolTipFinisher("Gregtech");
+ tt.addMachineType("Furnace").addInfo("Controller Block for the Multi Smelter")
+ .addInfo("Smelts up to 8-8192 items at once").addInfo("Items smelted increases with coil tier")
+ .addPollutionAmount(getPollutionPerSecond(null)).addSeparator().beginStructureBlock(3, 3, 3, true)
+ .addController("Front bottom").addCasingInfo("Heat Proof Machine Casing", 8)
+ .addOtherStructurePart("Heating Coils", "Middle layer").addEnergyHatch("Any bottom casing", 1)
+ .addMaintenanceHatch("Any bottom casing", 1).addMufflerHatch("Top Middle", 2)
+ .addInputBus("Any bottom casing", 1).addOutputBus("Any bottom casing", 1).toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide != aFacing) return new ITexture[] {casingTexturePages[0][CASING_INDEX]};
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_MULTI_SMELTER_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_MULTI_SMELTER_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_MULTI_SMELTER)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_MULTI_SMELTER_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide != aFacing) return new ITexture[] { casingTexturePages[0][CASING_INDEX] };
+ if (aActive) return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_MULTI_SMELTER_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_MULTI_SMELTER_ACTIVE_GLOW).extFacing().glow().build() };
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_MULTI_SMELTER).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_MULTI_SMELTER_GLOW).extFacing().glow().build() };
}
@Override
@@ -240,61 +208,87 @@ public class GT_MetaTileEntity_MultiFurnace
int tY = aBaseMetaTileEntity.getYCoord();
int tZ = aBaseMetaTileEntity.getZCoord() + zDir;
int tUsedMeta;
- for (int xPos = tX - 1; xPos <= tX + 1; xPos++)
- for (int zPos = tZ - 1; zPos <= tZ + 1; zPos++) {
- if ((xPos == tX) && (zPos == tZ)) continue;
- tUsedMeta = aBaseMetaTileEntity.getMetaID(xPos, tY + 1, zPos);
- if (tUsedMeta >= 12
- && tUsedMeta <= 14
- && aBaseMetaTileEntity.getBlock(xPos, tY + 1, zPos) == GregTech_API.sBlockCasings1)
- aBaseMetaTileEntity
- .getWorld()
- .setBlock(xPos, tY + 1, zPos, GregTech_API.sBlockCasings5, tUsedMeta - 12, 3);
- }
+ for (int xPos = tX - 1; xPos <= tX + 1; xPos++) for (int zPos = tZ - 1; zPos <= tZ + 1; zPos++) {
+ if ((xPos == tX) && (zPos == tZ)) continue;
+ tUsedMeta = aBaseMetaTileEntity.getMetaID(xPos, tY + 1, zPos);
+ if (tUsedMeta >= 12 && tUsedMeta <= 14
+ && aBaseMetaTileEntity.getBlock(xPos, tY + 1, zPos) == GregTech_API.sBlockCasings1)
+ aBaseMetaTileEntity.getWorld()
+ .setBlock(xPos, tY + 1, zPos, GregTech_API.sBlockCasings5, tUsedMeta - 12, 3);
+ }
}
@Override
public String[] getInfoData() {
int mPollutionReduction = 0;
- for (GT_MetaTileEntity_Hatch_Muffler tHatch : mMufflerHatches)
- if (isValidMetaTileEntity(tHatch))
- mPollutionReduction = Math.max(tHatch.calculatePollutionReduction(100), mPollutionReduction);
+ for (GT_MetaTileEntity_Hatch_Muffler tHatch : mMufflerHatches) if (isValidMetaTileEntity(tHatch))
+ mPollutionReduction = Math.max(tHatch.calculatePollutionReduction(100), mPollutionReduction);
long storedEnergy = 0;
long maxEnergy = 0;
- for (GT_MetaTileEntity_Hatch_Energy tHatch : mEnergyHatches)
- if (isValidMetaTileEntity(tHatch)) {
- storedEnergy += tHatch.getBaseMetaTileEntity().getStoredEU();
- maxEnergy += tHatch.getBaseMetaTileEntity().getEUCapacity();
- }
+ for (GT_MetaTileEntity_Hatch_Energy tHatch : mEnergyHatches) if (isValidMetaTileEntity(tHatch)) {
+ storedEnergy += tHatch.getBaseMetaTileEntity().getStoredEU();
+ maxEnergy += tHatch.getBaseMetaTileEntity().getEUCapacity();
+ }
return new String[] {
- StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mProgresstime / 20) + EnumChatFormatting.RESET + " s / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(mMaxProgresstime / 20) + EnumChatFormatting.RESET + " s",
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.multiblock.usage") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(-mEUt) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.multiblock.mei") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(getMaxInputVoltage()) + EnumChatFormatting.RESET + " EU/t(*2A) "
- + StatCollector.translateToLocal("GT5U.machines.tier")
- + ": " + EnumChatFormatting.YELLOW
- + VN[GT_Utility.getTier(getMaxInputVoltage())] + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.multiblock.problems") + ": " + EnumChatFormatting.RED
- + (getIdealStatus() - getRepairStatus()) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
- + ": " + EnumChatFormatting.YELLOW
- + mEfficiency / 100.0F + EnumChatFormatting.RESET + " %",
- StatCollector.translateToLocal("GT5U.MS.multismelting") + ": " + EnumChatFormatting.GREEN
- + mLevel + EnumChatFormatting.RESET + " Discount: (EU/t) / "
- + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(mCostDiscount) + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %"
- };
+ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(mMaxProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s",
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.multiblock.usage") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(-mEUt)
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.multiblock.mei") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getMaxInputVoltage())
+ + EnumChatFormatting.RESET
+ + " EU/t(*2A) "
+ + StatCollector.translateToLocal("GT5U.machines.tier")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + VN[GT_Utility.getTier(getMaxInputVoltage())]
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.multiblock.problems") + ": "
+ + EnumChatFormatting.RED
+ + (getIdealStatus() - getRepairStatus())
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + mEfficiency / 100.0F
+ + EnumChatFormatting.RESET
+ + " %",
+ StatCollector.translateToLocal("GT5U.MS.multismelting") + ": "
+ + EnumChatFormatting.GREEN
+ + mLevel
+ + EnumChatFormatting.RESET
+ + " Discount: (EU/t) / "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mCostDiscount)
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %" };
}
@Override
@@ -306,8 +300,7 @@ public class GT_MetaTileEntity_MultiFurnace
if (aTileEntity == null) return false;
IMetaTileEntity tMTE = aTileEntity.getMetaTileEntity();
if (tMTE == null) return false;
- return tMTE instanceof GT_MetaTileEntity_Hatch_Energy
- || tMTE instanceof GT_MetaTileEntity_Hatch_InputBus
+ return tMTE instanceof GT_MetaTileEntity_Hatch_Energy || tMTE instanceof GT_MetaTileEntity_Hatch_InputBus
|| tMTE instanceof GT_MetaTileEntity_Hatch_OutputBus
|| tMTE instanceof GT_MetaTileEntity_Hatch_Maintenance;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_NanoForge.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_NanoForge.java
index 0694434137..ddb8e302e4 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_NanoForge.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_NanoForge.java
@@ -10,12 +10,23 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_ASSEMBLY_LINE
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofFrame;
+import java.util.ArrayList;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.IAlignmentLimits;
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.alignment.enumerable.Rotation;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.enums.Textures.BlockIcons;
@@ -29,24 +40,16 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.common.blocks.GT_Block_Casings8;
-import java.util.ArrayList;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
-public class GT_MetaTileEntity_NanoForge
- extends GT_MetaTileEntity_ExtendedPowerMultiBlockBase<GT_MetaTileEntity_NanoForge>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_NanoForge extends
+ GT_MetaTileEntity_ExtendedPowerMultiBlockBase<GT_MetaTileEntity_NanoForge> implements ISurvivalConstructable {
+
private static final String STRUCTURE_PIECE_MAIN = "main";
private static final String STRUCTURE_PIECE_TIER2 = "tier2";
private static final String STRUCTURE_PIECE_TIER3 = "tier3";
- private static final IStructureDefinition<GT_MetaTileEntity_NanoForge> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_NanoForge>builder()
- // spotless:off
+ private static final IStructureDefinition<GT_MetaTileEntity_NanoForge> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_NanoForge>builder()
+ // spotless:off
.addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
{" "," "," F "," C "," C "," C "," C "," F "," "," "},
{" "," "," F "," C "," C "," C "," C "," F "," "," "},
@@ -134,17 +137,15 @@ public class GT_MetaTileEntity_NanoForge
{" CCCCCC ", "CCCCCCCC", "CCCCCCCC", "CCCCCCCC", "CCCCCCCC", "CCCCCCCC", "CCCCCCCC", " CCCCCC "}
}))
//spotless:on
- .addElement('F', ofFrame(Materials.StellarAlloy))
- .addElement('C', ofBlock(GregTech_API.sBlockCasings8, 10))
- .addElement('A', ofBlock(GregTech_API.sBlockCasings2, 5))
- .addElement(
- 'B',
- buildHatchAdder(GT_MetaTileEntity_NanoForge.class)
- .atLeast(InputHatch, OutputBus, InputBus, Maintenance, Energy.or(ExoticEnergy))
- .dot(1)
- .casingIndex(((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(10))
- .buildAndChain(GregTech_API.sBlockCasings8, 10))
- .build();
+ .addElement('F', ofFrame(Materials.StellarAlloy)).addElement('C', ofBlock(GregTech_API.sBlockCasings8, 10))
+ .addElement('A', ofBlock(GregTech_API.sBlockCasings2, 5))
+ .addElement(
+ 'B',
+ buildHatchAdder(GT_MetaTileEntity_NanoForge.class)
+ .atLeast(InputHatch, OutputBus, InputBus, Maintenance, Energy.or(ExoticEnergy)).dot(1)
+ .casingIndex(((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(10))
+ .buildAndChain(GregTech_API.sBlockCasings8, 10))
+ .build();
private byte mSpecialTier = 0;
private boolean mSeparate = false;
@@ -178,43 +179,21 @@ public class GT_MetaTileEntity_NanoForge
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
+ if (aActive) return new ITexture[] {
BlockIcons.getCasingTextureForId(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 10)),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE_GLOW).extFacing().glow()
+ .build() };
return new ITexture[] {
- BlockIcons.getCasingTextureForId(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 10)),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ BlockIcons.getCasingTextureForId(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 10)),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_GLOW).extFacing().glow().build() };
}
return new ITexture[] {
- BlockIcons.getCasingTextureForId(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 10))
- };
+ BlockIcons.getCasingTextureForId(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 10)) };
}
@Override
@@ -253,8 +232,8 @@ public class GT_MetaTileEntity_NanoForge
mOutputItems = null;
mOutputFluids = null;
long tTotalEU = getMaxInputEu();
- GT_Recipe tRecipe =
- map.findRecipe(getBaseMetaTileEntity(), null, false, false, tTotalEU, tFluidInputs, null, tItemInputs);
+ GT_Recipe tRecipe = map
+ .findRecipe(getBaseMetaTileEntity(), null, false, false, tTotalEU, tFluidInputs, null, tItemInputs);
if (tRecipe == null) return false;
@@ -266,7 +245,11 @@ public class GT_MetaTileEntity_NanoForge
this.mMaxProgresstime = tRecipe.mDuration;
this.lEUt = -tRecipe.mEUt;
calculateOverclockedNessMultiInternal(
- tRecipe.mEUt, tRecipe.mDuration, 1, tTotalEU, tRecipe.mSpecialValue < mSpecialTier);
+ tRecipe.mEUt,
+ tRecipe.mDuration,
+ 1,
+ tTotalEU,
+ tRecipe.mSpecialValue < mSpecialTier);
if (this.lEUt == Long.MAX_VALUE - 1 || this.mMaxProgresstime == Integer.MAX_VALUE - 1) return false;
@@ -300,21 +283,18 @@ public class GT_MetaTileEntity_NanoForge
mSpecialTier = 1;
}
- if (aStack.isItemEqual(Materials.Neutronium.getNanite(1))
- && checkPiece(STRUCTURE_PIECE_MAIN, 4, 37, 1)
+ if (aStack.isItemEqual(Materials.Neutronium.getNanite(1)) && checkPiece(STRUCTURE_PIECE_MAIN, 4, 37, 1)
&& checkPiece(STRUCTURE_PIECE_TIER2, -7, 14, 4)) {
mSpecialTier = 2;
}
- if (aStack.isItemEqual(Materials.TranscendentMetal.getNanite(1))
- && checkPiece(STRUCTURE_PIECE_MAIN, 4, 37, 1)
+ if (aStack.isItemEqual(Materials.TranscendentMetal.getNanite(1)) && checkPiece(STRUCTURE_PIECE_MAIN, 4, 37, 1)
&& checkPiece(STRUCTURE_PIECE_TIER2, -7, 14, 4)
&& checkPiece(STRUCTURE_PIECE_TIER3, 14, 26, 4)) {
mSpecialTier = 3;
}
- if (mMaintenanceHatches.size() != 1
- || mInputBusses.isEmpty()
+ if (mMaintenanceHatches.size() != 1 || mInputBusses.isEmpty()
|| mOutputBusses.isEmpty()
|| mInputHatches.isEmpty()) {
return false;
@@ -370,40 +350,32 @@ public class GT_MetaTileEntity_NanoForge
mSpecialTier = aNBT.getByte("mSpecialTier");
}
- /** Get possible alignments of this controller
+ /**
+ * Get possible alignments of this controller
*
* @return List of alignments that are possible or denied
*/
@Override
public IAlignmentLimits getAlignmentLimits() {
// The nano forge should only be buildable upright
- return IAlignmentLimits.Builder.allowAll()
- .deny(ForgeDirection.DOWN)
- .deny(ForgeDirection.UP)
- .deny(Rotation.UPSIDE_DOWN)
- .deny(Rotation.CLOCKWISE)
- .deny(Rotation.COUNTER_CLOCKWISE)
- .build();
+ return IAlignmentLimits.Builder.allowAll().deny(ForgeDirection.DOWN).deny(ForgeDirection.UP)
+ .deny(Rotation.UPSIDE_DOWN).deny(Rotation.CLOCKWISE).deny(Rotation.COUNTER_CLOCKWISE).build();
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Nanite Fabricator")
- .addInfo("Controller block for the Nano Forge")
+ tt.addMachineType("Nanite Fabricator").addInfo("Controller block for the Nano Forge")
.addInfo("Requires insane amounts of power to create nanites. Each tier")
.addInfo("the multi gains a new building next to it. The nanite in the")
- .addInfo("controller slot controls the tier.")
- .addInfo("--------------------------------------------")
+ .addInfo("controller slot controls the tier.").addInfo("--------------------------------------------")
.addInfo("Requires a Carbon Nanite to use tier tier " + EnumChatFormatting.DARK_PURPLE + 1)
.addInfo("Requires a Neutronium Nanite to use tier " + EnumChatFormatting.DARK_PURPLE + 2)
.addInfo("Requires a Transcendent Metal Nanite to use tier " + EnumChatFormatting.DARK_PURPLE + 3)
.addInfo("--------------------------------------------")
.addInfo("If a recipe's tier is lower than the tier of the Nano Forge")
.addInfo("it gains " + EnumChatFormatting.RED + "perfect overclock" + EnumChatFormatting.GRAY + ".")
- .addInfo(AuthorBlueWeabo)
- .addSeparator()
- .beginStructureBlock(30, 38, 13, false)
+ .addInfo(AuthorBlueWeabo).addSeparator().beginStructureBlock(30, 38, 13, false)
.addStructureInfo("Nano Forge Structure is too complex! See schematic for details.")
.addStructureInfo("--------------------------------------------")
.addStructureInfo("Tier " + EnumChatFormatting.DARK_PURPLE + 1 + EnumChatFormatting.GRAY)
@@ -423,21 +395,50 @@ public class GT_MetaTileEntity_NanoForge
.addStructureInfo(EnumChatFormatting.GOLD + "84" + EnumChatFormatting.GRAY + " Stellar Alloy Frame Box")
.addStructureInfo(EnumChatFormatting.GOLD + "16" + EnumChatFormatting.GRAY + " Assembling Line Casing")
.addStructureInfo("--------------------------------------------")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + "-"
- + EnumChatFormatting.GOLD + "2" + EnumChatFormatting.GRAY + " energy hatches or "
- + EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + " TT energy hatch.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + "1"
+ + EnumChatFormatting.GRAY
+ + "-"
+ + EnumChatFormatting.GOLD
+ + "2"
+ + EnumChatFormatting.GRAY
+ + " energy hatches or "
+ + EnumChatFormatting.GOLD
+ + "1"
+ + EnumChatFormatting.GRAY
+ + " TT energy hatch.")
.addStructureInfo(
"Requires " + EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + " maintenance hatch.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + 1 + EnumChatFormatting.GRAY + "+"
- + EnumChatFormatting.GRAY + " input hatches.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + 0 + EnumChatFormatting.GRAY + "+"
- + EnumChatFormatting.GRAY + " output hatches.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + 1 + EnumChatFormatting.GRAY + "+"
- + EnumChatFormatting.GRAY + " input busses.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + 1 + EnumChatFormatting.GRAY + "+"
- + EnumChatFormatting.GRAY + " output busses.")
- .addStructureInfo("--------------------------------------------")
- .toolTipFinisher("GregTech");
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + 1
+ + EnumChatFormatting.GRAY
+ + "+"
+ + EnumChatFormatting.GRAY
+ + " input hatches.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + 0
+ + EnumChatFormatting.GRAY
+ + "+"
+ + EnumChatFormatting.GRAY
+ + " output hatches.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + 1
+ + EnumChatFormatting.GRAY
+ + "+"
+ + EnumChatFormatting.GRAY
+ + " input busses.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + 1
+ + EnumChatFormatting.GRAY
+ + "+"
+ + EnumChatFormatting.GRAY
+ + " output busses.")
+ .addStructureInfo("--------------------------------------------").toolTipFinisher("GregTech");
return tt;
}
@@ -445,6 +446,7 @@ public class GT_MetaTileEntity_NanoForge
public final void onScrewdriverRightClick(byte aSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
mSeparate = !mSeparate;
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + mSeparate);
+ aPlayer,
+ StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + mSeparate);
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilCracker.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilCracker.java
index 3f64dd2e2a..becb1fcf47 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilCracker.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilCracker.java
@@ -10,10 +10,18 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_OIL_CRACKER_G
import static gregtech.api.enums.Textures.BlockIcons.casingTexturePages;
import static gregtech.api.util.GT_StructureUtility.*;
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_HatchElement;
import gregtech.api.enums.HeatingCoilLevel;
@@ -28,69 +36,58 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.List;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_OilCracker extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_OilCracker>
implements ISurvivalConstructable {
+
private static final byte CASING_INDEX = 49;
private static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_OilCracker> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_OilCracker>builder()
- .addShape(STRUCTURE_PIECE_MAIN, transpose(new String[][] {
- {"lcmcr", "lcmcr", "lcmcr"},
- {"lc~cr", "l---r", "lcmcr"},
- {"lcmcr", "lcmcr", "lcmcr"},
- }))
- .addElement(
- 'c',
- ofCoil(
- GT_MetaTileEntity_OilCracker::setCoilLevel,
- GT_MetaTileEntity_OilCracker::getCoilLevel))
- .addElement(
- 'l',
- buildHatchAdder(GT_MetaTileEntity_OilCracker.class)
- .atLeast(
- GT_HatchElement.InputHatch.withAdder(
- GT_MetaTileEntity_OilCracker::addLeftHatchToMachineList),
- GT_HatchElement.Energy,
- GT_HatchElement.Maintenance)
- .dot(2)
- .casingIndex(CASING_INDEX)
- .buildAndChain(onElementPass(
+ private static final IStructureDefinition<GT_MetaTileEntity_OilCracker> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_OilCracker>builder()
+ .addShape(
+ STRUCTURE_PIECE_MAIN,
+ transpose(
+ new String[][] { { "lcmcr", "lcmcr", "lcmcr" }, { "lc~cr", "l---r", "lcmcr" },
+ { "lcmcr", "lcmcr", "lcmcr" }, }))
+ .addElement(
+ 'c',
+ ofCoil(GT_MetaTileEntity_OilCracker::setCoilLevel, GT_MetaTileEntity_OilCracker::getCoilLevel))
+ .addElement(
+ 'l',
+ buildHatchAdder(GT_MetaTileEntity_OilCracker.class).atLeast(
+ GT_HatchElement.InputHatch
+ .withAdder(GT_MetaTileEntity_OilCracker::addLeftHatchToMachineList),
+ GT_HatchElement.Energy,
+ GT_HatchElement.Maintenance).dot(2).casingIndex(CASING_INDEX).buildAndChain(
+ onElementPass(
GT_MetaTileEntity_OilCracker::onCasingAdded,
ofBlock(GregTech_API.sBlockCasings4, 1))))
- .addElement(
- 'r',
- buildHatchAdder(GT_MetaTileEntity_OilCracker.class)
- .atLeast(
- GT_HatchElement.OutputHatch.withAdder(
- GT_MetaTileEntity_OilCracker::addRightHatchToMachineList),
- GT_HatchElement.Energy,
- GT_HatchElement.Maintenance)
- .dot(3)
- .casingIndex(CASING_INDEX)
- .buildAndChain(onElementPass(
+ .addElement(
+ 'r',
+ buildHatchAdder(GT_MetaTileEntity_OilCracker.class).atLeast(
+ GT_HatchElement.OutputHatch
+ .withAdder(GT_MetaTileEntity_OilCracker::addRightHatchToMachineList),
+ GT_HatchElement.Energy,
+ GT_HatchElement.Maintenance).dot(3).casingIndex(CASING_INDEX).buildAndChain(
+ onElementPass(
GT_MetaTileEntity_OilCracker::onCasingAdded,
ofBlock(GregTech_API.sBlockCasings4, 1))))
- .addElement(
- 'm',
- buildHatchAdder(GT_MetaTileEntity_OilCracker.class)
+ .addElement(
+ 'm',
+ buildHatchAdder(
+ GT_MetaTileEntity_OilCracker.class)
.atLeast(
- GT_HatchElement.InputHatch.withAdder(
+ GT_HatchElement.InputHatch
+ .withAdder(
GT_MetaTileEntity_OilCracker::addMiddleInputToMachineList)
.withCount(t -> t.mMiddleInputHatches.size()),
GT_HatchElement.Energy,
GT_HatchElement.Maintenance)
- .dot(1)
- .casingIndex(CASING_INDEX)
- .buildAndChain(onElementPass(
- GT_MetaTileEntity_OilCracker::onCasingAdded,
- ofBlock(GregTech_API.sBlockCasings4, 1))))
- .build();
+ .dot(1).casingIndex(CASING_INDEX).buildAndChain(
+ onElementPass(
+ GT_MetaTileEntity_OilCracker::onCasingAdded,
+ ofBlock(GregTech_API.sBlockCasings4, 1))))
+ .build();
private HeatingCoilLevel heatLevel;
protected final List<GT_MetaTileEntity_Hatch_Input> mMiddleInputHatches = new ArrayList<>();
// 0 -> left, 1 -> right, any other -> not found
@@ -109,68 +106,39 @@ public class GT_MetaTileEntity_OilCracker extends GT_MetaTileEntity_EnhancedMult
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Cracker")
- .addInfo("Controller block for the Oil Cracking Unit")
+ tt.addMachineType("Cracker").addInfo("Controller block for the Oil Cracking Unit")
.addInfo("Thermally cracks heavy hydrocarbons into lighter fractions")
.addInfo("More efficient than the Chemical Reactor")
.addInfo("Gives different benefits whether it hydro or steam-cracks:")
.addInfo("Hydro - Consumes 20% less Hydrogen and outputs 25% more cracked fluid")
.addInfo("Steam - Outputs 50% more cracked fluid")
.addInfo("(Values compared to cracking in the Chemical Reactor)")
- .addInfo("Place the appropriate circuit in the controller")
- .addSeparator()
- .beginStructureBlock(5, 3, 3, true)
- .addController("Front center")
+ .addInfo("Place the appropriate circuit in the controller").addSeparator()
+ .beginStructureBlock(5, 3, 3, true).addController("Front center")
.addCasingInfo("Clean Stainless Steel Machine Casing", 18)
.addOtherStructurePart("2 Rings of 8 Coils", "Each side of the controller")
.addInfo("Gets 10% EU/t reduction per coil tier, up to a maximum of 50%")
- .addEnergyHatch("Any casing", 1, 2, 3)
- .addMaintenanceHatch("Any casing", 1, 2, 3)
+ .addEnergyHatch("Any casing", 1, 2, 3).addMaintenanceHatch("Any casing", 1, 2, 3)
.addInputHatch("Steam/Hydrogen ONLY, Any middle ring casing", 1)
- .addInputHatch("Any left/right side casing", 2, 3)
- .addOutputHatch("Any right/left side casing", 2, 3)
+ .addInputHatch("Any left/right side casing", 2, 3).addOutputHatch("Any right/left side casing", 2, 3)
.addStructureInfo("Input/Output Hatches must be on opposite sides!")
- .addStructureHint("GT5U.cracker.io_side")
- .toolTipFinisher("Gregtech");
+ .addStructureHint("GT5U.cracker.io_side").toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_CRACKER_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_CRACKER_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][CASING_INDEX],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_CRACKER)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_CRACKER_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_CRACKER_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_CRACKER_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_CRACKER).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_CRACKER_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {casingTexturePages[0][CASING_INDEX]};
+ return new ITexture[] { casingTexturePages[0][CASING_INDEX] };
}
@Override
@@ -185,13 +153,12 @@ public class GT_MetaTileEntity_OilCracker extends GT_MetaTileEntity_EnhancedMult
long tVoltage = getMaxInputVoltage();
byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
- GT_Recipe tRecipe = getRecipeMap()
- .findRecipe(
- getBaseMetaTileEntity(),
- false,
- gregtech.api.enums.GT_Values.V[tTier],
- tFluidInputs,
- mInventory[1]);
+ GT_Recipe tRecipe = getRecipeMap().findRecipe(
+ getBaseMetaTileEntity(),
+ false,
+ gregtech.api.enums.GT_Values.V[tTier],
+ tFluidInputs,
+ mInventory[1]);
if (tRecipe == null) return false;
@@ -211,7 +178,7 @@ public class GT_MetaTileEntity_OilCracker extends GT_MetaTileEntity_EnhancedMult
if (this.mEUt > 0) this.mEUt = (-this.mEUt);
- this.mOutputFluids = new FluidStack[] {tRecipe.getFluidOutput(0)};
+ this.mOutputFluids = new FluidStack[] { tRecipe.getFluidOutput(0) };
return true;
}
return false;
@@ -303,8 +270,7 @@ public class GT_MetaTileEntity_OilCracker extends GT_MetaTileEntity_EnhancedMult
mInputOnSide = -1;
mOutputOnSide = -1;
replaceDeprecatedCoils(aBaseMetaTileEntity);
- return checkPiece(STRUCTURE_PIECE_MAIN, 2, 1, 0)
- && mInputOnSide != -1
+ return checkPiece(STRUCTURE_PIECE_MAIN, 2, 1, 0) && mInputOnSide != -1
&& mOutputOnSide != -1
&& mCasingAmount >= 18
&& mMaintenanceHatches.size() == 1
@@ -351,8 +317,7 @@ public class GT_MetaTileEntity_OilCracker extends GT_MetaTileEntity_EnhancedMult
if (tUsedMeta > 14) continue;
if (aBaseMetaTileEntity.getBlock(xPos, yPos, zPos) != GregTech_API.sBlockCasings1) continue;
- aBaseMetaTileEntity
- .getWorld()
+ aBaseMetaTileEntity.getWorld()
.setBlock(xPos, yPos, zPos, GregTech_API.sBlockCasings5, tUsedMeta - 12, 3);
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill1.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill1.java
index 610c21e89b..1e37dcbac9 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill1.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill1.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_OilDrill1 extends GT_MetaTileEntity_OilDrillBase {
+
public GT_MetaTileEntity_OilDrill1(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill2.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill2.java
index 31fc763da7..10a64a6b1d 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill2.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill2.java
@@ -9,6 +9,7 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_OilDrill2 extends GT_MetaTileEntity_OilDrillBase {
+
public GT_MetaTileEntity_OilDrill2(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill3.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill3.java
index 303502e1ce..bcbe42d794 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill3.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrill3.java
@@ -9,6 +9,7 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_OilDrill3 extends GT_MetaTileEntity_OilDrillBase {
+
public GT_MetaTileEntity_OilDrill3(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillBase.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillBase.java
index 72741573fd..dc56ffcb3f 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillBase.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillBase.java
@@ -10,18 +10,10 @@ import static gregtech.api.enums.Textures.BlockIcons.getCasingTextureForId;
import static gregtech.common.GT_UndergroundOil.undergroundOil;
import static gregtech.common.GT_UndergroundOil.undergroundOilReadInformation;
-import com.google.common.collect.ImmutableList;
-import gregtech.api.interfaces.IHatchElement;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.objects.GT_ChunkManager;
-import gregtech.api.render.TextureFactory;
-import gregtech.api.util.GT_Log;
-import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import gregtech.api.util.GT_Utility;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
+
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
@@ -33,7 +25,19 @@ import net.minecraft.world.chunk.Chunk;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
+import com.google.common.collect.ImmutableList;
+
+import gregtech.api.interfaces.IHatchElement;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.objects.GT_ChunkManager;
+import gregtech.api.render.TextureFactory;
+import gregtech.api.util.GT_Log;
+import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
+import gregtech.api.util.GT_Utility;
+
public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_DrillerBase {
+
private final ArrayList<Chunk> mOilFieldChunks = new ArrayList<>();
private int mOilId = 0;
private int mOilFlow = 0;
@@ -49,41 +53,17 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- getCasingTextureForId(casingTextureIndex),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_DRILL_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_DRILL_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- getCasingTextureForId(casingTextureIndex),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_DRILL)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_OIL_DRILL_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { getCasingTextureForId(casingTextureIndex),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_DRILL_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_DRILL_ACTIVE_GLOW).extFacing().glow().build() };
+ return new ITexture[] { getCasingTextureForId(casingTextureIndex),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_DRILL).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_OIL_DRILL_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {getCasingTextureForId(casingTextureIndex)};
+ return new ITexture[] { getCasingTextureForId(casingTextureIndex) };
}
@Override
@@ -110,20 +90,15 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
.addInfo("Works on " + getRangeInChunks() + "x" + getRangeInChunks() + " chunks")
.addInfo("Use a Screwdriver to configure range")
.addInfo("Use Programmed Circuits to ignore near exhausted oil field")
- .addInfo(
- "If total circuit # is greater than output amount it will halt. If it worked right.") // doesn't
+ .addInfo("If total circuit # is greater than output amount it will halt. If it worked right.") // doesn't
// work
- .addSeparator()
- .beginStructureBlock(3, 7, 3, false)
- .addController("Front bottom")
+ .addSeparator().beginStructureBlock(3, 7, 3, false).addController("Front bottom")
.addOtherStructurePart(casings, "form the 3x1x3 Base")
.addOtherStructurePart(casings, "1x3x1 pillar above the center of the base (2 minimum total)")
.addOtherStructurePart(getFrameMaterial().mName + " Frame Boxes", "Each pillar's side and 1x3x1 on top")
- .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1)
- .addMaintenanceHatch("Any base casing", 1)
+ .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1).addMaintenanceHatch("Any base casing", 1)
.addInputBus("Mining Pipes or Circuits, optional, any base casing", 1)
- .addOutputHatch("Any base casing", 1)
- .toolTipFinisher("Gregtech");
+ .addOutputHatch("Any base casing", 1).toolTipFinisher("Gregtech");
return tt;
}
@@ -147,7 +122,9 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
if (oldChunkRange != chunkRangeConfig) mOilFieldChunks.clear();
GT_Utility.sendChatToPlayer(
aPlayer,
- StatCollector.translateToLocal("GT5U.machines.workareaset") + " " + chunkRangeConfig + "x"
+ StatCollector.translateToLocal("GT5U.machines.workareaset") + " "
+ + chunkRangeConfig
+ + "x"
+ chunkRangeConfig
+ StatCollector.translateToLocal("GT5U.machines.chunks")); // TODO Add translation support
}
@@ -170,10 +147,8 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
this.mEUt = -7 << (tier << 1); // (1/4) A of current tier when at bottom (7/8) A of current tier while mining
this.mMaxProgresstime = Math.max(
1,
- (workState == STATE_AT_BOTTOM
- ? (64 * (chunkRangeConfig * chunkRangeConfig)) >> (getMinTier() - 1)
- : 120)
- >> tier);
+ (workState == STATE_AT_BOTTOM ? (64 * (chunkRangeConfig * chunkRangeConfig)) >> (getMinTier() - 1)
+ : 120) >> tier);
}
protected float computeSpeed() {
@@ -181,8 +156,8 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
}
@Override
- protected boolean workingAtBottom(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingAtBottom(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
switch (tryLowerPipeState(true)) {
case 0:
workState = STATE_DOWNWARD;
@@ -202,7 +177,7 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
float speed = computeSpeed();
FluidStack tFluid = pumpOil(speed);
if (tFluid != null && tFluid.amount > getTotalConfigValue()) {
- this.mOutputFluids = new FluidStack[] {tFluid};
+ this.mOutputFluids = new FluidStack[] { tFluid };
return true;
}
}
@@ -225,21 +200,22 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
tOil = new FluidStack(FluidRegistry.getFluid(mOilId), 0);
if (mOilFieldChunks.isEmpty()) {
- Chunk tChunk = getBaseMetaTileEntity()
- .getWorld()
- .getChunkFromBlockCoords(
- getBaseMetaTileEntity().getXCoord(),
- getBaseMetaTileEntity().getZCoord());
+ Chunk tChunk = getBaseMetaTileEntity().getWorld()
+ .getChunkFromBlockCoords(getBaseMetaTileEntity().getXCoord(), getBaseMetaTileEntity().getZCoord());
int range = chunkRangeConfig;
- int xChunk = Math.floorDiv(tChunk.xPosition, range)
- * range; // Java was written by idiots. For negative values, / returns rounded towards zero.
+ int xChunk = Math.floorDiv(tChunk.xPosition, range) * range; // Java was written by idiots. For negative
+ // values, / returns rounded towards zero.
// Fucking morons.
int zChunk = Math.floorDiv(tChunk.zPosition, range) * range;
if (debugDriller) {
- GT_Log.out.println("tChunk.xPosition = " + tChunk.xPosition + " tChunk.zPosition = "
- + tChunk.zPosition + " xChunk = "
- + xChunk + " zChunk = "
- + zChunk);
+ GT_Log.out.println(
+ "tChunk.xPosition = " + tChunk.xPosition
+ + " tChunk.zPosition = "
+ + tChunk.zPosition
+ + " xChunk = "
+ + xChunk
+ + " zChunk = "
+ + zChunk);
}
for (int i = 0; i < range; i++) {
for (int j = 0; j < range; j++) {
@@ -249,8 +225,7 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
tChunk = getBaseMetaTileEntity().getWorld().getChunkFromChunkCoords(xChunk + i, zChunk + j);
tFluid = undergroundOilReadInformation(tChunk);
if (debugDriller) {
- GT_Log.out.println(
- " Fluid in chunk = " + tFluid.getFluid().getID());
+ GT_Log.out.println(" Fluid in chunk = " + tFluid.getFluid().getID());
}
if (tOil.isFluidEqual(tFluid) && tFluid.amount > 0) {
mOilFieldChunks.add(tChunk);
@@ -280,8 +255,10 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
for (Chunk tChunk : mOilFieldChunks) {
tFluid = undergroundOil(tChunk, speed);
if (debugDriller) {
- GT_Log.out.println(" chunkX = " + tChunk.getChunkCoordIntPair().chunkXPos + " chunkZ = "
- + tChunk.getChunkCoordIntPair().chunkZPos);
+ GT_Log.out.println(
+ " chunkX = " + tChunk.getChunkCoordIntPair().chunkXPos
+ + " chunkZ = "
+ + tChunk.getChunkCoordIntPair().chunkZPos);
if (tFluid != null) {
GT_Log.out.println(" Fluid pumped = " + tFluid.amount);
} else {
@@ -300,18 +277,26 @@ public abstract class GT_MetaTileEntity_OilDrillBase extends GT_MetaTileEntity_D
@Override
public String[] getInfoData() {
- List<String> l = new ArrayList<>(Arrays.asList(
- EnumChatFormatting.BLUE
- + StatCollector.translateToLocal("GT5U.machines.oilfluidpump")
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.machines.workarea") + ": " + EnumChatFormatting.GREEN
- + (chunkRangeConfig) + " x " + (chunkRangeConfig) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.machines.chunks"),
- "Drilling fluid: " + EnumChatFormatting.GREEN
- + (mOilId > 0 ? FluidRegistry.getFluid(mOilId).getName() : "None") + EnumChatFormatting.RESET,
- "Drilling flow: " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(this.mMaxProgresstime > 0 ? (mOilFlow / this.mMaxProgresstime) : 0)
- + EnumChatFormatting.RESET + " L/t"));
+ List<String> l = new ArrayList<>(
+ Arrays.asList(
+ EnumChatFormatting.BLUE + StatCollector.translateToLocal("GT5U.machines.oilfluidpump")
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.machines.workarea") + ": "
+ + EnumChatFormatting.GREEN
+ + (chunkRangeConfig)
+ + " x "
+ + (chunkRangeConfig)
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.machines.chunks"),
+ "Drilling fluid: " + EnumChatFormatting.GREEN
+ + (mOilId > 0 ? FluidRegistry.getFluid(mOilId).getName() : "None")
+ + EnumChatFormatting.RESET,
+ "Drilling flow: " + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(
+ this.mMaxProgresstime > 0 ? (mOilFlow / this.mMaxProgresstime) : 0)
+ + EnumChatFormatting.RESET
+ + " L/t"));
l.addAll(Arrays.asList(super.getInfoData()));
return l.toArray(new String[0]);
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillInfinite.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillInfinite.java
index 6fa7c00f0f..e54fcbbd28 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillInfinite.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OilDrillInfinite.java
@@ -2,15 +2,17 @@ package gregtech.common.tileentities.machines.multi;
import static gregtech.api.enums.GT_Values.VN;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.enums.ItemList;
import gregtech.api.enums.Materials;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Utility;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_OilDrillInfinite extends GT_MetaTileEntity_OilDrillBase {
+
public GT_MetaTileEntity_OilDrillInfinite(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
@@ -24,20 +26,15 @@ public class GT_MetaTileEntity_OilDrillInfinite extends GT_MetaTileEntity_OilDri
String casings = getCasingBlockItem().get(0).getDisplayName();
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Pump")
- .addInfo("Controller Block for the Infinite Oil/Gas/Fluid Drilling Rig ")
- .addInfo("Works on " + getRangeInChunks() + "x" + getRangeInChunks() + " chunks")
- .addSeparator()
- .beginStructureBlock(3, 7, 3, false)
- .addController("Front bottom")
+ tt.addMachineType("Pump").addInfo("Controller Block for the Infinite Oil/Gas/Fluid Drilling Rig ")
+ .addInfo("Works on " + getRangeInChunks() + "x" + getRangeInChunks() + " chunks").addSeparator()
+ .beginStructureBlock(3, 7, 3, false).addController("Front bottom")
.addOtherStructurePart(casings, "form the 3x1x3 Base")
.addOtherStructurePart(casings, "1x3x1 pillar above the center of the base (2 minimum total)")
.addOtherStructurePart(getFrameMaterial().mName + " Frame Boxes", "Each pillar's side and 1x3x1 on top")
- .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1)
- .addMaintenanceHatch("Any base casing", 1)
+ .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1).addMaintenanceHatch("Any base casing", 1)
.addInputBus("Mining Pipes or Circuits, optional, any base casing", 1)
- .addOutputHatch("Any base casing", 1)
- .toolTipFinisher("Gregtech");
+ .addOutputHatch("Any base casing", 1).toolTipFinisher("Gregtech");
return tt;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant1.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant1.java
index 859f826320..50edf8928a 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant1.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant1.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_OreDrillingPlant1 extends GT_MetaTileEntity_OreDrillingPlantBase {
+
public GT_MetaTileEntity_OreDrillingPlant1(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
mTier = 1;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant2.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant2.java
index e178bdab83..6a80c96d26 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant2.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant2.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_OreDrillingPlant2 extends GT_MetaTileEntity_OreDrillingPlantBase {
+
public GT_MetaTileEntity_OreDrillingPlant2(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
mTier = 2;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant3.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant3.java
index b8ac96a8a7..2bb25b2254 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant3.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant3.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_OreDrillingPlant3 extends GT_MetaTileEntity_OreDrillingPlantBase {
+
public GT_MetaTileEntity_OreDrillingPlant3(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
mTier = 3;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant4.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant4.java
index e4a3da16ac..7ba26b9500 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant4.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlant4.java
@@ -7,6 +7,7 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
public class GT_MetaTileEntity_OreDrillingPlant4 extends GT_MetaTileEntity_OreDrillingPlantBase {
+
public GT_MetaTileEntity_OreDrillingPlant4(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
mTier = 4;
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlantBase.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlantBase.java
index 80b3660eb3..1f5bdf690e 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlantBase.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_OreDrillingPlantBase.java
@@ -5,24 +5,12 @@ import static gregtech.api.enums.GT_HatchElement.Energy;
import static gregtech.api.enums.GT_HatchElement.Maintenance;
import static gregtech.api.enums.GT_Values.VN;
-import com.google.common.collect.ImmutableList;
-import gregtech.api.enums.ItemList;
-import gregtech.api.enums.Materials;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.IHatchElement;
-import gregtech.api.objects.GT_ChunkManager;
-import gregtech.api.objects.ItemData;
-import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import gregtech.api.util.GT_OreDictUnificator;
-import gregtech.api.util.GT_Recipe;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.blocks.GT_Block_Ores_Abstract;
-import gregtech.common.blocks.GT_TileEntity_Ores;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
@@ -34,7 +22,23 @@ import net.minecraft.world.ChunkCoordIntPair;
import net.minecraft.world.ChunkPosition;
import net.minecraftforge.fluids.FluidStack;
+import com.google.common.collect.ImmutableList;
+
+import gregtech.api.enums.ItemList;
+import gregtech.api.enums.Materials;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IHatchElement;
+import gregtech.api.objects.GT_ChunkManager;
+import gregtech.api.objects.ItemData;
+import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
+import gregtech.api.util.GT_OreDictUnificator;
+import gregtech.api.util.GT_Recipe;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.blocks.GT_Block_Ores_Abstract;
+import gregtech.common.blocks.GT_TileEntity_Ores;
+
public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTileEntity_DrillerBase {
+
private final ArrayList<ChunkPosition> oreBlockPositions = new ArrayList<>();
protected int mTier = 1;
private int chunkRadiusConfig = getRadiusInChunks();
@@ -82,21 +86,23 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
}
GT_Utility.sendChatToPlayer(
aPlayer,
- StatCollector.translateToLocal("GT5U.machines.workareaset") + " " + (chunkRadiusConfig << 4) + " "
+ StatCollector.translateToLocal("GT5U.machines.workareaset") + " "
+ + (chunkRadiusConfig << 4)
+ + " "
+ StatCollector.translateToLocal("GT5U.machines.radius"));
}
@Override
- public boolean onWireCutterRightClick(
- byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public boolean onWireCutterRightClick(byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY,
+ float aZ) {
replaceWithCobblestone = !replaceWithCobblestone;
GT_Utility.sendChatToPlayer(aPlayer, "Replace with cobblestone " + replaceWithCobblestone);
return true;
}
@Override
- protected boolean workingDownward(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingDownward(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
if (yHead != oldYHead) oreBlockPositions.clear();
if (mWorkChunkNeedsReload && mChunkLoadingEnabled) { // ask to load machine itself
@@ -152,12 +158,10 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
Collection<ItemStack> oreBlockDrops = getBlockDrops(oreBlock, x, y, z);
ItemStack cobble = GT_Utility.getCobbleForOre(oreBlock, metaData);
if (replaceWithCobblestone) {
- getBaseMetaTileEntity()
- .getWorld()
+ getBaseMetaTileEntity().getWorld()
.setBlock(x, y, z, Block.getBlockFromItem(cobble.getItem()), cobble.getItemDamage(), 3);
} else {
- getBaseMetaTileEntity()
- .getWorld()
+ getBaseMetaTileEntity().getWorld()
.setBlockToAir(oreBlockPos.chunkPosX, oreBlockPos.chunkPosY, oreBlockPos.chunkPosZ);
}
mOutputItems = getOutputByDrops(oreBlockDrops);
@@ -166,8 +170,8 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
}
@Override
- protected boolean workingAtBottom(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingAtBottom(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
if (!mChunkLoadingEnabled)
return super.workingAtBottom(aStack, xDrill, yDrill, zDrill, xPipe, zPipe, yHead, oldYHead);
@@ -198,15 +202,16 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
// use corner closest to the drill as mining area center
final int leftRight = (getXDrill() - (centerX << 4)) < 8 ? 0 : 1;
final int topBottom = (getZDrill() - (centerZ << 4)) < 8 ? 0 : 1;
- mCurrentChunk =
- new ChunkCoordIntPair(centerX - chunkRadiusConfig + leftRight, centerZ - chunkRadiusConfig + topBottom);
+ mCurrentChunk = new ChunkCoordIntPair(
+ centerX - chunkRadiusConfig + leftRight,
+ centerZ - chunkRadiusConfig + topBottom);
GT_ChunkManager.requestChunkLoad((TileEntity) getBaseMetaTileEntity(), mCurrentChunk);
mWorkChunkNeedsReload = false;
}
@Override
- protected boolean workingUpward(
- ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe, int yHead, int oldYHead) {
+ protected boolean workingUpward(ItemStack aStack, int xDrill, int yDrill, int zDrill, int xPipe, int zPipe,
+ int yHead, int oldYHead) {
if (!mChunkLoadingEnabled || oreBlockPositions.isEmpty())
return super.workingUpward(aStack, xDrill, yDrill, zDrill, xPipe, zPipe, yHead, oldYHead);
boolean result = processOreList();
@@ -244,15 +249,14 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
return false;
}
mCurrentChunk = new ChunkCoordIntPair(nextChunkX, nextChunkZ);
- GT_ChunkManager.requestChunkLoad(
- (TileEntity) getBaseMetaTileEntity(), new ChunkCoordIntPair(nextChunkX, nextChunkZ));
+ GT_ChunkManager
+ .requestChunkLoad((TileEntity) getBaseMetaTileEntity(), new ChunkCoordIntPair(nextChunkX, nextChunkZ));
return true;
}
@Override
protected boolean checkHatches() {
- return !mMaintenanceHatches.isEmpty()
- && !mInputHatches.isEmpty()
+ return !mMaintenanceHatches.isEmpty() && !mInputHatches.isEmpty()
&& !mOutputBusses.isEmpty()
&& !mEnergyHatches.isEmpty();
}
@@ -268,9 +272,8 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
this.mEfficiencyIncrease = 10000;
int tier = Math.max(1, GT_Utility.getTier(getMaxInputVoltage()));
this.mEUt = -3 * (1 << (tier << 1));
- this.mMaxProgresstime =
- ((workState == STATE_DOWNWARD || workState == STATE_AT_BOTTOM) ? getBaseProgressTime() : 80)
- / (1 << tier);
+ this.mMaxProgresstime = ((workState == STATE_DOWNWARD || workState == STATE_AT_BOTTOM) ? getBaseProgressTime()
+ : 80) / (1 << tier);
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
}
@@ -282,8 +285,8 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
outputItems.add(multiplyStackSize(currentItem));
return;
}
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sMaceratorRecipes.findRecipe(
- getBaseMetaTileEntity(), false, voltage, null, currentItem);
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sMaceratorRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, voltage, null, currentItem);
if (tRecipe == null) {
outputItems.add(currentItem);
return;
@@ -300,16 +303,14 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
private boolean doUseMaceratorRecipe(ItemStack currentItem) {
ItemData itemData = GT_OreDictUnificator.getItemData(currentItem);
- return itemData == null
- || itemData.mPrefix != OrePrefixes.crushed
- && itemData.mPrefix != OrePrefixes.dustImpure
- && itemData.mPrefix != OrePrefixes.dust
- && itemData.mPrefix != OrePrefixes.gem
- && itemData.mPrefix != OrePrefixes.gemChipped
- && itemData.mPrefix != OrePrefixes.gemExquisite
- && itemData.mPrefix != OrePrefixes.gemFlawed
- && itemData.mPrefix != OrePrefixes.gemFlawless
- && itemData.mMaterial.mMaterial != Materials.Oilsands;
+ return itemData == null || itemData.mPrefix != OrePrefixes.crushed && itemData.mPrefix != OrePrefixes.dustImpure
+ && itemData.mPrefix != OrePrefixes.dust
+ && itemData.mPrefix != OrePrefixes.gem
+ && itemData.mPrefix != OrePrefixes.gemChipped
+ && itemData.mPrefix != OrePrefixes.gemExquisite
+ && itemData.mPrefix != OrePrefixes.gemFlawed
+ && itemData.mPrefix != OrePrefixes.gemFlawless
+ && itemData.mMaterial.mMaterial != Materials.Oilsands;
}
private ItemStack multiplyStackSize(ItemStack itemStack) {
@@ -355,9 +356,8 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
for (int z = startZ; z < (startZ + 16); ++z) tryAddOreBlockToMineList(x, yHead, z);
} else {
int radius = chunkRadiusConfig << 4;
- for (int xOff = -radius; xOff <= radius; xOff++)
- for (int zOff = -radius; zOff <= radius; zOff++)
- tryAddOreBlockToMineList(xDrill + xOff, yHead, zDrill + zOff);
+ for (int xOff = -radius; xOff <= radius; xOff++) for (int zOff = -radius; zOff <= radius; zOff++)
+ tryAddOreBlockToMineList(xDrill + xOff, yHead, zDrill + zOff);
}
}
@@ -390,18 +390,14 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
.addInfo("Use Wire Cutter to toggle replacing mined blocks with cobblestone")
.addInfo("In chunk mode, working area center is the chunk corner nearest to the drill")
.addInfo("Gives ~3x as much crushed ore vs normal processing")
- .addInfo("Fortune bonus of " + (mTier + 3) + ". Only works on small ores")
- .addSeparator()
- .beginStructureBlock(3, 7, 3, false)
- .addController("Front bottom")
+ .addInfo("Fortune bonus of " + (mTier + 3) + ". Only works on small ores").addSeparator()
+ .beginStructureBlock(3, 7, 3, false).addController("Front bottom")
.addOtherStructurePart(casings, "form the 3x1x3 Base")
.addOtherStructurePart(casings, "1x3x1 pillar above the center of the base (2 minimum total)")
.addOtherStructurePart(getFrameMaterial().mName + " Frame Boxes", "Each pillar's side and 1x3x1 on top")
- .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1)
- .addMaintenanceHatch("Any base casing", 1)
+ .addEnergyHatch(VN[getMinTier()] + "+, Any base casing", 1).addMaintenanceHatch("Any base casing", 1)
.addInputBus("Mining Pipes, optional, any base casing", 1)
- .addInputHatch("Drilling Fluid, any base casing", 1)
- .addOutputBus("Any base casing", 1)
+ .addInputHatch("Drilling Fluid, any base casing", 1).addOutputBus("Any base casing", 1)
.toolTipFinisher("Gregtech");
return tt;
}
@@ -410,11 +406,15 @@ public abstract class GT_MetaTileEntity_OreDrillingPlantBase extends GT_MetaTile
public String[] getInfoData() {
final int diameter = chunkRadiusConfig * 2;
return new String[] {
- EnumChatFormatting.BLUE
- + StatCollector.translateToLocal("GT5U.machines.minermulti")
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.machines.workarea") + ": " + EnumChatFormatting.GREEN + diameter + "x"
- + diameter + EnumChatFormatting.RESET + " " + StatCollector.translateToLocal("GT5U.machines.chunks")
- };
+ EnumChatFormatting.BLUE + StatCollector.translateToLocal("GT5U.machines.minermulti")
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.machines.workarea") + ": "
+ + EnumChatFormatting.GREEN
+ + diameter
+ + "x"
+ + diameter
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.machines.chunks") };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PCBFactory.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PCBFactory.java
index 06969bb55b..fb16756d40 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PCBFactory.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PCBFactory.java
@@ -10,6 +10,18 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_ASSEMBLY_LINE
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofFrame;
+import java.util.ArrayList;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.alignment.enumerable.ExtendedFacing;
import com.gtnewhorizon.structurelib.alignment.enumerable.Flip;
@@ -30,6 +42,7 @@ import com.gtnewhorizons.modularui.common.widget.DynamicPositionedRow;
import com.gtnewhorizons.modularui.common.widget.MultiChildWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
import com.gtnewhorizons.modularui.common.widget.textfield.TextFieldWidget;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.Materials;
import gregtech.api.enums.OrePrefixes;
@@ -53,21 +66,11 @@ import gregtech.api.util.GT_ParallelHelper;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.common.blocks.GT_Block_Casings8;
-import java.util.ArrayList;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
@SuppressWarnings("SpellCheckingInspection")
-public class GT_MetaTileEntity_PCBFactory
- extends GT_MetaTileEntity_ExtendedPowerMultiBlockBase<GT_MetaTileEntity_PCBFactory>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_PCBFactory extends
+ GT_MetaTileEntity_ExtendedPowerMultiBlockBase<GT_MetaTileEntity_PCBFactory> implements ISurvivalConstructable {
+
private static final String tier1 = "tier1";
private static final String tier2 = "tier2";
private static final String tier3 = "tier3";
@@ -78,9 +81,8 @@ public class GT_MetaTileEntity_PCBFactory
private float mRoughnessMultiplier = 1;
private int mTier = 1, mSetTier = 1, mUpgradesInstalled = 0, mCurrentParallel = 0, mMaxParallel = 0;
private boolean mBioUpgrade = false, mBioRotate = false, mOCTier1 = false, mOCTier2 = false;
- private int[] mBioOffsets = new int[] {-5, -1},
- mOCTier1Offsets = new int[] {2, -11},
- mOCTier2Offsets = new int[] {2, -11};
+ private int[] mBioOffsets = new int[] { -5, -1 }, mOCTier1Offsets = new int[] { 2, -11 },
+ mOCTier2Offsets = new int[] { 2, -11 };
private GT_MetaTileEntity_Hatch_Input mCoolantInputHatch;
private static final int mBioRotateBitMap = 0b1000000;
private static final int mOCTier2BitMap = 0b100000;
@@ -90,10 +92,12 @@ public class GT_MetaTileEntity_PCBFactory
private static final int mTier2BitMap = 0b10;
private static final int mTier1BitMap = 0b1;
private static final int COOLANT_CONSUMED_PER_SEC = 10;
- private static final IStructureDefinition<GT_MetaTileEntity_PCBFactory> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_PCBFactory>builder()
- .addShape(tier1, transpose(new String[][] {
- // spotless:off
+ private static final IStructureDefinition<GT_MetaTileEntity_PCBFactory> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_PCBFactory>builder().addShape(
+ tier1,
+ transpose(
+ new String[][] {
+ // spotless:off
{" ","E E","E E","EEEEEEE","E E","E E"," "},
{"EEEEEEE","CAAAAAC","CAAAAAC","CCCCCCC","CCCCCCC","CCCCCCC","E E"},
{"EAAAAAE","C-----C","C-----C","C-----C","C-----C","C-----C","ECCCCCE"},
@@ -101,9 +105,11 @@ public class GT_MetaTileEntity_PCBFactory
{"EAAAAAE","C-----C","B-FFF-B","B-FFF-B","B-FFF-B","C-----C","EPPPPPE"},
{"ECC~CCE","CDDDDDC","CDDDDDC","CDDDDDC","CDDDDDC","CDDDDDC","EPPPPPE"}
//spotless:on
- }))
- .addShape(tier2, transpose(new String[][] {
- // spotless:off
+ })).addShape(
+ tier2,
+ transpose(
+ new String[][] {
+ // spotless:off
{" "," "," ","HGGH","HGGH","HGGH","HGGH","HGGH"," "," "," "},
{" "," ","HGGH","GGGG","GGGG","GGGG","GGGG","GGGG","HGGH"," "," "},
{" ","HGGH","GGGG","G G","G G","G G","G G","G G","GGGG","HGGH"," "},
@@ -112,9 +118,11 @@ public class GT_MetaTileEntity_PCBFactory
{"HGGH","G G","G G","G G","G G","G G","G G","G G","G G","G G","HGGH"},
{"HGGH","GGGG","GGGG","GGGG","GGGG","GGGG","GGGG","GGGG","GGGG","GGGG","HGGH"}
//spotless:on
- }))
- .addShape(tier3, transpose(new String[][] {
- // spotless:off
+ })).addShape(
+ tier3,
+ transpose(
+ new String[][] {
+ // spotless:off
{" "," "," "," "," I "," I "," "," "," "," "},
{" "," "," "," I "," I "," I "," I "," "," "," "},
{" "," "," KKK "," KIK "," K K "," K K "," I "," "," "," "},
@@ -138,9 +146,11 @@ public class GT_MetaTileEntity_PCBFactory
{" "," III "," I I "," I I "," I I "," I I "," I I "," I I "," III "," "},
{" II~II ","IIJJJII","IJJJJJI","IJJJJJI","IJJJJJI","IJJJJJI","IJJJJJI","IJJJJJI","IIJJJII"," IIIII "}
//spotless:on
- }))
- .addShape(bioUpgrade, transpose(new String[][] {
- // spotless:off
+ })).addShape(
+ bioUpgrade,
+ transpose(
+ new String[][] {
+ // spotless:off
{" "," "," LLLLLL "," "," "},
{" "," "," L L "," "," "},
{"E E E E"," LLL LLL "," LLL LLL "," LLL LLL ","E E E E"},
@@ -149,9 +159,12 @@ public class GT_MetaTileEntity_PCBFactory
{"EAAAE EAAAE","A A A A","A A A A","A A A A","EAAAE EAAAE"},
{"ELLLE ELLLE","LLLLL LLLLL","LLLLL LLLLL","LLLLL LLLLL","ELLLE ELLLE"}
//spotless:on
- }))
- .addShape(ocTier1Upgrade, transpose(new String[][] {
- // spotless:off
+ }))
+ .addShape(
+ ocTier1Upgrade,
+ transpose(
+ new String[][] {
+ // spotless:off
{"EKKKE","K K","K K","K K","EKKKE"},
{"E E"," KKK "," K K "," KKK ","E E"},
{"E E"," NNN "," N N "," NNN ","E E"},
@@ -163,9 +176,11 @@ public class GT_MetaTileEntity_PCBFactory
{"ENNNE","NKKKN","NK KN","NKKKN","ENNNE"},
{"EGGGE","GGGGG","GGMGG","GGGGG","EGGGE"}
//spotless:on
- }))
- .addShape(ocTier2Upgrade, transpose(new String[][] {
- // spotless:off
+ })).addShape(
+ ocTier2Upgrade,
+ transpose(
+ new String[][] {
+ // spotless:off
{"RGGGR","G G","G G","G G","RGGGR"},
{"R R"," GGG "," GTG "," GGG ","R R"},
{"R R"," NNN "," NTN "," NNN ","R R"},
@@ -177,61 +192,50 @@ public class GT_MetaTileEntity_PCBFactory
{"RNNNR","NQQQN","NQTQN","NQQQN","RNNNR"},
{"RGGGR","GGGGG","GGSGG","GGGGG","RGGGR"}
//spotless:on
- }))
- .addElement('E', ofFrame(Materials.DamascusSteel))
- .addElement('C', ofBlock(GregTech_API.sBlockCasings8, 11))
- .addElement('D', ofBlock(GregTech_API.sBlockReinforced, 2))
- .addElement(
- 'A',
- ofChain(
- ofBlockUnlocalizedName("IC2", "blockAlloyGlass", 0, true),
- ofBlockUnlocalizedName("bartworks", "BW_GlasBlocks", 0, true),
- ofBlockUnlocalizedName("bartworks", "BW_GlasBlocks2", 0, true),
- // warded glass
- ofBlockUnlocalizedName("Thaumcraft", "blockCosmeticOpaque", 2, false)))
- .addElement('B', ofBlock(GregTech_API.sBlockCasings3, 10))
- .addElement('F', ofFrame(Materials.VibrantAlloy))
- .addElement(
- 'P',
- buildHatchAdder(GT_MetaTileEntity_PCBFactory.class)
- .atLeast(InputHatch, OutputBus, InputBus, Maintenance, Energy.or(ExoticEnergy))
- .dot(1)
- .casingIndex(((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(11))
- .buildAndChain(GregTech_API.sBlockCasings8, 11))
- .addElement('H', ofFrame(Materials.Duranium))
- .addElement('G', ofBlock(GregTech_API.sBlockCasings8, 12))
- .addElement('I', ofBlock(GregTech_API.sBlockCasings8, 13))
- .addElement('K', ofBlock(GregTech_API.sBlockCasings8, 10))
- .addElement(
- 'J',
- buildHatchAdder(GT_MetaTileEntity_PCBFactory.class)
- .atLeast(InputHatch, OutputBus, InputBus, Maintenance, Energy.or(ExoticEnergy))
- .dot(1)
- .casingIndex(((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(13))
- .buildAndChain(GregTech_API.sBlockCasings8, 13))
- .addElement('L', ofBlock(GregTech_API.sBlockCasings4, 1))
- .addElement(
- 'M',
- buildHatchAdder(GT_MetaTileEntity_PCBFactory.class)
- .hatchClass(GT_MetaTileEntity_Hatch_Input.class)
- .adder(GT_MetaTileEntity_PCBFactory::addCoolantInputToMachineList)
- .casingIndex(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 12))
- .dot(2)
- .buildAndChain(GregTech_API.sBlockCasings8, 12))
- .addElement('N', ofBlock(GregTech_API.sBlockCasings2, 15))
- .addElement('O', ofBlock(GregTech_API.sBlockCasings8, 4))
- .addElement(
- 'S',
- buildHatchAdder(GT_MetaTileEntity_PCBFactory.class)
- .hatchClass(GT_MetaTileEntity_Hatch_Input.class)
- .adder(GT_MetaTileEntity_PCBFactory::addCoolantInputToMachineList)
- .casingIndex(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 12))
- .dot(2)
- .buildAndChain(GregTech_API.sBlockCasings8, 12))
- .addElement('R', ofFrame(Materials.Americium))
- .addElement('Q', ofBlock(GregTech_API.sBlockCasings8, 14))
- .addElement('T', ofBlock(GregTech_API.sBlockCasings1, 15))
- .build();
+ })).addElement('E', ofFrame(Materials.DamascusSteel))
+ .addElement('C', ofBlock(GregTech_API.sBlockCasings8, 11))
+ .addElement('D', ofBlock(GregTech_API.sBlockReinforced, 2))
+ .addElement(
+ 'A',
+ ofChain(
+ ofBlockUnlocalizedName("IC2", "blockAlloyGlass", 0, true),
+ ofBlockUnlocalizedName("bartworks", "BW_GlasBlocks", 0, true),
+ ofBlockUnlocalizedName("bartworks", "BW_GlasBlocks2", 0, true),
+ // warded glass
+ ofBlockUnlocalizedName("Thaumcraft", "blockCosmeticOpaque", 2, false)))
+ .addElement('B', ofBlock(GregTech_API.sBlockCasings3, 10)).addElement('F', ofFrame(Materials.VibrantAlloy))
+ .addElement(
+ 'P',
+ buildHatchAdder(GT_MetaTileEntity_PCBFactory.class)
+ .atLeast(InputHatch, OutputBus, InputBus, Maintenance, Energy.or(ExoticEnergy)).dot(1)
+ .casingIndex(((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(11))
+ .buildAndChain(GregTech_API.sBlockCasings8, 11))
+ .addElement('H', ofFrame(Materials.Duranium)).addElement('G', ofBlock(GregTech_API.sBlockCasings8, 12))
+ .addElement('I', ofBlock(GregTech_API.sBlockCasings8, 13))
+ .addElement('K', ofBlock(GregTech_API.sBlockCasings8, 10))
+ .addElement(
+ 'J',
+ buildHatchAdder(GT_MetaTileEntity_PCBFactory.class)
+ .atLeast(InputHatch, OutputBus, InputBus, Maintenance, Energy.or(ExoticEnergy)).dot(1)
+ .casingIndex(((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(13))
+ .buildAndChain(GregTech_API.sBlockCasings8, 13))
+ .addElement('L', ofBlock(GregTech_API.sBlockCasings4, 1))
+ .addElement(
+ 'M',
+ buildHatchAdder(GT_MetaTileEntity_PCBFactory.class).hatchClass(GT_MetaTileEntity_Hatch_Input.class)
+ .adder(GT_MetaTileEntity_PCBFactory::addCoolantInputToMachineList)
+ .casingIndex(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 12)).dot(2)
+ .buildAndChain(GregTech_API.sBlockCasings8, 12))
+ .addElement('N', ofBlock(GregTech_API.sBlockCasings2, 15))
+ .addElement('O', ofBlock(GregTech_API.sBlockCasings8, 4))
+ .addElement(
+ 'S',
+ buildHatchAdder(GT_MetaTileEntity_PCBFactory.class).hatchClass(GT_MetaTileEntity_Hatch_Input.class)
+ .adder(GT_MetaTileEntity_PCBFactory::addCoolantInputToMachineList)
+ .casingIndex(GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 12)).dot(2)
+ .buildAndChain(GregTech_API.sBlockCasings8, 12))
+ .addElement('R', ofFrame(Materials.Americium)).addElement('Q', ofBlock(GregTech_API.sBlockCasings8, 14))
+ .addElement('T', ofBlock(GregTech_API.sBlockCasings1, 15)).build();
@Override
public void construct(ItemStack stackSize, boolean hintsOnly) {
@@ -247,20 +251,19 @@ public class GT_MetaTileEntity_PCBFactory
if (mBioUpgrade) {
if (mBioRotate) {
final IGregTechTileEntity tTile = getBaseMetaTileEntity();
- getStructureDefinition()
- .buildOrHints(
- this,
- stackSize,
- bioUpgrade,
- tTile.getWorld(),
- transformFacing(getExtendedFacing()),
- tTile.getXCoord(),
- tTile.getYCoord(),
- tTile.getZCoord(),
- mBioOffsets[1],
- 6,
- mBioOffsets[0],
- hintsOnly);
+ getStructureDefinition().buildOrHints(
+ this,
+ stackSize,
+ bioUpgrade,
+ tTile.getWorld(),
+ transformFacing(getExtendedFacing()),
+ tTile.getXCoord(),
+ tTile.getYCoord(),
+ tTile.getZCoord(),
+ mBioOffsets[1],
+ 6,
+ mBioOffsets[0],
+ hintsOnly);
} else {
buildPiece(bioUpgrade, stackSize, hintsOnly, mBioOffsets[0], 6, mBioOffsets[1]);
}
@@ -290,25 +293,32 @@ public class GT_MetaTileEntity_PCBFactory
if (mBioUpgrade) {
if (mBioRotate) {
final IGregTechTileEntity tTile = getBaseMetaTileEntity();
- getStructureDefinition()
- .survivalBuild(
- this,
- stackSize,
- bioUpgrade,
- tTile.getWorld(),
- transformFacing(getExtendedFacing()),
- tTile.getXCoord(),
- tTile.getYCoord(),
- tTile.getZCoord(),
- mBioOffsets[1],
- 6,
- mBioOffsets[0],
- elementBudget,
- env,
- false);
+ getStructureDefinition().survivalBuild(
+ this,
+ stackSize,
+ bioUpgrade,
+ tTile.getWorld(),
+ transformFacing(getExtendedFacing()),
+ tTile.getXCoord(),
+ tTile.getYCoord(),
+ tTile.getZCoord(),
+ mBioOffsets[1],
+ 6,
+ mBioOffsets[0],
+ elementBudget,
+ env,
+ false);
} else {
built += survivialBuildPiece(
- bioUpgrade, stackSize, mBioOffsets[0], 6, mBioOffsets[1], elementBudget, env, false, true);
+ bioUpgrade,
+ stackSize,
+ mBioOffsets[0],
+ 6,
+ mBioOffsets[1],
+ elementBudget,
+ env,
+ false,
+ true);
}
}
@@ -354,52 +364,26 @@ public class GT_MetaTileEntity_PCBFactory
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
+ if (aActive) return new ITexture[] {
BlockIcons.getCasingTextureForId(
- getTier() < 3
- ? GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 11)
+ getTier() < 3 ? GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 11)
: GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 13)),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_ACTIVE_GLOW).extFacing().glow()
+ .build() };
return new ITexture[] {
- BlockIcons.getCasingTextureForId(
- getTier() < 3
- ? GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 11)
- : GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 13)),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ BlockIcons.getCasingTextureForId(
+ getTier() < 3 ? GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 11)
+ : GT_Utility.getCasingTextureIndex(GregTech_API.sBlockCasings8, 13)),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ASSEMBLY_LINE_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {
- BlockIcons.getCasingTextureForId(
- mSetTier < 3
- ? ((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(11)
- : ((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(13))
- };
+ return new ITexture[] { BlockIcons.getCasingTextureForId(
+ mSetTier < 3 ? ((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(11)
+ : ((GT_Block_Casings8) GregTech_API.sBlockCasings8).getTextureIndex(13)) };
}
@Override
@@ -434,19 +418,18 @@ public class GT_MetaTileEntity_PCBFactory
if (mBioUpgrade) {
if (mBioRotate) {
final IGregTechTileEntity tTile = getBaseMetaTileEntity();
- if (!getStructureDefinition()
- .check(
- this,
- bioUpgrade,
- tTile.getWorld(),
- transformFacing(getExtendedFacing()),
- tTile.getXCoord(),
- tTile.getYCoord(),
- tTile.getZCoord(),
- mBioOffsets[1],
- 6,
- mBioOffsets[0],
- !mMachine)) {
+ if (!getStructureDefinition().check(
+ this,
+ bioUpgrade,
+ tTile.getWorld(),
+ transformFacing(getExtendedFacing()),
+ tTile.getXCoord(),
+ tTile.getYCoord(),
+ tTile.getZCoord(),
+ mBioOffsets[1],
+ 6,
+ mBioOffsets[0],
+ !mMachine)) {
return false;
}
} else {
@@ -479,8 +462,7 @@ public class GT_MetaTileEntity_PCBFactory
getBaseMetaTileEntity().sendBlockEvent(GregTechTileClientEvents.CHANGE_CUSTOM_DATA, getUpdateData());
- if (mMaintenanceHatches.size() != 1
- || mOutputBusses.isEmpty()
+ if (mMaintenanceHatches.size() != 1 || mOutputBusses.isEmpty()
|| mInputBusses.isEmpty()
|| mInputHatches.isEmpty()) {
return false;
@@ -521,8 +503,8 @@ public class GT_MetaTileEntity_PCBFactory
return false;
}
- private boolean processRecipe(
- ItemStack aStack, ItemStack[] aItemInputs, FluidStack[] aFluidInputs, GT_Recipe.GT_Recipe_Map aMap) {
+ private boolean processRecipe(ItemStack aStack, ItemStack[] aItemInputs, FluidStack[] aFluidInputs,
+ GT_Recipe.GT_Recipe_Map aMap) {
mOutputItems = null;
mOutputFluids = null;
if (aItemInputs == null || aFluidInputs == null) {
@@ -533,8 +515,8 @@ public class GT_MetaTileEntity_PCBFactory
long amps = getMaxInputAmps();
int tier = GT_Utility.getTier(voltage);
- GT_Recipe tRecipe =
- aMap.findRecipe(getBaseMetaTileEntity(), null, true, false, V[tier], aFluidInputs, aStack, aItemInputs);
+ GT_Recipe tRecipe = aMap
+ .findRecipe(getBaseMetaTileEntity(), null, true, false, V[tier], aFluidInputs, aStack, aItemInputs);
if (tRecipe == null) {
return false;
@@ -562,20 +544,14 @@ public class GT_MetaTileEntity_PCBFactory
}
boolean recipeAllowed = (((recipeBitMap & mTier1BitMap) == mTier1BitMap && (mTier >= 1))
- || ((recipeBitMap & mTier2BitMap) == mTier2BitMap && (mTier >= 2))
- || ((recipeBitMap & mTier3BitMap) == mTier3BitMap && (mTier >= 3)))
+ || ((recipeBitMap & mTier2BitMap) == mTier2BitMap && (mTier >= 2))
+ || ((recipeBitMap & mTier3BitMap) == mTier3BitMap && (mTier >= 3)))
&& ((recipeBitMap & mBioBitMap) == 0 || ((recipeBitMap & mBioBitMap) == mBioBitMap && mBioUpgrade));
if (recipeAllowed) {
- GT_ParallelHelper helper = new GT_ParallelHelper()
- .setRecipe(tRecipe)
- .setItemInputs(aItemInputs)
- .setFluidInputs(aFluidInputs)
- .setMaxParallel(aMaxParallel)
- .setAvailableEUt(getMaxInputEu())
- .setEUtModifier(aExtraPower)
- .enableConsumption()
- .build();
+ GT_ParallelHelper helper = new GT_ParallelHelper().setRecipe(tRecipe).setItemInputs(aItemInputs)
+ .setFluidInputs(aFluidInputs).setMaxParallel(aMaxParallel).setAvailableEUt(getMaxInputEu())
+ .setEUtModifier(aExtraPower).enableConsumption().build();
mCurrentParallel = helper.getCurrentParallel();
if (mCurrentParallel > 0) {
@@ -585,13 +561,9 @@ public class GT_MetaTileEntity_PCBFactory
this.mMaxProgresstime = (int) Math.ceil(tRecipe.mDuration * Math.pow(mRoughnessMultiplier, 2));
if (mOCTier1 || mOCTier2) {
- GT_OverclockCalculator calc = new GT_OverclockCalculator()
- .setRecipeEUt(tRecipe.mEUt)
- .setDuration(tRecipe.mDuration)
- .setEUt(voltage)
- .setAmperage(amps)
- .setEUtDiscount(aExtraPower)
- .setSpeedBoost((float) Math.pow(mRoughnessMultiplier, 2));
+ GT_OverclockCalculator calc = new GT_OverclockCalculator().setRecipeEUt(tRecipe.mEUt)
+ .setDuration(tRecipe.mDuration).setEUt(voltage).setAmperage(amps)
+ .setEUtDiscount(aExtraPower).setSpeedBoost((float) Math.pow(mRoughnessMultiplier, 2));
if (mOCTier2) {
calc.enablePerfectOC();
}
@@ -755,8 +727,7 @@ public class GT_MetaTileEntity_PCBFactory
break;
}
} else if (curRotation == Rotation.CLOCKWISE || curRotation == Rotation.COUNTER_CLOCKWISE) {
- newFlip = curRotation == Rotation.CLOCKWISE
- ? curFlip == Flip.NONE ? Flip.NONE : Flip.HORIZONTAL
+ newFlip = curRotation == Rotation.CLOCKWISE ? curFlip == Flip.NONE ? Flip.NONE : Flip.HORIZONTAL
: curFlip != Flip.NONE ? Flip.NONE : Flip.HORIZONTAL;
newDirection = curRotation == Rotation.CLOCKWISE ? ForgeDirection.UP : ForgeDirection.DOWN;
} else {
@@ -806,8 +777,8 @@ public class GT_MetaTileEntity_PCBFactory
}
@Override
- protected void calculateOverclockedNessMultiInternal(
- long aEUt, int aDuration, int mAmperage, long maxInputVoltage, boolean perfectOC) {
+ protected void calculateOverclockedNessMultiInternal(long aEUt, int aDuration, int mAmperage, long maxInputVoltage,
+ boolean perfectOC) {
int hatches = Math.max(getExoticEnergyHatches().size(), 1);
long zMaxInputVoltage = maxInputVoltage;
long zTime = aDuration;
@@ -853,7 +824,8 @@ public class GT_MetaTileEntity_PCBFactory
public void onScrewdriverRightClick(byte aSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
mSeparate = !mSeparate;
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + mSeparate);
+ aPlayer,
+ StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + mSeparate);
}
@Override
@@ -877,42 +849,73 @@ public class GT_MetaTileEntity_PCBFactory
long amps = getMaxInputAmps();
return new String[] {
- /* 1*/ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mProgresstime / 20) + EnumChatFormatting.RESET + " s / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(mMaxProgresstime / 20) + EnumChatFormatting.RESET + " s",
- /* 2*/ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- /* 3*/ StatCollector.translateToLocal("GT5U.multiblock.usage") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(getActualEnergyUsage()) + EnumChatFormatting.RESET + " EU/t",
- /* 4*/ StatCollector.translateToLocal("GT5U.multiblock.mei") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(voltage) + EnumChatFormatting.RESET + " EU/t(*" + amps + " A)"
- + StatCollector.translateToLocal("GT5U.machines.tier")
- + ": " + EnumChatFormatting.YELLOW
- + VN[GT_Utility.getTier(voltage)] + EnumChatFormatting.RESET,
- /* 5*/ StatCollector.translateToLocal("GT5U.multiblock.problems") + ": " + EnumChatFormatting.RED
- + (getIdealStatus() - getRepairStatus()) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
- + ": " + EnumChatFormatting.YELLOW
- + Float.toString(mEfficiency / 100.0F) + EnumChatFormatting.RESET + " %",
- /* 6*/ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": " + EnumChatFormatting.GREEN
- + mPollutionReduction + EnumChatFormatting.RESET + " %",
- /* 7*/ StatCollector.translateToLocal("GT5U.multiblock.parallelism") + ": " + EnumChatFormatting.GREEN
- + mMaxParallel,
- /* 8*/ StatCollector.translateToLocal("GT5U.multiblock.curparallelism") + ": " + EnumChatFormatting.GREEN
- + mCurrentParallel
- };
+ /* 1 */ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(mMaxProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s",
+ /* 2 */ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ /* 3 */ StatCollector.translateToLocal("GT5U.multiblock.usage") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(getActualEnergyUsage())
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ /* 4 */ StatCollector.translateToLocal("GT5U.multiblock.mei") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(voltage)
+ + EnumChatFormatting.RESET
+ + " EU/t(*"
+ + amps
+ + " A)"
+ + StatCollector.translateToLocal("GT5U.machines.tier")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + VN[GT_Utility.getTier(voltage)]
+ + EnumChatFormatting.RESET,
+ /* 5 */ StatCollector.translateToLocal("GT5U.multiblock.problems") + ": "
+ + EnumChatFormatting.RED
+ + (getIdealStatus() - getRepairStatus())
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + Float.toString(mEfficiency / 100.0F)
+ + EnumChatFormatting.RESET
+ + " %",
+ /* 6 */ StatCollector.translateToLocal("GT5U.multiblock.pollution") + ": "
+ + EnumChatFormatting.GREEN
+ + mPollutionReduction
+ + EnumChatFormatting.RESET
+ + " %",
+ /* 7 */ StatCollector.translateToLocal("GT5U.multiblock.parallelism") + ": "
+ + EnumChatFormatting.GREEN
+ + mMaxParallel,
+ /* 8 */ StatCollector.translateToLocal("GT5U.multiblock.curparallelism") + ": "
+ + EnumChatFormatting.GREEN
+ + mCurrentParallel };
}
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Circuit Board Fabricator")
- .addInfo("Controller for the PCB Factory")
- .addInfo(EnumChatFormatting.GOLD.toString() + EnumChatFormatting.BOLD + "IMPORTANT!"
- + " Check the configuration menu before building.")
+ tt.addMachineType("Circuit Board Fabricator").addInfo("Controller for the PCB Factory")
+ .addInfo(
+ EnumChatFormatting.GOLD.toString() + EnumChatFormatting.BOLD
+ + "IMPORTANT!"
+ + " Check the configuration menu before building.")
.addInfo("Tier of the machine determines the available recipes.")
.addInfo("Machine tier (1-3) is set in the controller GUI.")
.addInfo("The configuration menu can be used to add upgrades.")
@@ -925,46 +928,74 @@ public class GT_MetaTileEntity_PCBFactory
.addInfo("Liquid Cooling uses 10 L/s of distilled water and enables default overclocks.")
.addInfo("Thermosink uses 10 L/s of Space Coolant and enables perfect overclocks.")
.addInfo("Trace size can be changed to modify the material usage and machine speed.")
- .addInfo(AuthorBlueWeabo)
- .beginStructureBlock(30, 38, 13, false)
- .addSeparator()
+ .addInfo(AuthorBlueWeabo).beginStructureBlock(30, 38, 13, false).addSeparator()
.addMaintenanceHatch(EnumChatFormatting.GOLD + "1", 1)
.addEnergyHatch(EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + "+", 1)
.addInputBus(EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + "+", 1)
.addOutputBus(EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + "+", 1)
.addInputHatch(EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + "+", 1)
- .addStructureInfo("Coolant Hatch (Input Hatch): " + EnumChatFormatting.GOLD + "1"
- + EnumChatFormatting.GRAY + "Center of the Liquid Cooling/Thermosink")
- .addStructureInfo(EnumChatFormatting.BLUE + "Base Multi (Tier " + EnumChatFormatting.DARK_PURPLE + 1
- + EnumChatFormatting.BLUE + "):")
+ .addStructureInfo(
+ "Coolant Hatch (Input Hatch): " + EnumChatFormatting.GOLD
+ + "1"
+ + EnumChatFormatting.GRAY
+ + "Center of the Liquid Cooling/Thermosink")
+ .addStructureInfo(
+ EnumChatFormatting.BLUE + "Base Multi (Tier "
+ + EnumChatFormatting.DARK_PURPLE
+ + 1
+ + EnumChatFormatting.BLUE
+ + "):")
.addStructureInfo(
EnumChatFormatting.GOLD + "40" + EnumChatFormatting.GRAY + " Damascus Steel Frame Box")
.addStructureInfo(EnumChatFormatting.GOLD + "9" + EnumChatFormatting.GRAY + " Vibrant Alloy Frame Box")
.addStructureInfo(EnumChatFormatting.GOLD + "25" + EnumChatFormatting.GRAY + " Reinforced Glass")
- .addStructureInfo(EnumChatFormatting.GOLD + "77" + EnumChatFormatting.GRAY
- + " Basic Photolithography Framework Casing")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "77"
+ + EnumChatFormatting.GRAY
+ + " Basic Photolithography Framework Casing")
.addStructureInfo(EnumChatFormatting.GOLD + "12" + EnumChatFormatting.GRAY + " Grate Machine Casing")
.addStructureInfo(EnumChatFormatting.GOLD + "25" + EnumChatFormatting.GRAY + " Plascrete Block")
- .addStructureInfo(EnumChatFormatting.BLUE + "Tier " + EnumChatFormatting.DARK_PURPLE + 2
- + EnumChatFormatting.BLUE + " (Adds to Tier " + EnumChatFormatting.DARK_PURPLE + 1
- + EnumChatFormatting.BLUE + "):")
+ .addStructureInfo(
+ EnumChatFormatting.BLUE + "Tier "
+ + EnumChatFormatting.DARK_PURPLE
+ + 2
+ + EnumChatFormatting.BLUE
+ + " (Adds to Tier "
+ + EnumChatFormatting.DARK_PURPLE
+ + 1
+ + EnumChatFormatting.BLUE
+ + "):")
.addStructureInfo(EnumChatFormatting.GOLD + "34" + EnumChatFormatting.GRAY + " Duranium Frame Box")
- .addStructureInfo(EnumChatFormatting.GOLD + "158" + EnumChatFormatting.GRAY
- + " Reinforced Photolithography Framework Casing")
- .addStructureInfo(EnumChatFormatting.BLUE + "Tier " + EnumChatFormatting.DARK_PURPLE + 3
- + EnumChatFormatting.BLUE + ":")
- .addStructureInfo(EnumChatFormatting.GOLD + "292" + EnumChatFormatting.GRAY
- + " Radiation Proof Photolithography Framework Casing")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "158"
+ + EnumChatFormatting.GRAY
+ + " Reinforced Photolithography Framework Casing")
+ .addStructureInfo(
+ EnumChatFormatting.BLUE + "Tier "
+ + EnumChatFormatting.DARK_PURPLE
+ + 3
+ + EnumChatFormatting.BLUE
+ + ":")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "292"
+ + EnumChatFormatting.GRAY
+ + " Radiation Proof Photolithography Framework Casing")
.addStructureInfo(
EnumChatFormatting.GOLD + "76" + EnumChatFormatting.GRAY + " Radiant Naquadah Alloy Casing")
.addStructureInfo(EnumChatFormatting.BLUE + "Biochamber Upgrade")
- .addStructureInfo(EnumChatFormatting.GOLD + "68" + EnumChatFormatting.GRAY
- + " Clean Stainless Steel Machine Casing")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "68"
+ + EnumChatFormatting.GRAY
+ + " Clean Stainless Steel Machine Casing")
.addStructureInfo(
EnumChatFormatting.GOLD + "40" + EnumChatFormatting.GRAY + " Damascus Steel Frame Box")
.addStructureInfo(EnumChatFormatting.GOLD + "72" + EnumChatFormatting.GRAY + " Reinforced Glass")
- .addStructureInfo(EnumChatFormatting.BLUE + "Liquid Cooling Tower (Tier "
- + EnumChatFormatting.DARK_PURPLE + 1 + EnumChatFormatting.BLUE + "):")
+ .addStructureInfo(
+ EnumChatFormatting.BLUE + "Liquid Cooling Tower (Tier "
+ + EnumChatFormatting.DARK_PURPLE
+ + 1
+ + EnumChatFormatting.BLUE
+ + "):")
.addStructureInfo(
EnumChatFormatting.GOLD + "40" + EnumChatFormatting.GRAY + " Damascus Steel Frame Box")
.addStructureInfo(
@@ -973,13 +1004,21 @@ public class GT_MetaTileEntity_PCBFactory
EnumChatFormatting.GOLD + "12" + EnumChatFormatting.GRAY + " Extreme Engine Intake Casing")
.addStructureInfo(
EnumChatFormatting.GOLD + "20" + EnumChatFormatting.GRAY + " Tungstensteel Pipe Casing")
- .addStructureInfo(EnumChatFormatting.GOLD + "21" + EnumChatFormatting.GRAY
- + " Reinforced Photolithography Framework Casing")
- .addStructureInfo(EnumChatFormatting.BLUE + "Thermosink Radiator(Tier " + EnumChatFormatting.DARK_PURPLE
- + 2 + EnumChatFormatting.BLUE + "):")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "21"
+ + EnumChatFormatting.GRAY
+ + " Reinforced Photolithography Framework Casing")
+ .addStructureInfo(
+ EnumChatFormatting.BLUE + "Thermosink Radiator(Tier "
+ + EnumChatFormatting.DARK_PURPLE
+ + 2
+ + EnumChatFormatting.BLUE
+ + "):")
.addStructureInfo(EnumChatFormatting.GOLD + "40" + EnumChatFormatting.GRAY + " Americium Frame Box")
- .addStructureInfo(EnumChatFormatting.GOLD + "41" + EnumChatFormatting.GRAY
- + " Reinforced Photolithography Framework Casing")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "41"
+ + EnumChatFormatting.GRAY
+ + " Reinforced Photolithography Framework Casing")
.addStructureInfo(
EnumChatFormatting.GOLD + "8" + EnumChatFormatting.GRAY + " Superconducting Coil Block")
.addStructureInfo(
@@ -1069,100 +1108,85 @@ public class GT_MetaTileEntity_PCBFactory
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
super.addUIWidgets(builder, buildContext);
buildContext.addSyncedWindow(10, this::createConfigurationWindow);
- builder.widget(new ButtonWidget()
- .setOnClick((clickData, widget) -> {
- if (!widget.isClient()) widget.getContext().openSyncedWindow(10);
- })
- .setSize(18, 18)
- .setBackground(GT_UITextures.BUTTON_STANDARD)
- .setBackground(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
- .addTooltip("Configuration Menu")
+ builder.widget(
+ new ButtonWidget().setOnClick(
+ (clickData, widget) -> { if (!widget.isClient()) widget.getContext().openSyncedWindow(10); })
+ .setSize(18, 18).setBackground(GT_UITextures.BUTTON_STANDARD)
+ .setBackground(GT_UITextures.OVERLAY_BUTTON_CYCLIC).addTooltip("Configuration Menu")
.setPos(151, 24))
- .widget(new TextWidget(new Text("Tier"))
- .setTextAlignment(Alignment.Center)
- .setScale(0.91f)
- .setSize(20, 16)
- .setPos(152, 46))
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mSetTier)
- .setSetterInt(val -> {
- mSetTier = val;
- })
- .setNumbers(1, 3)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("PCB Factory Tier")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(18, 18)
- .setPos(151, 61));
+ .widget(
+ new TextWidget(new Text("Tier")).setTextAlignment(Alignment.Center).setScale(0.91f)
+ .setSize(20, 16).setPos(152, 46))
+ .widget(
+ new TextFieldWidget().setGetterInt(() -> mSetTier).setSetterInt(val -> { mSetTier = val; })
+ .setNumbers(1, 3).setTextColor(Color.WHITE.normal).setTextAlignment(Alignment.Center)
+ .addTooltip("PCB Factory Tier").setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(18, 18).setPos(151, 61));
}
protected ModularWindow createConfigurationWindow(final EntityPlayer player) {
ModularWindow.Builder builder = ModularWindow.builder(200, 160);
builder.setBackground(GT_UITextures.BACKGROUND_SINGLEBLOCK_DEFAULT);
builder.setGuiTint(getGUIColorization());
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
- .setPos(5, 5)
- .setSize(16, 16))
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC).setPos(5, 5).setSize(16, 16))
.widget(new TextWidget("Configuration Menu").setPos(25, 9))
.widget(ButtonWidget.closeWindowButton(true).setPos(185, 3))
- .widget(new DynamicPositionedColumn()
- .setSynced(false)
- .widget(new MultiChildWidget()
- .addChild(
- new CycleButtonWidget()
- .setToggle(() -> mBioUpgrade, val -> {
+ .widget(
+ new DynamicPositionedColumn().setSynced(false)
+ .widget(
+ new MultiChildWidget()
+ .addChild(new CycleButtonWidget().setToggle(() -> mBioUpgrade, val -> {
mBioUpgrade = val;
if (!mBioUpgrade) {
GT_Utility.sendChatToPlayer(
player,
- GT_Utility.trans(
- "339.1", "Biochamber Upgrade Disabled"));
+ GT_Utility
+ .trans("339.1", "Biochamber Upgrade Disabled"));
} else {
GT_Utility.sendChatToPlayer(
player,
GT_Utility.trans("339", "Biochamber Upgrade Enabled"));
}
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
- .setSize(90, 18)
- .addTooltip(
- "Enables nanites to construct organic circuitry. Required for Bioware and Wetware boards."))
- .addChild(new DrawableWidget()
- .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
- .setSize(18, 18))
- .addChild(new TextWidget("Biochamber")
- .setTextAlignment(Alignment.Center)
- .setPos(23, 5))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new MultiChildWidget()
- .addChild(new CycleButtonWidget()
- .setToggle(() -> mBioRotate, val -> {
- mBioRotate = val;
- if (!mBioRotate) {
- GT_Utility.sendChatToPlayer(
- player,
- GT_Utility.trans("340.1", "Rotated biochamber disabled"));
- } else {
- GT_Utility.sendChatToPlayer(
- player, GT_Utility.trans("340", "Rotated biochamber enabled"));
- }
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
- .setSize(90, 18)
- .addTooltip("Rotates the biochamber by 90 degrees."))
- .addChild(new DrawableWidget()
- .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
- .setSize(18, 18))
- .addChild(new TextWidget("Bio Rotation")
- .setTextAlignment(Alignment.Center)
- .setPos(23, 5))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new MultiChildWidget()
- .addChild(
- new CycleButtonWidget()
- .setToggle(() -> mOCTier1, val -> {
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setSize(90, 18).addTooltip(
+ "Enables nanites to construct organic circuitry. Required for Bioware and Wetware boards."))
+ .addChild(
+ new DrawableWidget()
+ .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
+ .setSize(18, 18))
+ .addChild(
+ new TextWidget("Biochamber").setTextAlignment(Alignment.Center)
+ .setPos(23, 5))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new MultiChildWidget()
+ .addChild(new CycleButtonWidget().setToggle(() -> mBioRotate, val -> {
+ mBioRotate = val;
+ if (!mBioRotate) {
+ GT_Utility.sendChatToPlayer(
+ player,
+ GT_Utility
+ .trans("340.1", "Rotated biochamber disabled"));
+ } else {
+ GT_Utility.sendChatToPlayer(
+ player,
+ GT_Utility.trans("340", "Rotated biochamber enabled"));
+ }
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setSize(90, 18)
+ .addTooltip("Rotates the biochamber by 90 degrees."))
+ .addChild(
+ new DrawableWidget()
+ .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
+ .setSize(18, 18))
+ .addChild(
+ new TextWidget("Bio Rotation")
+ .setTextAlignment(Alignment.Center).setPos(23, 5))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new MultiChildWidget()
+ .addChild(new CycleButtonWidget().setToggle(() -> mOCTier1, val -> {
mOCTier1 = val;
if (!mOCTier1) {
GT_Utility.sendChatToPlayer(
@@ -1173,22 +1197,20 @@ public class GT_MetaTileEntity_PCBFactory
player,
GT_Utility.trans("341", "Tier 1 cooling enabled"));
}
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
- .setSize(90, 18)
- .addTooltip(
- "Allows for overclocking. Requires 10 L/s of distilled water. Cooling upgrades are mutually exclusive."))
- .addChild(new DrawableWidget()
- .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
- .setSize(18, 18))
- .addChild(new TextWidget("Liquid Cooling")
- .setTextAlignment(Alignment.Center)
- .setPos(20, 5))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new MultiChildWidget()
- .addChild(
- new CycleButtonWidget()
- .setToggle(() -> mOCTier2, val -> {
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setSize(90, 18).addTooltip(
+ "Allows for overclocking. Requires 10 L/s of distilled water. Cooling upgrades are mutually exclusive."))
+ .addChild(
+ new DrawableWidget()
+ .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
+ .setSize(18, 18))
+ .addChild(
+ new TextWidget("Liquid Cooling")
+ .setTextAlignment(Alignment.Center).setPos(20, 5))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new MultiChildWidget()
+ .addChild(new CycleButtonWidget().setToggle(() -> mOCTier2, val -> {
mOCTier2 = val;
if (!mOCTier2) {
GT_Utility.sendChatToPlayer(
@@ -1199,128 +1221,100 @@ public class GT_MetaTileEntity_PCBFactory
player,
GT_Utility.trans("342", "Tier 2 cooling enabled"));
}
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
- .setSize(90, 18)
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setSize(90, 18).addTooltip(
+ "Enables perfect overclocking by allowing nanites to work with extreme speed and efficiency. Uses 10 L/s of space coolant."))
+ .addChild(
+ new DrawableWidget()
+ .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
+ .setSize(18, 18))
+ .addChild(
+ new TextWidget("Thermosink").setTextAlignment(Alignment.Center)
+ .setPos(20, 5))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new TextWidget(new Text("Trace Size")).setSize(90, 18)
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()).setPos(0, 4))
+ .widget(
+ new TextFieldWidget()
+ .setGetterInt(() -> (int) ((1f / mRoughnessMultiplier) * 100f))
+ .setSetterInt(val -> { mRoughnessMultiplier = 100f / val; })
+ .setNumbers(50, 200).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center)
+ .addTooltip(
+ "Set the trace size. Smaller traces allow material savings but take longer to fabricate. Larger traces waste material but are fast. 50-200 μm.")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD).setSize(90, 16))
+ .widget(
+ new DrawableWidget().setDrawable(GT_UITextures.OVERLAY_BUTTON_CROSS)
+ .setSize(18, 18)
.addTooltip(
- "Enables perfect overclocking by allowing nanites to work with extreme speed and efficiency. Uses 10 L/s of space coolant."))
- .addChild(new DrawableWidget()
- .setDrawable(GT_UITextures.OVERLAY_BUTTON_CYCLIC)
- .setSize(18, 18))
- .addChild(new TextWidget("Thermosink")
- .setTextAlignment(Alignment.Center)
- .setPos(20, 5))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new TextWidget(new Text("Trace Size"))
- .setSize(90, 18)
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive())
- .setPos(0, 4))
- .widget(new TextFieldWidget()
- .setGetterInt(() -> (int) ((1f / mRoughnessMultiplier) * 100f))
- .setSetterInt(val -> {
- mRoughnessMultiplier = 100f / val;
- })
- .setNumbers(50, 200)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip(
- "Set the trace size. Smaller traces allow material savings but take longer to fabricate. Larger traces waste material but are fast. 50-200 μm.")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(90, 16))
- .widget(new DrawableWidget()
- .setDrawable(GT_UITextures.OVERLAY_BUTTON_CROSS)
- .setSize(18, 18)
- .addTooltip(
- new Text("Can't change configuration when running !").color(Color.RED.dark(3)))
- .setEnabled(widget -> getBaseMetaTileEntity().isActive()))
- .setPos(10, 25))
- .widget(new DynamicPositionedColumn()
- .setSynced(false)
- .widget(new TextWidget(new Text("Bio Upgrade Offsets"))
- .setSize(72, 18)
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new DynamicPositionedRow()
- .setSynced(false)
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mBioOffsets[0])
- .setSetterInt(val -> {
- mBioOffsets[0] = val;
- })
- .setNumbers(-16, 16)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("X Offset")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(36, 18))
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mBioOffsets[1])
- .setSetterInt(val -> {
- mBioOffsets[1] = val;
- })
- .setNumbers(-16, 16)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("Z Offset")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(36, 18))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new TextWidget(new Text("Cooler Tier 1 Offsets"))
- .setSize(72, 18)
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new DynamicPositionedRow()
- .setSynced(false)
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mOCTier1Offsets[0])
- .setSetterInt(val -> {
- mOCTier1Offsets[0] = val;
- })
- .setNumbers(-16, 16)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("X Offset")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(36, 18))
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mOCTier1Offsets[1])
- .setSetterInt(val -> {
- mOCTier1Offsets[1] = val;
- })
- .setNumbers(-16, 16)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("Z Offset")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(36, 18))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new TextWidget(new Text("Cooler Tier 2 Offsets"))
- .setSize(72, 18)
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .widget(new DynamicPositionedRow()
- .setSynced(false)
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mOCTier2Offsets[0])
- .setSetterInt(val -> {
- mOCTier2Offsets[0] = val;
- })
- .setNumbers(-16, 16)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("X Offset")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(36, 18))
- .widget(new TextFieldWidget()
- .setGetterInt(() -> mOCTier2Offsets[1])
- .setSetterInt(val -> {
- mOCTier2Offsets[1] = val;
- })
- .setNumbers(-16, 16)
- .setTextColor(Color.WHITE.normal)
- .setTextAlignment(Alignment.Center)
- .addTooltip("Z Offset")
- .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
- .setSize(36, 18))
- .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
- .setPos(110, 25));
+ new Text("Can't change configuration when running !")
+ .color(Color.RED.dark(3)))
+ .setEnabled(widget -> getBaseMetaTileEntity().isActive()))
+ .setPos(10, 25))
+ .widget(
+ new DynamicPositionedColumn().setSynced(false)
+ .widget(
+ new TextWidget(new Text("Bio Upgrade Offsets")).setSize(72, 18)
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new DynamicPositionedRow().setSynced(false).widget(
+ new TextFieldWidget().setGetterInt(() -> mBioOffsets[0])
+ .setSetterInt(val -> { mBioOffsets[0] = val; })
+ .setNumbers(-16, 16).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center).addTooltip("X Offset")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(36, 18))
+ .widget(
+ new TextFieldWidget().setGetterInt(() -> mBioOffsets[1])
+ .setSetterInt(val -> { mBioOffsets[1] = val; })
+ .setNumbers(-16, 16).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center)
+ .addTooltip("Z Offset")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(36, 18))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new TextWidget(new Text("Cooler Tier 1 Offsets")).setSize(72, 18)
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new DynamicPositionedRow().setSynced(false).widget(
+ new TextFieldWidget().setGetterInt(() -> mOCTier1Offsets[0])
+ .setSetterInt(val -> { mOCTier1Offsets[0] = val; })
+ .setNumbers(-16, 16).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center).addTooltip("X Offset")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(36, 18))
+ .widget(
+ new TextFieldWidget().setGetterInt(() -> mOCTier1Offsets[1])
+ .setSetterInt(val -> { mOCTier1Offsets[1] = val; })
+ .setNumbers(-16, 16).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center)
+ .addTooltip("Z Offset")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(36, 18))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new TextWidget(new Text("Cooler Tier 2 Offsets")).setSize(72, 18)
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .widget(
+ new DynamicPositionedRow().setSynced(false).widget(
+ new TextFieldWidget().setGetterInt(() -> mOCTier2Offsets[0])
+ .setSetterInt(val -> { mOCTier2Offsets[0] = val; })
+ .setNumbers(-16, 16).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center).addTooltip("X Offset")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(36, 18))
+ .widget(
+ new TextFieldWidget().setGetterInt(() -> mOCTier2Offsets[1])
+ .setSetterInt(val -> { mOCTier2Offsets[1] = val; })
+ .setNumbers(-16, 16).setTextColor(Color.WHITE.normal)
+ .setTextAlignment(Alignment.Center)
+ .addTooltip("Z Offset")
+ .setBackground(GT_UITextures.BACKGROUND_TEXT_FIELD)
+ .setSize(36, 18))
+ .setEnabled(widget -> !getBaseMetaTileEntity().isActive()))
+ .setPos(110, 25));
return builder.build();
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PlasmaForge.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PlasmaForge.java
index 60f168e05d..c231c6e935 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PlasmaForge.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PlasmaForge.java
@@ -8,10 +8,22 @@ import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofCoil;
import static java.lang.Math.*;
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.ChunkCoordIntPair;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import gregtech.api.GregTech_API;
import gregtech.api.enums.HeatingCoilLevel;
import gregtech.api.enums.Materials;
@@ -26,15 +38,6 @@ import gregtech.api.util.GT_ExoticEnergyInputHelper;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import java.util.ArrayList;
-import java.util.List;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.ChunkCoordIntPair;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMultiFurnace<GT_MetaTileEntity_PlasmaForge>
implements ISurvivalConstructable {
@@ -44,12 +47,9 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
private static final double maximum_discount = 0.5d;
// Valid fuels which the discount will get applied to.
- private static final FluidStack[] valid_fuels = {
- Materials.ExcitedDTEC.getFluid(1L),
- Materials.ExcitedDTRC.getFluid(1L),
- Materials.ExcitedDTPC.getFluid(1L),
- Materials.ExcitedDTCC.getFluid(1L),
- };
+ private static final FluidStack[] valid_fuels = { Materials.ExcitedDTEC.getFluid(1L),
+ Materials.ExcitedDTRC.getFluid(1L), Materials.ExcitedDTPC.getFluid(1L),
+ Materials.ExcitedDTCC.getFluid(1L), };
// Saves recomputing this every recipe check for overclocking.
private static final double log4 = log(4);
@@ -72,865 +72,402 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
@SuppressWarnings("SpellCheckingInspection")
private static final String[][] structure_string = new String[][] {
- {
- " ",
- " N N N N ",
- " N N N N ",
- " N N N N ",
- " ",
- " ",
- " ",
- " N N N N ",
- " N N N N ",
- " NNN NNN N N NNN NNN ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN "
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- " N N N N ",
- " ",
- " N N N N ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- " CCC CCC N N CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN N N NbbbN NbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " NNNbbbbbNNsNNbbbbbNNN ",
- " ss bCCCb bCCCb ss ",
- " s N N N N s ",
- " s s ",
- " N N N N N N ",
- " N bCCCb bCCCb N ",
- " N sbbbbbNNsNNbbbbbs N ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- " CbC CbC N N CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- " s s s s ",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " ss bCCCb bCCCb ss ",
- " bCCCb bCCCb ",
- " s NCCCN NCCCN s ",
- " s NCCCN NCCCN s ",
- " NCCCN NCCCN ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- " CCCCCCCCC N N CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbN NbbbNNNbbbN",
- },
- {
- " ",
- " N N N N ",
- " s N N N N s ",
- " s NCCCN NCCCN s ",
- " ",
- " ",
- " ",
- " NCCCN NCCCN ",
- " N N N N ",
- " NNN NN N N NN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NbN NNN NNN ",
- },
- {
- " ",
- " ",
- " s s ",
- " s NCCCN NCCCN s ",
- " ",
- " ",
- " ",
- " NCCCN NCCCN ",
- " ",
- " N N N N ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N N N ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " N N NbN N N ",
- },
- {
- " ",
- " N N N N ",
- " N N N N N N ",
- " NCCCN NCCCN ",
- " ",
- " ",
- " ",
- " NCCCN NCCCN ",
- " N N N N ",
- " NNN NN N N NN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NbN NNN NNN ",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " N bCCCb bCCCb N ",
- " bCCCb bCCCb ",
- " NCCCN NCCCN ",
- " NCCCN NCCCN ",
- " NCCCN NCCCN ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- " CCCCCCCCC N N CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbN NbbbNNNbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " N sbbbbbNNsNNbbbbbs N ",
- " bCCCb bCCCb ",
- " N N N N ",
- " ",
- " N N N N ",
- " bCCCb bCCCb ",
- " s sbbbbbNNsNNbbbbbs s ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- " CbC CbC N N CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- " s s s s ",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN",
- },
- {
- " NNN NNN N N NNN NNN ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- " NNN NNN N N NNN NNN ",
- " N N N N ",
- " NNN NNN N N NNN NNN ",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- "NNNN NNNCCCb bCCCNNN NNNN",
- " CCC CCC N N CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN NbN NbbbN NbbbN",
- },
- {
- " ",
- " CCC CCC N N CCC CCC ",
- " CbC CbC N N CbC CbC ",
- " CCCCCCCCC N N CCCCCCCCC ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " CCCCCCCCC N N CCCCCCCCC ",
- " CbC CbC N N CbC CbC ",
- " CCC CCC N N CCC CCC ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " NNN NNN NbN NNN NNN ",
- },
- {
- " ",
- " CCC CCC CCC CCC ",
- " CbC CbC CbC CbC ",
- " CCCCCCCCC CCCCCCCCC ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " CCCCCCCCC CCCCCCCCC ",
- " CbC CbC CbC CbC ",
- " CCC CCC CCC CCC ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NbN N N ",
- },
- {
- " ",
- " CCC CCC CCC CCC ",
- " CbC CbC CbC CbC ",
- " CCCCCCCCC CCCCCCCCC ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " CCCCCCCCC CCCCCCCCC ",
- " CbC CbC CbC CbC ",
- " CCC CCC CCC CCC ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NbN N N ",
- },
- {
- " NNN NNN NNN NNN ",
- "NbbbN NbbbN NbbbN NbbbN",
- "NbbbN NbbbN NbbbN NbbbN",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " NNN NNN NNN NNN ",
- " N N N N ",
- " NNN NNN NNN NNN ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- "NbbbN NbbbN NbbbN NbbbN",
- "NbbbN NbbbN NbbbN NbbbN",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NsNsN N N ",
- },
- {
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NbbbbbN N N ",
- },
- {
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N ",
- " NsNNNNNsNNNNsbbbbbsNNNNsNNNNNsN ",
- },
- {
- " ",
- " ",
- " s s s s ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " s s s s ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ~ ",
- " NNN ",
- " NbbbbbNbbbbNbbbbbNbbbbNbbbbbN ",
- },
- {
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N ",
- " NsNNNNNsNNNNsbbbbbsNNNNsNNNNNsN ",
- },
- {
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NbbbbbN N N ",
- },
- {
- " NNN NNN NNN NNN ",
- "NbbbN NbbbN NbbbN NbbbN",
- "NbbbN NbbbN NbbbN NbbbN",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " NNN NNN NNN NNN ",
- " N N N N ",
- " NNN NNN NNN NNN ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- "NbbbN NbbbN NbbbN NbbbN",
- "NbbbN NbbbN NbbbN NbbbN",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NsNsN N N ",
- },
- {
- " ",
- " CCC CCC CCC CCC ",
- " CbC CbC CbC CbC ",
- " CCCCCCCCC CCCCCCCCC ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " CCCCCCCCC CCCCCCCCC ",
- " CbC CbC CbC CbC ",
- " CCC CCC CCC CCC ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NbN N N ",
- },
- {
- " ",
- " CCC CCC CCC CCC ",
- " CbC CbC CbC CbC ",
- " CCCCCCCCC CCCCCCCCC ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " CCCCCCCCC CCCCCCCCC ",
- " CbC CbC CbC CbC ",
- " CCC CCC CCC CCC ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N NbN N N ",
- },
- {
- " ",
- " CCC CCC N N CCC CCC ",
- " CbC CbC N N CbC CbC ",
- " CCCCCCCCC N N CCCCCCCCC ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " CCCCCCCCC N N CCCCCCCCC ",
- " CbC CbC N N CbC CbC ",
- " CCC CCC N N CCC CCC ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " NNN NNN NbN NNN NNN ",
- },
- {
- " NNN NNN N N NNN NNN ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- " NNN NNN N N NNN NNN ",
- " N N N N ",
- " NNN NNN N N NNN NNN ",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- "NNNN NNNCCCb bCCCNNN NNNN",
- " CCC CCC N N CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN NbN NbbbN NbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " N sbbbbbNNsNNbbbbbs N ",
- " bCCCb bCCCb ",
- " N N N N ",
- " ",
- " N N N N ",
- " bCCCb bCCCb ",
- " s sbbbbbNNsNNbbbbbs s ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- " CbC CbC N N CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- " s s s s ",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " N bCCCb bCCCb N ",
- " bCCCb bCCCb ",
- " NCCCN NCCCN ",
- " NCCCN NCCCN ",
- " NCCCN NCCCN ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- " CCCCCCCCC N N CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbN NbbbNNNbbbN",
- },
- {
- " ",
- " N N N N ",
- " N N N N N N ",
- " NCCCN NCCCN ",
- " ",
- " ",
- " ",
- " NCCCN NCCCN ",
- " N N N N ",
- " NNN NN N N NN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NbN NNN NNN ",
- },
- {
- " ",
- " ",
- " s s ",
- " s NCCCN NCCCN s ",
- " ",
- " ",
- " ",
- " NCCCN NCCCN ",
- " ",
- " N N N N ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " N N N N ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " N N N N ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " N N NbN N N ",
- },
- {
- " ",
- " N N N N ",
- " s N N N N s ",
- " s NCCCN NCCCN s ",
- " ",
- " ",
- " ",
- " NCCCN NCCCN ",
- " N N N N ",
- " NNN NN N N NN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " C C C C ",
- " C C C C ",
- " C C C C ",
- " NNN NNN NbN NNN NNN ",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " ss bCCCb bCCCb ss ",
- " bCCCb bCCCb ",
- " s NCCCN NCCCN s ",
- " s NCCCN NCCCN s ",
- " NCCCN NCCCN ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
- " CCCCCCCCC N N CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbNNNbbbN NbbbNNNbbbN",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- " CCCCCCCCC CCCCCCCCC ",
- "NbbbNNNbbbN NbN NbbbNNNbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " NNNbbbbbNNsNNbbbbbNNN ",
- " ss bCCCb bCCCb ss ",
- " s N N N N s ",
- " s s ",
- " N N N N N N ",
- " N bCCCb bCCCb N ",
- " N sbbbbbNNsNNbbbbbs N ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- " CbC CbC N N CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- " s s s s ",
- " NNN NNN NNN NNN ",
- " NNN NNN NNN NNN ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- " CbC CbC CbC CbC ",
- "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN",
- },
- {
- " N N N N ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- " N N N N ",
- " ",
- " N N N N ",
- " bCCCb bCCCb ",
- " bCCCb bCCCb ",
- "NbbbN NbbNCCCb bCCCNbbN NbbbN",
- " CCC CCC N N CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN NbbbN NbbbN",
- " N N N N ",
- " N N N N ",
- " ",
- " N N N N ",
- " N N N N ",
- "NbbbN NbbbN NbbbN NbbbN",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- " CCC CCC CCC CCC ",
- "NbbbN NbbbN N N NbbbN NbbbN",
- },
- {
- " ",
- " N N N N ",
- " N N N N ",
- " N N N N ",
- " ",
- " ",
- " ",
- " N N N N ",
- " N N N N ",
- " NNN NNN N N NNN NNN ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- " ",
- " ",
- " ",
- " NNN NNN NNN NNN ",
- }
- };
+ { " ", " N N N N ",
+ " N N N N ", " N N N N ",
+ " ", " ",
+ " ", " N N N N ",
+ " N N N N ", " NNN NNN N N NNN NNN ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN " },
+ { " N N N N ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", " bCCCb bCCCb ",
+ " N N N N ", " ",
+ " N N N N ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ " CCC CCC N N CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN NbbbN NbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbN NbbbN NbbbN NbbbN",
+ " CCC CCC CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN N N NbbbN NbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " NNNbbbbbNNsNNbbbbbNNN ", " ss bCCCb bCCCb ss ",
+ " s N N N N s ", " s s ",
+ " N N N N N N ", " N bCCCb bCCCb N ",
+ " N sbbbbbNNsNNbbbbbs N ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ " CbC CbC N N CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbN NbbbN NbbbN",
+ " NNN NNN NNN NNN ", " NNN NNN NNN NNN ",
+ " s s s s ", " NNN NNN NNN NNN ",
+ " NNN NNN NNN NNN ", "NbbbN NbbbN NbbbN NbbbN",
+ " CbC CbC CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " ss bCCCb bCCCb ss ", " bCCCb bCCCb ",
+ " s NCCCN NCCCN s ", " s NCCCN NCCCN s ",
+ " NCCCN NCCCN ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ " CCCCCCCCC N N CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " CCCCCCCCC CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbN NbbbNNNbbbN", },
+ { " ", " N N N N ",
+ " s N N N N s ", " s NCCCN NCCCN s ",
+ " ", " ",
+ " ", " NCCCN NCCCN ",
+ " N N N N ", " NNN NN N N NN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NbN NNN NNN ", },
+ { " ", " ",
+ " s s ", " s NCCCN NCCCN s ",
+ " ", " ",
+ " ", " NCCCN NCCCN ",
+ " ", " N N N N ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " N N N N ",
+ " ", " ",
+ " ", " ",
+ " ", " N N N N ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " N N NbN N N ", },
+ { " ", " N N N N ",
+ " N N N N N N ", " NCCCN NCCCN ",
+ " ", " ",
+ " ", " NCCCN NCCCN ",
+ " N N N N ", " NNN NN N N NN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NbN NNN NNN ", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " N bCCCb bCCCb N ", " bCCCb bCCCb ",
+ " NCCCN NCCCN ", " NCCCN NCCCN ",
+ " NCCCN NCCCN ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ " CCCCCCCCC N N CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " CCCCCCCCC CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbN NbbbNNNbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " N sbbbbbNNsNNbbbbbs N ", " bCCCb bCCCb ",
+ " N N N N ", " ",
+ " N N N N ", " bCCCb bCCCb ",
+ " s sbbbbbNNsNNbbbbbs s ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ " CbC CbC N N CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbN NbbbN NbbbN",
+ " NNN NNN NNN NNN ", " NNN NNN NNN NNN ",
+ " s s s s ", " NNN NNN NNN NNN ",
+ " NNN NNN NNN NNN ", "NbbbN NbbbN NbbbN NbbbN",
+ " CbC CbC CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN", },
+ { " NNN NNN N N NNN NNN ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ "NbbbN NbbNCCCb bCCCNbbN NbbbN", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ " NNN NNN N N NNN NNN ", " N N N N ",
+ " NNN NNN N N NNN NNN ", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ "NbbbN NbbNCCCb bCCCNbbN NbbbN", "NNNN NNNCCCb bCCCNNN NNNN",
+ " CCC CCC N N CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN NbbbN NbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbN NbbbN NbbbN NbbbN",
+ " CCC CCC CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN NbN NbbbN NbbbN", },
+ { " ", " CCC CCC N N CCC CCC ",
+ " CbC CbC N N CbC CbC ", " CCCCCCCCC N N CCCCCCCCC ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " CCCCCCCCC N N CCCCCCCCC ",
+ " CbC CbC N N CbC CbC ", " CCC CCC N N CCC CCC ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " NNN NNN NbN NNN NNN ", },
+ { " ", " CCC CCC CCC CCC ",
+ " CbC CbC CbC CbC ", " CCCCCCCCC CCCCCCCCC ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " CCCCCCCCC CCCCCCCCC ",
+ " CbC CbC CbC CbC ", " CCC CCC CCC CCC ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NbN N N ", },
+ { " ", " CCC CCC CCC CCC ",
+ " CbC CbC CbC CbC ", " CCCCCCCCC CCCCCCCCC ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " CCCCCCCCC CCCCCCCCC ",
+ " CbC CbC CbC CbC ", " CCC CCC CCC CCC ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NbN N N ", },
+ { " NNN NNN NNN NNN ", "NbbbN NbbbN NbbbN NbbbN",
+ "NbbbN NbbbN NbbbN NbbbN", "NbbbNNNbbbN NbbbNNNbbbN",
+ " NNN NNN NNN NNN ", " N N N N ",
+ " NNN NNN NNN NNN ", "NbbbNNNbbbN NbbbNNNbbbN",
+ "NbbbN NbbbN NbbbN NbbbN", "NbbbN NbbbN NbbbN NbbbN",
+ " NNN NNN NNN NNN ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NsNsN N N ", },
+ { " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NbbbbbN N N ", },
+ { " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " N ", " NsNNNNNsNNNNsbbbbbsNNNNsNNNNNsN ", },
+ { " ", " ",
+ " s s s s ", " ",
+ " ", " ",
+ " ", " ",
+ " s s s s ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ~ ",
+ " NNN ", " NbbbbbNbbbbNbbbbbNbbbbNbbbbbN ", },
+ { " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " N ", " NsNNNNNsNNNNsbbbbbsNNNNsNNNNNsN ", },
+ { " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " N N N N ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NbbbbbN N N ", },
+ { " NNN NNN NNN NNN ", "NbbbN NbbbN NbbbN NbbbN",
+ "NbbbN NbbbN NbbbN NbbbN", "NbbbNNNbbbN NbbbNNNbbbN",
+ " NNN NNN NNN NNN ", " N N N N ",
+ " NNN NNN NNN NNN ", "NbbbNNNbbbN NbbbNNNbbbN",
+ "NbbbN NbbbN NbbbN NbbbN", "NbbbN NbbbN NbbbN NbbbN",
+ " NNN NNN NNN NNN ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NsNsN N N ", },
+ { " ", " CCC CCC CCC CCC ",
+ " CbC CbC CbC CbC ", " CCCCCCCCC CCCCCCCCC ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " CCCCCCCCC CCCCCCCCC ",
+ " CbC CbC CbC CbC ", " CCC CCC CCC CCC ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NbN N N ", },
+ { " ", " CCC CCC CCC CCC ",
+ " CbC CbC CbC CbC ", " CCCCCCCCC CCCCCCCCC ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " CCCCCCCCC CCCCCCCCC ",
+ " CbC CbC CbC CbC ", " CCC CCC CCC CCC ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " ",
+ " ", " N N NbN N N ", },
+ { " ", " CCC CCC N N CCC CCC ",
+ " CbC CbC N N CbC CbC ", " CCCCCCCCC N N CCCCCCCCC ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " CCCCCCCCC N N CCCCCCCCC ",
+ " CbC CbC N N CbC CbC ", " CCC CCC N N CCC CCC ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " NNN NNN NbN NNN NNN ", },
+ { " NNN NNN N N NNN NNN ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ "NbbbN NbbNCCCb bCCCNbbN NbbbN", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ " NNN NNN N N NNN NNN ", " N N N N ",
+ " NNN NNN N N NNN NNN ", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ "NbbbN NbbNCCCb bCCCNbbN NbbbN", "NNNN NNNCCCb bCCCNNN NNNN",
+ " CCC CCC N N CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN NbbbN NbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbN NbbbN NbbbN NbbbN",
+ " CCC CCC CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN NbN NbbbN NbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " N sbbbbbNNsNNbbbbbs N ", " bCCCb bCCCb ",
+ " N N N N ", " ",
+ " N N N N ", " bCCCb bCCCb ",
+ " s sbbbbbNNsNNbbbbbs s ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ " CbC CbC N N CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbN NbbbN NbbbN",
+ " NNN NNN NNN NNN ", " NNN NNN NNN NNN ",
+ " s s s s ", " NNN NNN NNN NNN ",
+ " NNN NNN NNN NNN ", "NbbbN NbbbN NbbbN NbbbN",
+ " CbC CbC CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " N bCCCb bCCCb N ", " bCCCb bCCCb ",
+ " NCCCN NCCCN ", " NCCCN NCCCN ",
+ " NCCCN NCCCN ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ " CCCCCCCCC N N CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " CCCCCCCCC CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbN NbbbNNNbbbN", },
+ { " ", " N N N N ",
+ " N N N N N N ", " NCCCN NCCCN ",
+ " ", " ",
+ " ", " NCCCN NCCCN ",
+ " N N N N ", " NNN NN N N NN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NbN NNN NNN ", },
+ { " ", " ",
+ " s s ", " s NCCCN NCCCN s ",
+ " ", " ",
+ " ", " NCCCN NCCCN ",
+ " ", " N N N N ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " N N N N ",
+ " ", " ",
+ " ", " ",
+ " ", " N N N N ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " N N NbN N N ", },
+ { " ", " N N N N ",
+ " s N N N N s ", " s NCCCN NCCCN s ",
+ " ", " ",
+ " ", " NCCCN NCCCN ",
+ " N N N N ", " NNN NN N N NN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " C C C C ", " C C C C ",
+ " C C C C ", " NNN NNN NbN NNN NNN ", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " ss bCCCb bCCCb ss ", " bCCCb bCCCb ",
+ " s NCCCN NCCCN s ", " s NCCCN NCCCN s ",
+ " NCCCN NCCCN ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", "NbbbNNNbbNCCCb bCCCNbbNNNbbbN",
+ " CCCCCCCCC N N CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbNNNbbbN NbbbNNNbbbN",
+ " CCCCCCCCC CCCCCCCCC ", " CCCCCCCCC CCCCCCCCC ",
+ " CCCCCCCCC CCCCCCCCC ", "NbbbNNNbbbN NbN NbbbNNNbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " NNNbbbbbNNsNNbbbbbNNN ", " ss bCCCb bCCCb ss ",
+ " s N N N N s ", " s s ",
+ " N N N N N N ", " N bCCCb bCCCb N ",
+ " N sbbbbbNNsNNbbbbbs N ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ " CbC CbC N N CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbN NbbbN NbbbN",
+ " NNN NNN NNN NNN ", " NNN NNN NNN NNN ",
+ " s s s s ", " NNN NNN NNN NNN ",
+ " NNN NNN NNN NNN ", "NbbbN NbbbN NbbbN NbbbN",
+ " CbC CbC CbC CbC ", " CbC CbC CbC CbC ",
+ " CbC CbC CbC CbC ", "NbbbN NbbbNNNNNsNsNNNNNbbbN NbbbN", },
+ { " N N N N ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", " bCCCb bCCCb ",
+ " N N N N ", " ",
+ " N N N N ", " bCCCb bCCCb ",
+ " bCCCb bCCCb ", "NbbbN NbbNCCCb bCCCNbbN NbbbN",
+ " CCC CCC N N CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN NbbbN NbbbN",
+ " N N N N ", " N N N N ",
+ " ", " N N N N ",
+ " N N N N ", "NbbbN NbbbN NbbbN NbbbN",
+ " CCC CCC CCC CCC ", " CCC CCC CCC CCC ",
+ " CCC CCC CCC CCC ", "NbbbN NbbbN N N NbbbN NbbbN", },
+ { " ", " N N N N ",
+ " N N N N ", " N N N N ",
+ " ", " ",
+ " ", " N N N N ",
+ " N N N N ", " NNN NNN N N NNN NNN ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ",
+ " ", " ",
+ " ", " NNN NNN NNN NNN ", } };
protected static final int DIM_TRANS_CASING = 12;
protected static final int DIM_INJECTION_CASING = 13;
@@ -939,31 +476,19 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
private boolean isMultiChunkloaded = true;
protected static final String STRUCTURE_PIECE_MAIN = "main";
- private static final IStructureDefinition<GT_MetaTileEntity_PlasmaForge> STRUCTURE_DEFINITION =
- StructureDefinition.<GT_MetaTileEntity_PlasmaForge>builder()
- .addShape(STRUCTURE_PIECE_MAIN, structure_string)
- .addElement(
- 'C',
- ofCoil(
- GT_MetaTileEntity_PlasmaForge::setCoilLevel,
- GT_MetaTileEntity_PlasmaForge::getCoilLevel))
- .addElement(
- 'b',
- buildHatchAdder(GT_MetaTileEntity_PlasmaForge.class)
- .atLeast(
- InputHatch,
- OutputHatch,
- InputBus,
- OutputBus,
- Energy,
- ExoticEnergy,
- Maintenance)
- .casingIndex(DIM_INJECTION_CASING)
- .dot(3)
- .buildAndChain(GregTech_API.sBlockCasings1, DIM_INJECTION_CASING))
- .addElement('N', ofBlock(GregTech_API.sBlockCasings1, DIM_TRANS_CASING))
- .addElement('s', ofBlock(GregTech_API.sBlockCasings1, DIM_BRIDGE_CASING))
- .build();
+ private static final IStructureDefinition<GT_MetaTileEntity_PlasmaForge> STRUCTURE_DEFINITION = StructureDefinition
+ .<GT_MetaTileEntity_PlasmaForge>builder().addShape(STRUCTURE_PIECE_MAIN, structure_string)
+ .addElement(
+ 'C',
+ ofCoil(GT_MetaTileEntity_PlasmaForge::setCoilLevel, GT_MetaTileEntity_PlasmaForge::getCoilLevel))
+ .addElement(
+ 'b',
+ buildHatchAdder(GT_MetaTileEntity_PlasmaForge.class)
+ .atLeast(InputHatch, OutputHatch, InputBus, OutputBus, Energy, ExoticEnergy, Maintenance)
+ .casingIndex(DIM_INJECTION_CASING).dot(3)
+ .buildAndChain(GregTech_API.sBlockCasings1, DIM_INJECTION_CASING))
+ .addElement('N', ofBlock(GregTech_API.sBlockCasings1, DIM_TRANS_CASING))
+ .addElement('s', ofBlock(GregTech_API.sBlockCasings1, DIM_BRIDGE_CASING)).build();
@Override
protected boolean addBottomHatch(IGregTechTileEntity aTileEntity, int aBaseCasingIndex) {
@@ -988,42 +513,87 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
protected GT_Multiblock_Tooltip_Builder createTooltip() {
GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
tt.addInfo("Transcending Dimensional Boundaries.")
- .addInfo("Takes " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(max_efficiency_time_in_ticks / (3600 * 20)) + EnumChatFormatting.GRAY
- + " hours of continuous run time to fully breach dimensional")
+ .addInfo(
+ "Takes " + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(max_efficiency_time_in_ticks / (3600 * 20))
+ + EnumChatFormatting.GRAY
+ + " hours of continuous run time to fully breach dimensional")
.addInfo("boundaries and achieve maximum efficiency. This reduces fuel")
- .addInfo("consumption by up to " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(100 * maximum_discount) + "%" + EnumChatFormatting.GRAY
- + ". Supports overclocking beyond MAX voltage.")
- .addInfo(AuthorColen)
- .addSeparator()
- .beginStructureBlock(33, 24, 33, false)
+ .addInfo(
+ "consumption by up to " + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(100 * maximum_discount)
+ + "%"
+ + EnumChatFormatting.GRAY
+ + ". Supports overclocking beyond MAX voltage.")
+ .addInfo(AuthorColen).addSeparator().beginStructureBlock(33, 24, 33, false)
.addStructureInfo("DTPF Structure is too complex! See schematic for details.")
.addStructureInfo(
EnumChatFormatting.GOLD + "2,112" + EnumChatFormatting.GRAY + " Heating coils required.")
- .addStructureInfo(EnumChatFormatting.GOLD + "120" + EnumChatFormatting.GRAY
- + " Dimensional bridge blocks required.")
- .addStructureInfo(EnumChatFormatting.GOLD + "1,270" + EnumChatFormatting.GRAY
- + " Dimensional injection casings required.")
- .addStructureInfo(EnumChatFormatting.GOLD + "2,121" + EnumChatFormatting.GRAY
- + " Dimensionally transcendent casings required.")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "120"
+ + EnumChatFormatting.GRAY
+ + " Dimensional bridge blocks required.")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "1,270"
+ + EnumChatFormatting.GRAY
+ + " Dimensional injection casings required.")
+ .addStructureInfo(
+ EnumChatFormatting.GOLD + "2,121"
+ + EnumChatFormatting.GRAY
+ + " Dimensionally transcendent casings required.")
.addStructureInfo("--------------------------------------------")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + "-"
- + EnumChatFormatting.GOLD + "2" + EnumChatFormatting.GRAY + " energy hatches or "
- + EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + " TT energy hatch.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + "1"
+ + EnumChatFormatting.GRAY
+ + "-"
+ + EnumChatFormatting.GOLD
+ + "2"
+ + EnumChatFormatting.GRAY
+ + " energy hatches or "
+ + EnumChatFormatting.GOLD
+ + "1"
+ + EnumChatFormatting.GRAY
+ + " TT energy hatch.")
.addStructureInfo(
"Requires " + EnumChatFormatting.GOLD + "1" + EnumChatFormatting.GRAY + " maintenance hatch.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + min_input_hatch + EnumChatFormatting.GRAY
- + "-" + EnumChatFormatting.GOLD + max_input_hatch + EnumChatFormatting.GRAY + " input hatches.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + min_output_hatch + EnumChatFormatting.GRAY
- + "-" + EnumChatFormatting.GOLD + max_output_hatch + EnumChatFormatting.GRAY
- + " output hatches.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + min_input_bus + EnumChatFormatting.GRAY + "-"
- + EnumChatFormatting.GOLD + max_input_bus + EnumChatFormatting.GRAY + " input busses.")
- .addStructureInfo("Requires " + EnumChatFormatting.GOLD + min_output_bus + EnumChatFormatting.GRAY + "-"
- + EnumChatFormatting.GOLD + max_input_bus + EnumChatFormatting.GRAY + " output busses.")
- .addStructureInfo("--------------------------------------------")
- .toolTipFinisher("Gregtech");
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + min_input_hatch
+ + EnumChatFormatting.GRAY
+ + "-"
+ + EnumChatFormatting.GOLD
+ + max_input_hatch
+ + EnumChatFormatting.GRAY
+ + " input hatches.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + min_output_hatch
+ + EnumChatFormatting.GRAY
+ + "-"
+ + EnumChatFormatting.GOLD
+ + max_output_hatch
+ + EnumChatFormatting.GRAY
+ + " output hatches.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + min_input_bus
+ + EnumChatFormatting.GRAY
+ + "-"
+ + EnumChatFormatting.GOLD
+ + max_input_bus
+ + EnumChatFormatting.GRAY
+ + " input busses.")
+ .addStructureInfo(
+ "Requires " + EnumChatFormatting.GOLD
+ + min_output_bus
+ + EnumChatFormatting.GRAY
+ + "-"
+ + EnumChatFormatting.GOLD
+ + max_input_bus
+ + EnumChatFormatting.GRAY
+ + " output busses.")
+ .addStructureInfo("--------------------------------------------").toolTipFinisher("Gregtech");
return tt;
}
@@ -1034,33 +604,16 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- casingTexturePages[0][DIM_BRIDGE_CASING],
- TextureFactory.builder()
- .addIcon(OVERLAY_DTPF_ON)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FUSION1_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- casingTexturePages[0][DIM_BRIDGE_CASING],
- TextureFactory.builder().addIcon(OVERLAY_DTPF_OFF).extFacing().build()
- };
+ if (aActive) return new ITexture[] { casingTexturePages[0][DIM_BRIDGE_CASING],
+ TextureFactory.builder().addIcon(OVERLAY_DTPF_ON).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FUSION1_GLOW).extFacing().glow().build() };
+ return new ITexture[] { casingTexturePages[0][DIM_BRIDGE_CASING],
+ TextureFactory.builder().addIcon(OVERLAY_DTPF_OFF).extFacing().build() };
}
- return new ITexture[] {casingTexturePages[0][DIM_BRIDGE_CASING]};
+ return new ITexture[] { casingTexturePages[0][DIM_BRIDGE_CASING] };
}
@Override
@@ -1101,8 +654,8 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
long tTotalEU = GT_ExoticEnergyInputHelper.getTotalEuMulti(getExoticAndNormalEnergyHatchList());
// Look up recipe. If not found it will return null.
- GT_Recipe tRecipe_0 = GT_Recipe.GT_Recipe_Map.sPlasmaForgeRecipes.findRecipe(
- getBaseMetaTileEntity(), false, tTotalEU, tFluids, tItems);
+ GT_Recipe tRecipe_0 = GT_Recipe.GT_Recipe_Map.sPlasmaForgeRecipes
+ .findRecipe(getBaseMetaTileEntity(), false, tTotalEU, tFluids, tItems);
// Check if recipe found.
if (tRecipe_0 == null) return false;
@@ -1114,8 +667,7 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
GT_Recipe tRecipe_1 = tRecipe_0.copy();
// Break out to the outermost for loop when fuel found and discounted. Only 1 fuel per recipe is intended.
- outside:
- for (int i = 0; i < tRecipe_0.mFluidInputs.length; i++) {
+ outside: for (int i = 0; i < tRecipe_0.mFluidInputs.length; i++) {
for (FluidStack fuel : valid_fuels) {
if (tRecipe_1.mFluidInputs[i].isFluidEqual(fuel)) {
// If running for max_efficiency_time_in_ticks then discount is at maximum.
@@ -1257,37 +809,63 @@ public class GT_MetaTileEntity_PlasmaForge extends GT_MetaTileEntity_AbstractMul
}
}
- return new String[] {
- "------------ Critical Information ------------",
- StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mProgresstime) + EnumChatFormatting.RESET + "t / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(mMaxProgresstime) + EnumChatFormatting.RESET + "t",
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.multiblock.usage") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(-EU_per_tick) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.multiblock.mei") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(
- GT_ExoticEnergyInputHelper.getAverageInputVoltageMulti(getExoticAndNormalEnergyHatchList()))
- + EnumChatFormatting.RESET + " EU/t(*" + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(
- GT_ExoticEnergyInputHelper.getMaxWorkingInputAmpsMulti(getExoticAndNormalEnergyHatchList()))
- + EnumChatFormatting.RESET + "A) " + StatCollector.translateToLocal("GT5U.machines.tier")
- + ": " + EnumChatFormatting.YELLOW
- + VN[
- GT_Utility.getTier(
- GT_ExoticEnergyInputHelper.getTotalEuMulti(getExoticAndNormalEnergyHatchList()))]
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.EBF.heat") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mHeatingCapacity) + EnumChatFormatting.RESET + " K",
- "Ticks run: " + EnumChatFormatting.GREEN + GT_Utility.formatNumbers(running_time) + EnumChatFormatting.RESET
- + ", Fuel Discount: " + EnumChatFormatting.RED + GT_Utility.formatNumbers(100 * (1 - discount))
- + EnumChatFormatting.RESET + "%",
- "-----------------------------------------"
- };
+ return new String[] { "------------ Critical Information ------------",
+ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mProgresstime)
+ + EnumChatFormatting.RESET
+ + "t / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(mMaxProgresstime)
+ + EnumChatFormatting.RESET
+ + "t",
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.multiblock.usage") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(-EU_per_tick)
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.multiblock.mei") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(
+ GT_ExoticEnergyInputHelper
+ .getAverageInputVoltageMulti(getExoticAndNormalEnergyHatchList()))
+ + EnumChatFormatting.RESET
+ + " EU/t(*"
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(
+ GT_ExoticEnergyInputHelper
+ .getMaxWorkingInputAmpsMulti(getExoticAndNormalEnergyHatchList()))
+ + EnumChatFormatting.RESET
+ + "A) "
+ + StatCollector.translateToLocal("GT5U.machines.tier")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + VN[GT_Utility.getTier(
+ GT_ExoticEnergyInputHelper.getTotalEuMulti(getExoticAndNormalEnergyHatchList()))]
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.EBF.heat") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mHeatingCapacity)
+ + EnumChatFormatting.RESET
+ + " K",
+ "Ticks run: " + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(running_time)
+ + EnumChatFormatting.RESET
+ + ", Fuel Discount: "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(100 * (1 - discount))
+ + EnumChatFormatting.RESET
+ + "%",
+ "-----------------------------------------" };
}
public List<GT_MetaTileEntity_Hatch> getExoticAndNormalEnergyHatchList() {
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PrimitiveBlastFurnace.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PrimitiveBlastFurnace.java
index 40754c14c5..67afa63df8 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PrimitiveBlastFurnace.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PrimitiveBlastFurnace.java
@@ -3,6 +3,13 @@ package gregtech.common.tileentities.machines.multi;
import static com.gtnewhorizon.structurelib.structure.StructureUtility.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.init.Blocks;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraftforge.common.util.ForgeDirection;
+
import com.gtnewhorizon.structurelib.StructureLibAPI;
import com.gtnewhorizon.structurelib.alignment.IAlignment;
import com.gtnewhorizon.structurelib.alignment.IAlignmentLimits;
@@ -15,6 +22,7 @@ import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.ProgressBar;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.GT_Mod;
@@ -34,37 +42,28 @@ import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
import gregtech.common.GT_Pollution;
-import net.minecraft.block.Block;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.init.Blocks;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraftforge.common.util.ForgeDirection;
public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEntity
implements IAlignment, ISurvivalConstructable, IAddUIWidgets, IGetTitleColor {
+
public static final int INPUT_SLOTS = 3, OUTPUT_SLOTS = 3;
- private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_PrimitiveBlastFurnace>>
- STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_PrimitiveBlastFurnace>>() {
- @Override
- protected IStructureDefinition<GT_MetaTileEntity_PrimitiveBlastFurnace> computeValue(Class<?> type) {
- return IStructureDefinition.<GT_MetaTileEntity_PrimitiveBlastFurnace>builder()
- .addShape("main", transpose(new String[][] {
- {"ccc", "c-c", "ccc"},
- {"ccc", "clc", "ccc"},
- {"c~c", "clc", "ccc"},
- {"ccc", "ccc", "ccc"},
- }))
- .addElement('c', lazy(t -> ofBlock(t.getCasingBlock(), t.getCasingMetaID())))
- .addElement(
- 'l',
- ofChain(
- isAir(),
- ofBlockAnyMeta(Blocks.lava, 1),
- ofBlockAnyMeta(Blocks.flowing_lava, 1)))
- .build();
- }
- };
+ private static final ClassValue<IStructureDefinition<GT_MetaTileEntity_PrimitiveBlastFurnace>> STRUCTURE_DEFINITION = new ClassValue<IStructureDefinition<GT_MetaTileEntity_PrimitiveBlastFurnace>>() {
+
+ @Override
+ protected IStructureDefinition<GT_MetaTileEntity_PrimitiveBlastFurnace> computeValue(Class<?> type) {
+ return IStructureDefinition.<GT_MetaTileEntity_PrimitiveBlastFurnace>builder()
+ .addShape(
+ "main",
+ transpose(
+ new String[][] { { "ccc", "c-c", "ccc" }, { "ccc", "clc", "ccc" },
+ { "c~c", "clc", "ccc" }, { "ccc", "ccc", "ccc" }, }))
+ .addElement('c', lazy(t -> ofBlock(t.getCasingBlock(), t.getCasingMetaID())))
+ .addElement(
+ 'l',
+ ofChain(isAir(), ofBlockAnyMeta(Blocks.lava, 1), ofBlockAnyMeta(Blocks.flowing_lava, 1)))
+ .build();
+ }
+ };
public int mMaxProgresstime = 0;
private volatile boolean mUpdated;
@@ -197,8 +196,7 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
@Override
public ExtendedFacing getExtendedFacing() {
- return ExtendedFacing.of(
- ForgeDirection.getOrientation(getBaseMetaTileEntity().getFrontFacing()));
+ return ExtendedFacing.of(ForgeDirection.getOrientation(getBaseMetaTileEntity().getFrontFacing()));
}
@Override
@@ -212,20 +210,18 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
}
private boolean checkMachine() {
- return STRUCTURE_DEFINITION
- .get(this.getClass())
- .check(
- this,
- "main",
- getBaseMetaTileEntity().getWorld(),
- getExtendedFacing(),
- getBaseMetaTileEntity().getXCoord(),
- getBaseMetaTileEntity().getYCoord(),
- getBaseMetaTileEntity().getZCoord(),
- 1,
- 2,
- 0,
- !mMachine);
+ return STRUCTURE_DEFINITION.get(this.getClass()).check(
+ this,
+ "main",
+ getBaseMetaTileEntity().getWorld(),
+ getExtendedFacing(),
+ getBaseMetaTileEntity().getXCoord(),
+ getBaseMetaTileEntity().getYCoord(),
+ getBaseMetaTileEntity().getZCoord(),
+ 1,
+ 2,
+ 0,
+ !mMachine);
}
protected abstract Block getCasingBlock();
@@ -243,15 +239,13 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
final int lavaZ = aBaseMetaTileEntity.getOffsetZ(aBaseMetaTileEntity.getBackFacing(), 1);
if ((aBaseMetaTileEntity.isClientSide()) && (aBaseMetaTileEntity.isActive())) {
- new WorldSpawnedEventBuilder.ParticleEventBuilder()
- .setMotion(0D, 0.3D, 0D)
+ new WorldSpawnedEventBuilder.ParticleEventBuilder().setMotion(0D, 0.3D, 0D)
.setIdentifier(ParticleFX.LARGE_SMOKE)
.setPosition(
lavaX + XSTR_INSTANCE.nextFloat(),
aBaseMetaTileEntity.getOffsetY(aBaseMetaTileEntity.getBackFacing(), 1),
lavaZ + XSTR_INSTANCE.nextFloat())
- .setWorld(getBaseMetaTileEntity().getWorld())
- .run();
+ .setWorld(getBaseMetaTileEntity().getWorld()).run();
}
if (aBaseMetaTileEntity.isServerSide()) {
if (mUpdated) {
@@ -270,8 +264,7 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
this.mProgresstime = 0;
this.mMaxProgresstime = 0;
GT_Mod.achievements.issueAchievement(
- aBaseMetaTileEntity
- .getWorld()
+ aBaseMetaTileEntity.getWorld()
.getPlayerEntityByName(aBaseMetaTileEntity.getOwnerName()),
"steel");
}
@@ -281,7 +274,8 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
}
if (this.mMaxProgresstime > 0 && (aTimer % 20L == 0L)) {
GT_Pollution.addPollution(
- this.getBaseMetaTileEntity(), GT_Mod.gregtechproxy.mPollutionPrimitveBlastFurnacePerSecond);
+ this.getBaseMetaTileEntity(),
+ GT_Mod.gregtechproxy.mPollutionPrimitveBlastFurnacePerSecond);
}
aBaseMetaTileEntity.setActive((this.mMaxProgresstime > 0) && (this.mMachine));
@@ -318,11 +312,9 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
}
/**
- * Draws random flames and smoke particles in front of Primitive Blast
- * Furnace when active
+ * Draws random flames and smoke particles in front of Primitive Blast Furnace when active
*
- * @param aBaseMetaTileEntity The entity that will handle the
- * {@link Block#randomDisplayTick}
+ * @param aBaseMetaTileEntity The entity that will handle the {@link Block#randomDisplayTick}
*/
@SideOnly(Side.CLIENT)
@Override
@@ -356,10 +348,8 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
z = oZ + offset;
}
- ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder())
- .setMotion(0D, 0D, 0D)
- .setPosition(x, y, z)
- .setWorld(getBaseMetaTileEntity().getWorld());
+ ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder()).setMotion(0D, 0D, 0D)
+ .setPosition(x, y, z).setWorld(getBaseMetaTileEntity().getWorld());
particleEventBuilder.setIdentifier(ParticleFX.SMOKE).run();
particleEventBuilder.setIdentifier(ParticleFX.FLAME).run();
}
@@ -397,7 +387,7 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
return true;
}
return ((this.mInventory[absoluteSlot].stackSize + outputStack.stackSize
- <= this.mInventory[absoluteSlot].getMaxStackSize())
+ <= this.mInventory[absoluteSlot].getMaxStackSize())
&& (GT_Utility.areStacksEqual(this.mInventory[absoluteSlot], outputStack)));
}
@@ -459,23 +449,21 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
@Override
public int survivalConstruct(ItemStack stackSize, int elementBudget, ISurvivalBuildEnvironment env) {
if (mMachine) return -1;
- return STRUCTURE_DEFINITION
- .get(getClass())
- .survivalBuild(
- this,
- stackSize,
- "main",
- getBaseMetaTileEntity().getWorld(),
- getExtendedFacing(),
- getBaseMetaTileEntity().getXCoord(),
- getBaseMetaTileEntity().getYCoord(),
- getBaseMetaTileEntity().getZCoord(),
- 1,
- 2,
- 0,
- elementBudget,
- env,
- false);
+ return STRUCTURE_DEFINITION.get(getClass()).survivalBuild(
+ this,
+ stackSize,
+ "main",
+ getBaseMetaTileEntity().getWorld(),
+ getExtendedFacing(),
+ getBaseMetaTileEntity().getXCoord(),
+ getBaseMetaTileEntity().getYCoord(),
+ getBaseMetaTileEntity().getZCoord(),
+ 1,
+ 2,
+ 0,
+ elementBudget,
+ env,
+ false);
}
@Override
@@ -485,21 +473,19 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
@Override
public void construct(ItemStack stackSize, boolean hintsOnly) {
- STRUCTURE_DEFINITION
- .get(getClass())
- .buildOrHints(
- this,
- stackSize,
- "main",
- getBaseMetaTileEntity().getWorld(),
- getExtendedFacing(),
- getBaseMetaTileEntity().getXCoord(),
- getBaseMetaTileEntity().getYCoord(),
- getBaseMetaTileEntity().getZCoord(),
- 1,
- 2,
- 0,
- hintsOnly);
+ STRUCTURE_DEFINITION.get(getClass()).buildOrHints(
+ this,
+ stackSize,
+ "main",
+ getBaseMetaTileEntity().getWorld(),
+ getExtendedFacing(),
+ getBaseMetaTileEntity().getXCoord(),
+ getBaseMetaTileEntity().getYCoord(),
+ getBaseMetaTileEntity().getZCoord(),
+ 1,
+ 2,
+ 0,
+ hintsOnly);
}
@Override
@@ -509,45 +495,40 @@ public abstract class GT_MetaTileEntity_PrimitiveBlastFurnace extends MetaTileEn
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new SlotWidget(inventoryHandler, 0)
- .setBackground(
- getGUITextureSet().getItemSlot(),
- GT_UITextures.OVERLAY_SLOT_INGOT_STEAM.get(getSteamVariant()))
- .setPos(33, 15))
- .widget(new SlotWidget(inventoryHandler, 1)
- .setBackground(
- getGUITextureSet().getItemSlot(),
- GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant()))
- .setPos(33, 33))
- .widget(new SlotWidget(inventoryHandler, 2)
- .setBackground(
- getGUITextureSet().getItemSlot(),
- GT_UITextures.OVERLAY_SLOT_FURNACE_STEAM.get(getSteamVariant()))
- .setPos(33, 51))
- .widget(new SlotWidget(inventoryHandler, 3)
- .setAccess(true, false)
- .setBackground(
- getGUITextureSet().getItemSlot(),
- GT_UITextures.OVERLAY_SLOT_INGOT_STEAM.get(getSteamVariant()))
- .setPos(85, 24))
- .widget(new SlotWidget(inventoryHandler, 4)
- .setAccess(true, false)
- .setBackground(
+ builder.widget(
+ new SlotWidget(inventoryHandler, 0).setBackground(
+ getGUITextureSet().getItemSlot(),
+ GT_UITextures.OVERLAY_SLOT_INGOT_STEAM.get(getSteamVariant())).setPos(33, 15))
+ .widget(
+ new SlotWidget(inventoryHandler, 1).setBackground(
getGUITextureSet().getItemSlot(),
- GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant()))
- .setPos(103, 24))
- .widget(new SlotWidget(inventoryHandler, 5)
- .setAccess(true, false)
- .setBackground(
+ GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant())).setPos(33, 33))
+ .widget(
+ new SlotWidget(inventoryHandler, 2).setBackground(
getGUITextureSet().getItemSlot(),
- GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant()))
- .setPos(121, 24))
- .widget(new ProgressBar()
- .setTexture(GT_UITextures.PROGRESSBAR_ARROW_2_STEAM.get(getSteamVariant()), 20)
- .setProgress(() -> (float) mProgresstime / mMaxProgresstime)
- .setNEITransferRect(getRecipeMap().mNEIName)
- .setPos(58, 24)
- .setSize(20, 18));
+ GT_UITextures.OVERLAY_SLOT_FURNACE_STEAM.get(getSteamVariant())).setPos(33, 51))
+ .widget(
+ new SlotWidget(inventoryHandler, 3).setAccess(true, false)
+ .setBackground(
+ getGUITextureSet().getItemSlot(),
+ GT_UITextures.OVERLAY_SLOT_INGOT_STEAM.get(getSteamVariant()))
+ .setPos(85, 24))
+ .widget(
+ new SlotWidget(inventoryHandler, 4).setAccess(true, false)
+ .setBackground(
+ getGUITextureSet().getItemSlot(),
+ GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant()))
+ .setPos(103, 24))
+ .widget(
+ new SlotWidget(inventoryHandler, 5).setAccess(true, false)
+ .setBackground(
+ getGUITextureSet().getItemSlot(),
+ GT_UITextures.OVERLAY_SLOT_DUST_STEAM.get(getSteamVariant()))
+ .setPos(121, 24))
+ .widget(
+ new ProgressBar().setTexture(GT_UITextures.PROGRESSBAR_ARROW_2_STEAM.get(getSteamVariant()), 20)
+ .setProgress(() -> (float) mProgresstime / mMaxProgresstime)
+ .setNEITransferRect(getRecipeMap().mNEIName).setPos(58, 24).setSize(20, 18));
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java
index f36ba2853b..a53288d50c 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java
@@ -12,8 +12,22 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_PROCESSING_AR
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_PROCESSING_ARRAY_GLOW;
import static gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicMachine.isValidForLowGravity;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Objects;
+import java.util.stream.Stream;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraftforge.fluids.FluidStack;
+
import com.google.common.collect.ImmutableList;
import com.gtnewhorizon.structurelib.structure.IStructureElement;
+
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
@@ -33,17 +47,6 @@ import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import gregtech.api.util.GT_Single_Recipe_Check_Processing_Array;
import gregtech.api.util.GT_Utility;
import gregtech.common.blocks.GT_Item_Machines;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-import java.util.Objects;
-import java.util.stream.Stream;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_ProcessingArray
extends GT_MetaTileEntity_CubicMultiBlockBase<GT_MetaTileEntity_ProcessingArray> {
@@ -75,25 +78,17 @@ public class GT_MetaTileEntity_ProcessingArray
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Processing Array")
- .addInfo("Runs supplied machines as if placed in the world")
+ tt.addMachineType("Processing Array").addInfo("Runs supplied machines as if placed in the world")
.addInfo("Place up to 64 singleblock GT machines into the controller")
.addInfo("Note that you still need to supply power to them all")
.addInfo("Use a screwdriver to enable separate input busses")
.addInfo("Use a wire cutter to disable UEV+ downtiering")
.addInfo("Doesn't work on certain machines, deal with it")
- .addInfo("Use it if you hate GT++, or want even more speed later on")
- .addSeparator()
- .beginStructureBlock(3, 3, 3, true)
- .addController("Front center")
- .addCasingInfo("Robust Tungstensteel Machine Casing", 14)
- .addEnergyHatch("Any casing", 1)
- .addMaintenanceHatch("Any casing", 1)
- .addInputBus("Any casing", 1)
- .addInputHatch("Any casing", 1)
- .addOutputBus("Any casing", 1)
- .addOutputHatch("Any casing", 1)
- .toolTipFinisher("Gregtech");
+ .addInfo("Use it if you hate GT++, or want even more speed later on").addSeparator()
+ .beginStructureBlock(3, 3, 3, true).addController("Front center")
+ .addCasingInfo("Robust Tungstensteel Machine Casing", 14).addEnergyHatch("Any casing", 1)
+ .addMaintenanceHatch("Any casing", 1).addInputBus("Any casing", 1).addInputHatch("Any casing", 1)
+ .addOutputBus("Any casing", 1).addOutputHatch("Any casing", 1).toolTipFinisher("Gregtech");
return tt;
}
@@ -104,65 +99,28 @@ public class GT_MetaTileEntity_ProcessingArray
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- BlockIcons.casingTexturePages[0][48],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- BlockIcons.casingTexturePages[0][48],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { BlockIcons.casingTexturePages[0][48],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { BlockIcons.casingTexturePages[0][48],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PROCESSING_ARRAY_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {Textures.BlockIcons.casingTexturePages[0][48]};
+ return new ITexture[] { Textures.BlockIcons.casingTexturePages[0][48] };
}
// TODO: Expand so it also does the non recipe map recipes
/*
- public void remoteRecipeCheck() {
- if (mInventory[1] == null) return;
- String tmp = mInventory[1].getUnlocalizedName().replaceAll("gt.blockmachines.basicmachine.", "");
- if (tmp.startsWith("replicator")) {
-
- } else if (tmp.startsWith("brewery")) {
-
- } else if (tmp.startsWith("packer")) {
-
- } else if (tmp.startsWith("printer")) {
-
- } else if (tmp.startsWith("disassembler")) {
-
- } else if (tmp.startsWith("massfab")) {
-
- } else if (tmp.startsWith("scanner")) {
-
- }
- }
- */
+ * public void remoteRecipeCheck() { if (mInventory[1] == null) return; String tmp =
+ * mInventory[1].getUnlocalizedName().replaceAll("gt.blockmachines.basicmachine.", ""); if
+ * (tmp.startsWith("replicator")) { } else if (tmp.startsWith("brewery")) { } else if (tmp.startsWith("packer")) { }
+ * else if (tmp.startsWith("printer")) { } else if (tmp.startsWith("disassembler")) { } else if
+ * (tmp.startsWith("massfab")) { } else if (tmp.startsWith("scanner")) { } }
+ */
// Gets the recipe map for the given machine through its unlocalized name
@Override
@@ -233,23 +191,29 @@ public class GT_MetaTileEntity_ProcessingArray
}
public boolean processLockedRecipe() {
- GT_Single_Recipe_Check_Processing_Array tSingleRecipeCheck =
- (GT_Single_Recipe_Check_Processing_Array) mSingleRecipeCheck;
+ GT_Single_Recipe_Check_Processing_Array tSingleRecipeCheck = (GT_Single_Recipe_Check_Processing_Array) mSingleRecipeCheck;
int machines = mInventory[1].stackSize << mMult;
int parallel = tSingleRecipeCheck.checkRecipeInputs(true, machines);
return processRecipeOutputs(
- tSingleRecipeCheck.getRecipe(), tSingleRecipeCheck.getRecipeAmperage(), parallel, 1);
+ tSingleRecipeCheck.getRecipe(),
+ tSingleRecipeCheck.getRecipeAmperage(),
+ parallel,
+ 1);
}
public boolean processRecipe(ItemStack[] tInputs, FluidStack[] tFluids, GT_Recipe.GT_Recipe_Map map) {
if (tInputs.length <= 0 && tFluids.length <= 0) return false;
GT_Recipe tRecipe = map.findRecipe(
- getBaseMetaTileEntity(), mLastRecipe, false, gregtech.api.enums.GT_Values.V[tTier], tFluids, tInputs);
+ getBaseMetaTileEntity(),
+ mLastRecipe,
+ false,
+ gregtech.api.enums.GT_Values.V[tTier],
+ tFluids,
+ tInputs);
if (tRecipe == null) return false;
- if (GT_Mod.gregtechproxy.mLowGravProcessing
- && tRecipe.mSpecialValue == -100
+ if (GT_Mod.gregtechproxy.mLowGravProcessing && tRecipe.mSpecialValue == -100
&& !isValidForLowGravity(tRecipe, getBaseMetaTileEntity().getWorld().provider.dimensionId))
return false;
@@ -270,11 +234,8 @@ public class GT_MetaTileEntity_ProcessingArray
break;
} else if (mLockedToSingleRecipe && !recipeLocked) {
// We want to lock to a single run of the recipe.
- mSingleRecipeCheck = tSingleRecipeCheckBuilder
- .setAfter(tInputs, tFluids)
- .setRecipe(tRecipe)
- .setRecipeAmperage(map.mAmperage)
- .build();
+ mSingleRecipeCheck = tSingleRecipeCheckBuilder.setAfter(tInputs, tFluids).setRecipe(tRecipe)
+ .setRecipeAmperage(map.mAmperage).build();
recipeLocked = true;
}
}
@@ -304,7 +265,11 @@ public class GT_MetaTileEntity_ProcessingArray
this.mEfficiency = (10000 - (getIdealStatus() - getRepairStatus()) * 1000);
this.mEfficiencyIncrease = 10000;
ProcessingArrayCalculateOverclock(
- aRecipe.mEUt, aRecipe.mDuration * multiplier, aAmperage, GT_Values.V[tTier], false);
+ aRecipe.mEUt,
+ aRecipe.mDuration * multiplier,
+ aAmperage,
+ GT_Values.V[tTier],
+ false);
// In case recipe is too OP for that machine
if (mMaxProgresstime == Integer.MAX_VALUE - 1 && mEUPerTick == Long.MAX_VALUE - 1) return false;
mEUPerTick = mEUPerTick * parallel;
@@ -322,8 +287,7 @@ public class GT_MetaTileEntity_ProcessingArray
}
FluidStack[] tFOut = new FluidStack[aRecipe.mFluidOutputs.length];
for (int i = 0; i < aRecipe.mFluidOutputs.length; i++)
- if (aRecipe.getFluidOutput(i) != null)
- tFOut[i] = aRecipe.getFluidOutput(i).copy();
+ if (aRecipe.getFluidOutput(i) != null) tFOut[i] = aRecipe.getFluidOutput(i).copy();
for (int f = 0; f < tOut.length; f++) {
if (aRecipe.mOutputs[f] != null && tOut[f] != null) {
for (int g = 0; g < parallel * multiplier; g++) {
@@ -341,10 +305,8 @@ public class GT_MetaTileEntity_ProcessingArray
oNumber++;
}
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
- this.mOutputItems = Arrays.stream(tOut)
- .filter(Objects::nonNull)
- .flatMap(GT_MetaTileEntity_ProcessingArray::splitOversizedStack)
- .filter(is -> is.stackSize > 0)
+ this.mOutputItems = Arrays.stream(tOut).filter(Objects::nonNull)
+ .flatMap(GT_MetaTileEntity_ProcessingArray::splitOversizedStack).filter(is -> is.stackSize > 0)
.toArray(ItemStack[]::new);
this.mOutputFluids = tFOut;
updateSlots();
@@ -420,13 +382,14 @@ public class GT_MetaTileEntity_ProcessingArray
} else {
mSeparate = !mSeparate;
GT_Utility.sendChatToPlayer(
- aPlayer, StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + mSeparate);
+ aPlayer,
+ StatCollector.translateToLocal("GT5U.machines.separatebus") + " " + mSeparate);
}
}
@Override
- public boolean onWireCutterRightClick(
- byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public boolean onWireCutterRightClick(byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY,
+ float aZ) {
if (aPlayer.isSneaking()) {
mUseMultiparallelMode = !mUseMultiparallelMode;
if (mUseMultiparallelMode) {
@@ -460,8 +423,8 @@ public class GT_MetaTileEntity_ProcessingArray
@Override
protected List<IHatchElement<? super GT_MetaTileEntity_CubicMultiBlockBase<?>>> getAllowedHatches() {
- return ImmutableList.of(
- InputHatch, OutputHatch, InputBus, OutputBus, Muffler, Maintenance, Energy, ExoticEnergy);
+ return ImmutableList
+ .of(InputHatch, OutputHatch, InputBus, OutputBus, Muffler, Maintenance, Energy, ExoticEnergy);
}
@Override
@@ -487,41 +450,71 @@ public class GT_MetaTileEntity_ProcessingArray
}
return new String[] {
- StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(mProgresstime / 20) + EnumChatFormatting.RESET + " s / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(mMaxProgresstime / 20) + EnumChatFormatting.RESET + " s",
- StatCollector.translateToLocal("GT5U.multiblock.energy") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers(storedEnergy) + EnumChatFormatting.RESET + " EU / "
- + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(maxEnergy) + EnumChatFormatting.RESET + " EU",
- StatCollector.translateToLocal("GT5U.multiblock.usage") + ": " + EnumChatFormatting.RED
- + GT_Utility.formatNumbers(-mEUPerTick) + EnumChatFormatting.RESET + " EU/t",
- StatCollector.translateToLocal("GT5U.multiblock.mei") + ": " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(
- GT_ExoticEnergyInputHelper.getMaxInputVoltageMulti(getExoticAndNormalEnergyHatchList()))
- + EnumChatFormatting.RESET + " EU/t(*"
- + GT_Utility.formatNumbers(
- GT_ExoticEnergyInputHelper.getMaxInputAmpsMulti(getExoticAndNormalEnergyHatchList()))
- + "A) " + StatCollector.translateToLocal("GT5U.machines.tier")
- + ": " + EnumChatFormatting.YELLOW
- + VN[
- GT_Utility.getTier(GT_ExoticEnergyInputHelper.getMaxInputVoltageMulti(
- getExoticAndNormalEnergyHatchList()))]
- + EnumChatFormatting.RESET,
- StatCollector.translateToLocal("GT5U.multiblock.problems") + ": " + EnumChatFormatting.RED
- + (getIdealStatus() - getRepairStatus()) + EnumChatFormatting.RESET + " "
- + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
- + ": " + EnumChatFormatting.YELLOW
- + mEfficiency / 100.0F + EnumChatFormatting.RESET + " %",
- StatCollector.translateToLocal("GT5U.PA.machinetier") + ": " + EnumChatFormatting.GREEN
- + tTier + EnumChatFormatting.RESET + " " + StatCollector.translateToLocal("GT5U.PA.discount")
- + ": " + EnumChatFormatting.GREEN
- + 1 + EnumChatFormatting.RESET + " x",
- StatCollector.translateToLocal("GT5U.PA.parallel") + ": " + EnumChatFormatting.GREEN
- + GT_Utility.formatNumbers((mInventory[1] != null) ? (mInventory[1].stackSize << mMult) : 0)
- + EnumChatFormatting.RESET
- };
+ StatCollector.translateToLocal("GT5U.multiblock.Progress") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(mProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(mMaxProgresstime / 20)
+ + EnumChatFormatting.RESET
+ + " s",
+ StatCollector.translateToLocal("GT5U.multiblock.energy") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers(storedEnergy)
+ + EnumChatFormatting.RESET
+ + " EU / "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(maxEnergy)
+ + EnumChatFormatting.RESET
+ + " EU",
+ StatCollector.translateToLocal("GT5U.multiblock.usage") + ": "
+ + EnumChatFormatting.RED
+ + GT_Utility.formatNumbers(-mEUPerTick)
+ + EnumChatFormatting.RESET
+ + " EU/t",
+ StatCollector.translateToLocal("GT5U.multiblock.mei") + ": "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(
+ GT_ExoticEnergyInputHelper.getMaxInputVoltageMulti(getExoticAndNormalEnergyHatchList()))
+ + EnumChatFormatting.RESET
+ + " EU/t(*"
+ + GT_Utility.formatNumbers(
+ GT_ExoticEnergyInputHelper.getMaxInputAmpsMulti(getExoticAndNormalEnergyHatchList()))
+ + "A) "
+ + StatCollector.translateToLocal("GT5U.machines.tier")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + VN[GT_Utility.getTier(
+ GT_ExoticEnergyInputHelper
+ .getMaxInputVoltageMulti(getExoticAndNormalEnergyHatchList()))]
+ + EnumChatFormatting.RESET,
+ StatCollector.translateToLocal("GT5U.multiblock.problems") + ": "
+ + EnumChatFormatting.RED
+ + (getIdealStatus() - getRepairStatus())
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.multiblock.efficiency")
+ + ": "
+ + EnumChatFormatting.YELLOW
+ + mEfficiency / 100.0F
+ + EnumChatFormatting.RESET
+ + " %",
+ StatCollector.translateToLocal("GT5U.PA.machinetier") + ": "
+ + EnumChatFormatting.GREEN
+ + tTier
+ + EnumChatFormatting.RESET
+ + " "
+ + StatCollector.translateToLocal("GT5U.PA.discount")
+ + ": "
+ + EnumChatFormatting.GREEN
+ + 1
+ + EnumChatFormatting.RESET
+ + " x",
+ StatCollector.translateToLocal("GT5U.PA.parallel") + ": "
+ + EnumChatFormatting.GREEN
+ + GT_Utility.formatNumbers((mInventory[1] != null) ? (mInventory[1].stackSize << mMult) : 0)
+ + EnumChatFormatting.RESET };
}
public List<GT_MetaTileEntity_Hatch> getExoticAndNormalEnergyHatchList() {
@@ -543,8 +536,8 @@ public class GT_MetaTileEntity_ProcessingArray
return true;
}
- protected void ProcessingArrayCalculateOverclock(
- long aEUt, int aDuration, int mAmperage, long maxInputVoltage, boolean perfectOC) {
+ protected void ProcessingArrayCalculateOverclock(long aEUt, int aDuration, int mAmperage, long maxInputVoltage,
+ boolean perfectOC) {
byte mTier = (byte) Math.max(0, GT_Utility.getTier(maxInputVoltage));
if (mTier == 0) {
// Long time calculation
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PyrolyseOven.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PyrolyseOven.java
index 5212dc9195..8e3f07df48 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PyrolyseOven.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_PyrolyseOven.java
@@ -13,11 +13,16 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_PYROLYSE_OVEN
import static gregtech.api.util.GT_StructureUtility.buildHatchAdder;
import static gregtech.api.util.GT_StructureUtility.ofCoil;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.alignment.constructable.ISurvivalConstructable;
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.IStructureElement;
import com.gtnewhorizon.structurelib.structure.ISurvivalBuildEnvironment;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
+
import cpw.mods.fml.common.Loader;
import gregtech.GT_Mod;
import gregtech.api.GregTech_API;
@@ -33,21 +38,16 @@ import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Single_Recipe_Check;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
-public class GT_MetaTileEntity_PyrolyseOven
- extends GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_PyrolyseOven>
- implements ISurvivalConstructable {
+public class GT_MetaTileEntity_PyrolyseOven extends
+ GT_MetaTileEntity_EnhancedMultiBlockBase<GT_MetaTileEntity_PyrolyseOven> implements ISurvivalConstructable {
private HeatingCoilLevel coilHeat;
// public static GT_CopiedBlockTexture mTextureULV = new
// GT_CopiedBlockTexture(Block.getBlockFromItem(ItemList.Casing_ULV.get(1).getItem()), 6, 0,
// Dyes.MACHINE_METAL.mRGBa);
private static final int CASING_INDEX = 1090;
- private static final IStructureDefinition<GT_MetaTileEntity_PyrolyseOven> STRUCTURE_DEFINITION =
- createStructureDefinition();
+ private static final IStructureDefinition<GT_MetaTileEntity_PyrolyseOven> STRUCTURE_DEFINITION = createStructureDefinition();
private static IStructureDefinition<GT_MetaTileEntity_PyrolyseOven> createStructureDefinition() {
IStructureElement<GT_MetaTileEntity_PyrolyseOven> tCasingElement = Loader.isModLoaded(MOD_ID_DC)
@@ -55,12 +55,13 @@ public class GT_MetaTileEntity_PyrolyseOven
: ofBlock(GregTech_API.sBlockCasings1, 0);
return StructureDefinition.<GT_MetaTileEntity_PyrolyseOven>builder()
- .addShape("main", transpose(new String[][] {
- {"ccccc", "ctttc", "ctttc", "ctttc", "ccccc"},
- {"ccccc", "c---c", "c---c", "c---c", "ccccc"},
- {"ccccc", "c---c", "c---c", "c---c", "ccccc"},
- {"bb~bb", "bCCCb", "bCCCb", "bCCCb", "bbbbb"},
- }))
+ .addShape(
+ "main",
+ transpose(
+ new String[][] { { "ccccc", "ctttc", "ctttc", "ctttc", "ccccc" },
+ { "ccccc", "c---c", "c---c", "c---c", "ccccc" },
+ { "ccccc", "c---c", "c---c", "c---c", "ccccc" },
+ { "bb~bb", "bCCCb", "bCCCb", "bCCCb", "bbbbb" }, }))
.addElement('c', onElementPass(GT_MetaTileEntity_PyrolyseOven::onCasingAdded, tCasingElement))
.addElement(
'C',
@@ -70,18 +71,13 @@ public class GT_MetaTileEntity_PyrolyseOven
.addElement(
'b',
buildHatchAdder(GT_MetaTileEntity_PyrolyseOven.class)
- .atLeast(OutputBus, OutputHatch, Energy, Maintenance)
- .casingIndex(CASING_INDEX)
- .dot(1)
+ .atLeast(OutputBus, OutputHatch, Energy, Maintenance).casingIndex(CASING_INDEX).dot(1)
.buildAndChain(
onElementPass(GT_MetaTileEntity_PyrolyseOven::onCasingAdded, tCasingElement)))
.addElement(
't',
- buildHatchAdder(GT_MetaTileEntity_PyrolyseOven.class)
- .atLeast(InputBus, InputHatch, Muffler)
- .casingIndex(CASING_INDEX)
- .dot(1)
- .buildAndChain(
+ buildHatchAdder(GT_MetaTileEntity_PyrolyseOven.class).atLeast(InputBus, InputHatch, Muffler)
+ .casingIndex(CASING_INDEX).dot(1).buildAndChain(
onElementPass(GT_MetaTileEntity_PyrolyseOven::onCasingAdded, tCasingElement)))
.build();
}
@@ -99,65 +95,33 @@ public class GT_MetaTileEntity_PyrolyseOven
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Coke Oven")
- .addInfo("Controller block for the Pyrolyse Oven")
- .addInfo("Industrial Charcoal producer")
- .addInfo("Processing speed scales linearly with Coil tier:")
+ tt.addMachineType("Coke Oven").addInfo("Controller block for the Pyrolyse Oven")
+ .addInfo("Industrial Charcoal producer").addInfo("Processing speed scales linearly with Coil tier:")
.addInfo("CuNi: 50%, FeAlCr: 100%, Ni4Cr: 150%, Fe50CW: 200%, etc.")
- .addInfo("EU/t is not affected by Coil tier")
- .addPollutionAmount(getPollutionPerSecond(null))
- .addSeparator()
- .beginStructureBlock(5, 4, 5, true)
- .addController("Front center")
+ .addInfo("EU/t is not affected by Coil tier").addPollutionAmount(getPollutionPerSecond(null))
+ .addSeparator().beginStructureBlock(5, 4, 5, true).addController("Front center")
.addCasingInfo("Pyrolyse Oven Casing", 60)
.addOtherStructurePart("Heating Coils", "Center 3x1x3 of the bottom layer")
- .addEnergyHatch("Any bottom layer casing", 1)
- .addMaintenanceHatch("Any bottom layer casing", 1)
- .addMufflerHatch("Center 3x1x3 area in top layer", 2)
- .addInputBus("Center 3x1x3 area in top layer", 2)
- .addInputHatch("Center 3x1x3 area in top layer", 2)
- .addOutputBus("Any bottom layer casing", 1)
- .addOutputHatch("Any bottom layer casing", 1)
- .toolTipFinisher("Gregtech");
+ .addEnergyHatch("Any bottom layer casing", 1).addMaintenanceHatch("Any bottom layer casing", 1)
+ .addMufflerHatch("Center 3x1x3 area in top layer", 2).addInputBus("Center 3x1x3 area in top layer", 2)
+ .addInputHatch("Center 3x1x3 area in top layer", 2).addOutputBus("Any bottom layer casing", 1)
+ .addOutputHatch("Any bottom layer casing", 1).toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- if (aActive)
- return new ITexture[] {
- BlockIcons.casingTexturePages[8][66],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PYROLYSE_OVEN_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PYROLYSE_OVEN_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
- return new ITexture[] {
- BlockIcons.casingTexturePages[8][66],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PYROLYSE_OVEN)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_PYROLYSE_OVEN_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ if (aActive) return new ITexture[] { BlockIcons.casingTexturePages[8][66],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PYROLYSE_OVEN_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PYROLYSE_OVEN_ACTIVE_GLOW).extFacing().glow()
+ .build() };
+ return new ITexture[] { BlockIcons.casingTexturePages[8][66],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PYROLYSE_OVEN).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_PYROLYSE_OVEN_GLOW).extFacing().glow().build() };
}
- return new ITexture[] {Textures.BlockIcons.casingTexturePages[8][66]};
+ return new ITexture[] { Textures.BlockIcons.casingTexturePages[8][66] };
}
@Override
@@ -191,13 +155,16 @@ public class GT_MetaTileEntity_PyrolyseOven
}
tRecipe = GT_Recipe.GT_Recipe_Map.sPyrolyseRecipes.findRecipe(
- getBaseMetaTileEntity(), false, gregtech.api.enums.GT_Values.V[tTier], tFluids, tInputs);
+ getBaseMetaTileEntity(),
+ false,
+ gregtech.api.enums.GT_Values.V[tTier],
+ tFluids,
+ tInputs);
if (tRecipe == null || !tRecipe.isRecipeInputEqual(true, tFluids, tInputs)) return false;
if (mLockedToSingleRecipe) {
- mSingleRecipeCheck =
- tSingleRecipeCheckBuilder.setAfter().setRecipe(tRecipe).build();
+ mSingleRecipeCheck = tSingleRecipeCheckBuilder.setAfter().setRecipe(tRecipe).build();
}
}
@@ -209,8 +176,8 @@ public class GT_MetaTileEntity_PyrolyseOven
if (mMaxProgresstime == Integer.MAX_VALUE - 1 && mEUt == Integer.MAX_VALUE - 1) return false;
if (this.mEUt > 0) this.mEUt = (-this.mEUt);
this.mMaxProgresstime = Math.max(mMaxProgresstime * 2 / (1 + coilHeat.getTier()), 1);
- if (tRecipe.mOutputs.length > 0) this.mOutputItems = new ItemStack[] {tRecipe.getOutput(0)};
- if (tRecipe.mFluidOutputs.length > 0) this.mOutputFluids = new FluidStack[] {tRecipe.getFluidOutput(0)};
+ if (tRecipe.mOutputs.length > 0) this.mOutputItems = new ItemStack[] { tRecipe.getOutput(0) };
+ if (tRecipe.mFluidOutputs.length > 0) this.mOutputFluids = new FluidStack[] { tRecipe.getFluidOutput(0) };
updateSlots();
return true;
}
@@ -237,8 +204,7 @@ public class GT_MetaTileEntity_PyrolyseOven
coilHeat = HeatingCoilLevel.None;
mCasingAmount = 0;
replaceDeprecatedCoils(aBaseMetaTileEntity);
- return checkPiece("main", 2, 3, 0)
- && mCasingAmount >= 60
+ return checkPiece("main", 2, 3, 0) && mCasingAmount >= 60
&& mMaintenanceHatches.size() == 1
&& !mMufflerHatches.isEmpty();
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_VacuumFreezer.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_VacuumFreezer.java
index f942123109..681a4dfd63 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_VacuumFreezer.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_VacuumFreezer.java
@@ -6,8 +6,12 @@ import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_VACUUM_FREEZE
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_FRONT_VACUUM_FREEZER_GLOW;
import static gregtech.api.enums.Textures.BlockIcons.casingTexturePages;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.fluids.FluidStack;
+
import com.gtnewhorizon.structurelib.structure.IStructureElement;
import com.gtnewhorizon.structurelib.structure.StructureUtility;
+
import gregtech.api.GregTech_API;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -17,11 +21,10 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_VacuumFreezer
extends GT_MetaTileEntity_CubicMultiBlockBase<GT_MetaTileEntity_VacuumFreezer> {
+
public GT_MetaTileEntity_VacuumFreezer(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional);
}
@@ -38,62 +41,33 @@ public class GT_MetaTileEntity_VacuumFreezer
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Vacuum Freezer")
- .addInfo("Controller Block for the Vacuum Freezer")
- .addInfo("Cools hot ingots and cells")
- .addSeparator()
- .beginStructureBlock(3, 3, 3, true)
- .addController("Front center")
- .addCasingInfo("Frost Proof Machine Casing", 16)
- .addEnergyHatch("Any casing", 1)
- .addMaintenanceHatch("Any casing", 1)
- .addInputHatch("Any casing", 1)
- .addOutputHatch("Any casing", 1)
- .addInputBus("Any casing", 1)
- .addOutputBus("Any casing", 1)
+ tt.addMachineType("Vacuum Freezer").addInfo("Controller Block for the Vacuum Freezer")
+ .addInfo("Cools hot ingots and cells").addSeparator().beginStructureBlock(3, 3, 3, true)
+ .addController("Front center").addCasingInfo("Frost Proof Machine Casing", 16)
+ .addEnergyHatch("Any casing", 1).addMaintenanceHatch("Any casing", 1).addInputHatch("Any casing", 1)
+ .addOutputHatch("Any casing", 1).addInputBus("Any casing", 1).addOutputBus("Any casing", 1)
.toolTipFinisher("Gregtech");
return tt;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
ITexture[] rTexture;
if (aSide == aFacing) {
if (aActive) {
- rTexture = new ITexture[] {
- casingTexturePages[0][17],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_VACUUM_FREEZER_ACTIVE)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_VACUUM_FREEZER_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ rTexture = new ITexture[] { casingTexturePages[0][17],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_VACUUM_FREEZER_ACTIVE).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_VACUUM_FREEZER_ACTIVE_GLOW).extFacing().glow()
+ .build() };
} else {
- rTexture = new ITexture[] {
- casingTexturePages[0][17],
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_VACUUM_FREEZER)
- .extFacing()
- .build(),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_VACUUM_FREEZER_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ rTexture = new ITexture[] { casingTexturePages[0][17],
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_VACUUM_FREEZER).extFacing().build(),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_VACUUM_FREEZER_GLOW).extFacing().glow()
+ .build() };
}
} else {
- rTexture = new ITexture[] {casingTexturePages[0][17]};
+ rTexture = new ITexture[] { casingTexturePages[0][17] };
}
return rTexture;
}
@@ -115,9 +89,12 @@ public class GT_MetaTileEntity_VacuumFreezer
long tVoltage = getMaxInputVoltage();
byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
- GT_Recipe tRecipe = getRecipeMap()
- .findRecipe(
- getBaseMetaTileEntity(), false, gregtech.api.enums.GT_Values.V[tTier], tFluidList, tInputList);
+ GT_Recipe tRecipe = getRecipeMap().findRecipe(
+ getBaseMetaTileEntity(),
+ false,
+ gregtech.api.enums.GT_Values.V[tTier],
+ tFluidList,
+ tInputList);
if (tRecipe != null) {
if (tRecipe.isRecipeInputEqual(true, tFluidList, tInputList)) {
this.mEfficiency = (10000 - (getIdealStatus() - getRepairStatus()) * 1000);
@@ -130,8 +107,8 @@ public class GT_MetaTileEntity_VacuumFreezer
this.mEUt = (-this.mEUt);
}
this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
- this.mOutputItems = new ItemStack[] {tRecipe.getOutput(0)};
- this.mOutputFluids = new FluidStack[] {tRecipe.getFluidOutput(0)};
+ this.mOutputItems = new ItemStack[] { tRecipe.getOutput(0) };
+ this.mOutputFluids = new FluidStack[] { tRecipe.getFluidOutput(0) };
updateSlots();
return true;
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/multiblock/MultiBlock_Macerator.java b/src/main/java/gregtech/common/tileentities/machines/multiblock/MultiBlock_Macerator.java
index 09aae61527..757b3ea72d 100644
--- a/src/main/java/gregtech/common/tileentities/machines/multiblock/MultiBlock_Macerator.java
+++ b/src/main/java/gregtech/common/tileentities/machines/multiblock/MultiBlock_Macerator.java
@@ -12,16 +12,19 @@ import static gregtech.api.multitileentity.multiblock.base.MultiBlockPart.ITEM_I
import static gregtech.api.multitileentity.multiblock.base.MultiBlockPart.ITEM_OUT;
import static gregtech.api.multitileentity.multiblock.base.MultiBlockPart.NOTHING;
+import net.minecraft.block.Block;
+
import com.gtnewhorizon.structurelib.structure.IStructureDefinition;
import com.gtnewhorizon.structurelib.structure.StructureDefinition;
import com.gtnewhorizon.structurelib.util.Vec3Impl;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.multitileentity.multiblock.base.MultiBlock_Stackable;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Multiblock_Tooltip_Builder;
-import net.minecraft.block.Block;
public class MultiBlock_Macerator extends MultiBlock_Stackable<MultiBlock_Macerator> {
+
private IStructureDefinition<MultiBlock_Macerator> STRUCTURE_DEFINITION = null;
@Override
@@ -33,23 +36,25 @@ public class MultiBlock_Macerator extends MultiBlock_Stackable<MultiBlock_Macera
public IStructureDefinition<MultiBlock_Macerator> getStructureDefinition() {
if (STRUCTURE_DEFINITION == null) {
STRUCTURE_DEFINITION = StructureDefinition.<MultiBlock_Macerator>builder()
- .addShape(STACKABLE_TOP, transpose(new String[][] {
- {" CCC ", "CCCCC", "CCCCC", "CCCCC", " CCC "},
- }))
- .addShape(STACKABLE_MIDDLE, transpose(new String[][] {
- {" BBB ", " B---B ", "DC---CD", " B---B ", " BBB "},
- }))
- .addShape(STACKABLE_BOTTOM, transpose(new String[][] {
- {" A~A ", "AAAAA", "AAAAA", "AAAAA", " AAA "},
- }))
+ .addShape(
+ STACKABLE_TOP,
+ transpose(new String[][] { { " CCC ", "CCCCC", "CCCCC", "CCCCC", " CCC " }, }))
+ .addShape(
+ STACKABLE_MIDDLE,
+ transpose(new String[][] { { " BBB ", " B---B ", "DC---CD", " B---B ", " BBB " }, }))
+ .addShape(
+ STACKABLE_BOTTOM,
+ transpose(new String[][] { { " A~A ", "AAAAA", "AAAAA", "AAAAA", " AAA " }, }))
.addElement('A', ofChain(addMultiTileCasing(getCasingRegistryID(), getCasingMeta(), ENERGY_IN)))
.addElement(
'B',
- ofChain(addMultiTileCasing(
- getCasingRegistryID(), getCasingMeta(), FLUID_IN | ITEM_IN | FLUID_OUT | ITEM_OUT)))
+ ofChain(
+ addMultiTileCasing(
+ getCasingRegistryID(),
+ getCasingMeta(),
+ FLUID_IN | ITEM_IN | FLUID_OUT | ITEM_OUT)))
.addElement('C', addMultiTileCasing(getCasingRegistryID(), getCasingMeta(), NOTHING))
- .addElement('D', addMultiTileCasing(getCasingRegistryID(), getCasingMeta(), NOTHING))
- .build();
+ .addElement('D', addMultiTileCasing(getCasingRegistryID(), getCasingMeta(), NOTHING)).build();
}
return STRUCTURE_DEFINITION;
}
@@ -72,12 +77,9 @@ public class MultiBlock_Macerator extends MultiBlock_Stackable<MultiBlock_Macera
@Override
protected GT_Multiblock_Tooltip_Builder createTooltip() {
final GT_Multiblock_Tooltip_Builder tt = new GT_Multiblock_Tooltip_Builder();
- tt.addMachineType("Macerator")
- .addInfo("Controller for the Macerator")
- .addSeparator()
+ tt.addMachineType("Macerator").addInfo("Controller for the Macerator").addSeparator()
.beginVariableStructureBlock(7, 9, 2 + getMinStacks(), 2 + getMaxStacks(), 7, 9, true)
- .addController("Bottom Front Center")
- .addCasingInfo("Test Casing", 60)
+ .addController("Bottom Front Center").addCasingInfo("Test Casing", 60)
.addEnergyHatch("Any bottom layer casing")
.addInputHatch("Any non-optional external facing casing on the stacks")
.addInputBus("Any non-optional external facing casing on the stacks")
@@ -124,22 +126,15 @@ public class MultiBlock_Macerator extends MultiBlock_Stackable<MultiBlock_Macera
// TODO: MTE(Texture)
if (mFacing == aSide) {
return new ITexture[] {
- // Base Texture
- MACHINE_CASINGS[1][0],
- // Active
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE)
- .extFacing()
- .build(),
- // Active Glow
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE_GLOW)
- .extFacing()
- .glow()
- .build()
- };
+ // Base Texture
+ MACHINE_CASINGS[1][0],
+ // Active
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE).extFacing().build(),
+ // Active Glow
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_ELECTRIC_BLAST_FURNACE_ACTIVE_GLOW).extFacing()
+ .glow().build() };
}
// Base Texture
- return new ITexture[] {MACHINE_CASINGS[1][0]};
+ return new ITexture[] { MACHINE_CASINGS[1][0] };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Bronze.java
index 3aefd2d16f..4f9677eda6 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Bronze.java
@@ -12,6 +12,7 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_AlloySmelter_Bronze extends GT_MetaTileEntity_BasicMachine_Bronze {
+
public GT_MetaTileEntity_AlloySmelter_Bronze(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Combination Smelter", 2, 1, false);
}
@@ -54,97 +55,57 @@ public class GT_MetaTileEntity_AlloySmelter_Bronze extends GT_MetaTileEntity_Bas
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Steel.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Steel.java
index 9926c8a5e7..ca08d647a1 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_AlloySmelter_Steel.java
@@ -12,6 +12,7 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_AlloySmelter_Steel extends GT_MetaTileEntity_BasicMachine_Steel {
+
public GT_MetaTileEntity_AlloySmelter_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Combination Smelter", 2, 1, true);
}
@@ -54,97 +55,57 @@ public class GT_MetaTileEntity_AlloySmelter_Steel extends GT_MetaTileEntity_Basi
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_ALLOY_SMELTER_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Bronze.java
index 5706345c3b..3f7eed2c99 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Bronze.java
@@ -12,6 +12,7 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_Compressor_Bronze extends GT_MetaTileEntity_BasicMachine_Bronze {
+
public GT_MetaTileEntity_Compressor_Bronze(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Compressing Items", 1, 1, false);
}
@@ -49,97 +50,56 @@ public class GT_MetaTileEntity_Compressor_Bronze extends GT_MetaTileEntity_Basic
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Steel.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Steel.java
index 693f5abdbc..3f6e318284 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Compressor_Steel.java
@@ -12,6 +12,7 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_Compressor_Steel extends GT_MetaTileEntity_BasicMachine_Steel {
+
public GT_MetaTileEntity_Compressor_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Compressing Items", 1, 1, true);
}
@@ -49,97 +50,56 @@ public class GT_MetaTileEntity_Compressor_Steel extends GT_MetaTileEntity_BasicM
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_COMPRESSOR_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_COMPRESSOR_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_COMPRESSOR_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_COMPRESSOR),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_COMPRESSOR_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Bronze.java
index 7fa8358974..d9597663da 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Bronze.java
@@ -12,6 +12,7 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_Extractor_Bronze extends GT_MetaTileEntity_BasicMachine_Bronze {
+
public GT_MetaTileEntity_Extractor_Bronze(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Extracting your first Rubber", 1, 1, false);
}
@@ -49,97 +50,55 @@ public class GT_MetaTileEntity_Extractor_Bronze extends GT_MetaTileEntity_BasicM
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Steel.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Steel.java
index c18a7e8a51..f90e0044bd 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Extractor_Steel.java
@@ -12,6 +12,7 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
public class GT_MetaTileEntity_Extractor_Steel extends GT_MetaTileEntity_BasicMachine_Steel {
+
public GT_MetaTileEntity_Extractor_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Extracting your first Rubber", 1, 1, true);
}
@@ -49,97 +50,55 @@ public class GT_MetaTileEntity_Extractor_Steel extends GT_MetaTileEntity_BasicMa
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_EXTRACTOR_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_EXTRACTOR_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_EXTRACTOR_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_EXTRACTOR),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_EXTRACTOR_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Bronze.java
index 9709207ab3..3f25499dd8 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Bronze.java
@@ -3,6 +3,9 @@ package gregtech.common.tileentities.machines.steam;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.block.Block;
+import net.minecraftforge.common.util.ForgeDirection;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.enums.ParticleFX;
@@ -15,10 +18,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
-import net.minecraft.block.Block;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_ForgeHammer_Bronze extends GT_MetaTileEntity_BasicMachine_Bronze {
+
public GT_MetaTileEntity_ForgeHammer_Bronze(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Forge Hammer", 1, 1, false);
}
@@ -56,103 +58,58 @@ public class GT_MetaTileEntity_ForgeHammer_Bronze extends GT_MetaTileEntity_Basi
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_HAMMER_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_HAMMER_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_HAMMER_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_GLOW).glow().build() };
}
/**
- * Handles {@link Block#randomDisplayTick}.
- * Draws Random Sparkles at main face.
+ * Handles {@link Block#randomDisplayTick}. Draws Random Sparkles at main face.
*
* @param aBaseMetaTileEntity The entity that will handle the {@see Block#randomDisplayTick}
*/
@@ -165,8 +122,7 @@ public class GT_MetaTileEntity_ForgeHammer_Bronze extends GT_MetaTileEntity_Basi
final byte mainFacing = (byte) this.mMainFacing;
- if (mainFacing > 1
- && aBaseMetaTileEntity.getCoverIDAtSide(mainFacing) == 0
+ if (mainFacing > 1 && aBaseMetaTileEntity.getCoverIDAtSide(mainFacing) == 0
&& !aBaseMetaTileEntity.getOpacityAtSide(mainFacing)) {
final double oX = aBaseMetaTileEntity.getXCoord();
@@ -202,10 +158,8 @@ public class GT_MetaTileEntity_ForgeHammer_Bronze extends GT_MetaTileEntity_Basi
mZ = .05D;
}
- ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder())
- .setMotion(mX, 0, mZ)
- .setPosition(x, y, z)
- .setWorld(getBaseMetaTileEntity().getWorld());
+ ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder()).setMotion(mX, 0, mZ)
+ .setPosition(x, y, z).setWorld(getBaseMetaTileEntity().getWorld());
particleEventBuilder.setIdentifier(ParticleFX.LAVA).run();
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Steel.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Steel.java
index d34cf2efb9..acfd8e6b28 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_ForgeHammer_Steel.java
@@ -3,6 +3,9 @@ package gregtech.common.tileentities.machines.steam;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.block.Block;
+import net.minecraftforge.common.util.ForgeDirection;
+
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import gregtech.api.enums.ParticleFX;
@@ -15,10 +18,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
-import net.minecraft.block.Block;
-import net.minecraftforge.common.util.ForgeDirection;
public class GT_MetaTileEntity_ForgeHammer_Steel extends GT_MetaTileEntity_BasicMachine_Steel {
+
public GT_MetaTileEntity_ForgeHammer_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Forge Hammer", 1, 1, true);
}
@@ -56,103 +58,58 @@ public class GT_MetaTileEntity_ForgeHammer_Steel extends GT_MetaTileEntity_Basic
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_HAMMER_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_FRONT_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_HAMMER_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_HAMMER_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_HAMMER),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_HAMMER_GLOW).glow().build() };
}
/**
- * Handles {@link Block#randomDisplayTick}.
- * Draws Random Sparkles at main face.
+ * Handles {@link Block#randomDisplayTick}. Draws Random Sparkles at main face.
*
* @param aBaseMetaTileEntity The entity that will handle the {@see Block#randomDisplayTick}
*/
@@ -165,8 +122,7 @@ public class GT_MetaTileEntity_ForgeHammer_Steel extends GT_MetaTileEntity_Basic
final byte mainFacing = (byte) this.mMainFacing;
- if (mainFacing > 1
- && aBaseMetaTileEntity.getCoverIDAtSide(mainFacing) == 0
+ if (mainFacing > 1 && aBaseMetaTileEntity.getCoverIDAtSide(mainFacing) == 0
&& !aBaseMetaTileEntity.getOpacityAtSide(mainFacing)) {
final double oX = aBaseMetaTileEntity.getXCoord();
@@ -202,10 +158,8 @@ public class GT_MetaTileEntity_ForgeHammer_Steel extends GT_MetaTileEntity_Basic
mZ = .05D;
}
- ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder())
- .setMotion(mX, 0, mZ)
- .setPosition(x, y, z)
- .setWorld(getBaseMetaTileEntity().getWorld());
+ ParticleEventBuilder particleEventBuilder = (new ParticleEventBuilder()).setMotion(mX, 0, mZ)
+ .setPosition(x, y, z).setWorld(getBaseMetaTileEntity().getWorld());
particleEventBuilder.setIdentifier(ParticleFX.LAVA).run();
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Bronze.java
index 15d971a0fb..e102d797e8 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Bronze.java
@@ -2,6 +2,8 @@ package gregtech.common.tileentities.machines.steam;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
@@ -11,9 +13,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_Furnace_Bronze extends GT_MetaTileEntity_BasicMachine_Bronze {
+
public GT_MetaTileEntity_Furnace_Bronze(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Smelting things with compressed Steam", 1, 1, false);
}
@@ -52,8 +54,8 @@ public class GT_MetaTileEntity_Furnace_Bronze extends GT_MetaTileEntity_BasicMac
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& GT_ModHandler.getSmeltingOutput(GT_Utility.copyAmount(64L, aStack), false, null) != null;
}
@@ -73,98 +75,55 @@ public class GT_MetaTileEntity_Furnace_Bronze extends GT_MetaTileEntity_BasicMac
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_FURNACE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_FURNACE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_FURNACE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_GLOW)
- .glow()
- .build())
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_GLOW).glow().build()) };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Steel.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Steel.java
index 85142dbd98..8d0414103e 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Furnace_Steel.java
@@ -2,6 +2,8 @@ package gregtech.common.tileentities.machines.steam;
import static gregtech.api.enums.Textures.BlockIcons.*;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
@@ -11,9 +13,9 @@ import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_ModHandler;
import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Utility;
-import net.minecraft.item.ItemStack;
public class GT_MetaTileEntity_Furnace_Steel extends GT_MetaTileEntity_BasicMachine_Steel {
+
public GT_MetaTileEntity_Furnace_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Smelting things with compressed Steam", 1, 1, true);
}
@@ -52,8 +54,8 @@ public class GT_MetaTileEntity_Furnace_Steel extends GT_MetaTileEntity_BasicMach
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& GT_ModHandler.getSmeltingOutput(GT_Utility.copyAmount(64L, aStack), false, null) != null;
}
@@ -73,97 +75,54 @@ public class GT_MetaTileEntity_Furnace_Steel extends GT_MetaTileEntity_BasicMach
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_FURNACE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_FRONT_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_FURNACE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_FURNACE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_FURNACE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_FURNACE_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Bronze.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Bronze.java
index e06a179fa7..def8af9fe3 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Bronze.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Bronze.java
@@ -4,6 +4,10 @@ import static gregtech.api.enums.GT_Values.V;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.enums.ParticleFX;
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.ITexture;
@@ -15,11 +19,9 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder.ParticleEventBuilder;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_Macerator_Bronze extends GT_MetaTileEntity_BasicMachine_Bronze {
+
public GT_MetaTileEntity_Macerator_Bronze(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Macerating your Ores", 1, 1, false);
}
@@ -48,15 +50,12 @@ public class GT_MetaTileEntity_Macerator_Bronze extends GT_MetaTileEntity_BasicM
&& aBaseMetaTileEntity.getCoverIDAtSide(topFacing) == 0
&& !aBaseMetaTileEntity.getOpacityAtSide(topFacing)) {
- new ParticleEventBuilder()
- .setMotion(0.0D, 0.0D, 0.0D)
- .setIdentifier(ParticleFX.SMOKE)
+ new ParticleEventBuilder().setMotion(0.0D, 0.0D, 0.0D).setIdentifier(ParticleFX.SMOKE)
.setPosition(
aBaseMetaTileEntity.getXCoord() + 0.8F - XSTR_INSTANCE.nextFloat() * 0.6F,
aBaseMetaTileEntity.getYCoord() + 0.9F + XSTR_INSTANCE.nextFloat() * 0.2F,
aBaseMetaTileEntity.getZCoord() + 0.8F - XSTR_INSTANCE.nextFloat() * 0.6F)
- .setWorld(getBaseMetaTileEntity().getWorld())
- .run();
+ .setWorld(getBaseMetaTileEntity().getWorld()).run();
}
}
}
@@ -77,7 +76,7 @@ public class GT_MetaTileEntity_Macerator_Bronze extends GT_MetaTileEntity_BasicM
return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
}
- if (!tRecipe.isRecipeInputEqual(true, new FluidStack[] {getFillableStack()}, getAllInputs()))
+ if (!tRecipe.isRecipeInputEqual(true, new FluidStack[] { getFillableStack() }, getAllInputs()))
return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
if (tRecipe.getOutput(0) != null) mOutputItems[0] = tRecipe.getOutput(0);
calculateOverclockedNess(tRecipe);
@@ -85,8 +84,8 @@ public class GT_MetaTileEntity_Macerator_Bronze extends GT_MetaTileEntity_BasicM
}
@Override
- protected boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ protected boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& GT_Recipe_Map.sMaceratorRecipes.containsInput(GT_Utility.copyAmount(64L, aStack));
}
@@ -106,97 +105,55 @@ public class GT_MetaTileEntity_Macerator_Bronze extends GT_MetaTileEntity_BasicM
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_MACERATOR_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_MACERATOR_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_MACERATOR_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Steel.java b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Steel.java
index 13270b9a83..81027ca069 100644
--- a/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Steel.java
+++ b/src/main/java/gregtech/common/tileentities/machines/steam/GT_MetaTileEntity_Macerator_Steel.java
@@ -4,6 +4,10 @@ import static gregtech.api.enums.GT_Values.V;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.objects.XSTR.XSTR_INSTANCE;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
import gregtech.api.enums.ParticleFX;
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.ITexture;
@@ -15,11 +19,9 @@ import gregtech.api.util.GT_Recipe;
import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import gregtech.api.util.GT_Utility;
import gregtech.api.util.WorldSpawnedEventBuilder;
-import net.minecraft.item.ItemStack;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.FluidStack;
public class GT_MetaTileEntity_Macerator_Steel extends GT_MetaTileEntity_BasicMachine_Steel {
+
public GT_MetaTileEntity_Macerator_Steel(int aID, String aName, String aNameRegional) {
super(aID, aName, aNameRegional, "Macerating your Ores", 1, 1, true);
}
@@ -48,15 +50,13 @@ public class GT_MetaTileEntity_Macerator_Steel extends GT_MetaTileEntity_BasicMa
&& aBaseMetaTileEntity.getCoverIDAtSide(topFacing) == 0
&& !aBaseMetaTileEntity.getOpacityAtSide(topFacing)) {
- new WorldSpawnedEventBuilder.ParticleEventBuilder()
- .setMotion(0.0D, 0.0D, 0.0D)
+ new WorldSpawnedEventBuilder.ParticleEventBuilder().setMotion(0.0D, 0.0D, 0.0D)
.setIdentifier(ParticleFX.SMOKE)
.setPosition(
aBaseMetaTileEntity.getXCoord() + 0.8F - XSTR_INSTANCE.nextFloat() * 0.6F,
aBaseMetaTileEntity.getYCoord() + 0.9F + XSTR_INSTANCE.nextFloat() * 0.2F,
aBaseMetaTileEntity.getZCoord() + 0.8F - XSTR_INSTANCE.nextFloat() * 0.6F)
- .setWorld(getBaseMetaTileEntity().getWorld())
- .run();
+ .setWorld(getBaseMetaTileEntity().getWorld()).run();
}
}
}
@@ -77,7 +77,7 @@ public class GT_MetaTileEntity_Macerator_Steel extends GT_MetaTileEntity_BasicMa
return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
}
- if (!tRecipe.isRecipeInputEqual(true, new FluidStack[] {getFillableStack()}, getAllInputs()))
+ if (!tRecipe.isRecipeInputEqual(true, new FluidStack[] { getFillableStack() }, getAllInputs()))
return FOUND_RECIPE_BUT_DID_NOT_MEET_REQUIREMENTS;
if (tRecipe.getOutput(0) != null) mOutputItems[0] = tRecipe.getOutput(0);
calculateOverclockedNess(tRecipe);
@@ -85,8 +85,8 @@ public class GT_MetaTileEntity_Macerator_Steel extends GT_MetaTileEntity_BasicMa
}
@Override
- public boolean allowPutStackValidated(
- IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide, ItemStack aStack) {
+ public boolean allowPutStackValidated(IGregTechTileEntity aBaseMetaTileEntity, int aIndex, byte aSide,
+ ItemStack aStack) {
return super.allowPutStackValidated(aBaseMetaTileEntity, aIndex, aSide, aStack)
&& GT_Recipe_Map.sMaceratorRecipes.containsInput(GT_Utility.copyAmount(64L, aStack));
}
@@ -106,97 +106,55 @@ public class GT_MetaTileEntity_Macerator_Steel extends GT_MetaTileEntity_BasicMa
@Override
public ITexture[] getSideFacingActive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getSideFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getSideFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_SIDE_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getSideFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_SIDE_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_SIDE_STEAM_MACERATOR_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingActive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getFrontFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getFrontFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_FRONT_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getFrontFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_FRONT_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_FRONT_STEAM_MACERATOR_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingActive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getTopFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getTopFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_TOP_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getTopFacingInactive(aColor)[0], TextureFactory.of(OVERLAY_TOP_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_TOP_STEAM_MACERATOR_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingActive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingActive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingActive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_ACTIVE_GLOW).glow().build() };
}
@Override
public ITexture[] getBottomFacingInactive(byte aColor) {
- return new ITexture[] {
- super.getBottomFacingInactive(aColor)[0],
- TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR),
- TextureFactory.builder()
- .addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_GLOW)
- .glow()
- .build()
- };
+ return new ITexture[] { super.getBottomFacingInactive(aColor)[0],
+ TextureFactory.of(OVERLAY_BOTTOM_STEAM_MACERATOR),
+ TextureFactory.builder().addIcon(OVERLAY_BOTTOM_STEAM_MACERATOR_GLOW).glow().build() };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalChestBase.java b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalChestBase.java
index 8ef639e89e..c40e05090b 100644
--- a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalChestBase.java
+++ b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalChestBase.java
@@ -4,11 +4,29 @@ import static gregtech.api.enums.Textures.BlockIcons.MACHINE_CASINGS;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_SCHEST;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_SCHEST_GLOW;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import mcp.mobius.waila.api.IWailaConfigHandler;
+import mcp.mobius.waila.api.IWailaDataAccessor;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.Constants;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import cpw.mods.fml.common.Optional;
import gregtech.api.GregTech_API;
import gregtech.api.enums.GT_Values;
@@ -21,36 +39,25 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_TieredMachi
import gregtech.api.objects.AE2DigitalChestHandler;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import mcp.mobius.waila.api.IWailaConfigHandler;
-import mcp.mobius.waila.api.IWailaDataAccessor;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.Constants;
@Optional.Interface(iface = "appeng.api.storage.IMEMonitor", modid = "appliedenergistics2", striprefs = true)
public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEntity_TieredMachineBlock
implements appeng.api.storage.IMEMonitor<appeng.api.storage.data.IAEItemStack>, IAddUIWidgets {
+
protected boolean mVoidOverflow = false;
protected boolean mDisableFilter;
- private Map<appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack>, Object> listeners =
- null;
+ private Map<appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack>, Object> listeners = null;
public GT_MetaTileEntity_DigitalChestBase(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 3, new String[] {
- "This Chest stores " + GT_Utility.formatNumbers(commonSizeCompute(aTier)) + " Blocks",
- "Use a screwdriver to enable",
- "voiding items on overflow",
- "Will keep its contents when harvested",
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 3,
+ new String[] { "This Chest stores " + GT_Utility.formatNumbers(commonSizeCompute(aTier)) + " Blocks",
+ "Use a screwdriver to enable", "voiding items on overflow",
+ "Will keep its contents when harvested", });
}
protected static int commonSizeCompute(int tier) {
@@ -84,24 +91,21 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
super(aName, aTier, 3, aDescription, aTextures);
}
- public GT_MetaTileEntity_DigitalChestBase(
- String aName, int aTier, String[] aDescription, ITexture[][][] aTextures) {
+ public GT_MetaTileEntity_DigitalChestBase(String aName, int aTier, String[] aDescription,
+ ITexture[][][] aTextures) {
super(aName, aTier, 3, aDescription, aTextures);
}
@Optional.Method(modid = "appliedenergistics2")
public static void registerAEIntegration() {
- appeng.api.AEApi.instance()
- .registries()
- .externalStorage()
+ appeng.api.AEApi.instance().registries().externalStorage()
.addExternalStorageInterface(new AE2DigitalChestHandler());
}
@Optional.Method(modid = "appliedenergistics2")
@Override
public void addListener(
- appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack>
- imeMonitorHandlerReceiver,
+ appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack> imeMonitorHandlerReceiver,
Object o) {
if (listeners == null) listeners = new HashMap<>();
listeners.put(imeMonitorHandlerReceiver, o);
@@ -110,8 +114,7 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
@Optional.Method(modid = "appliedenergistics2")
@Override
public void removeListener(
- appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack>
- imeMonitorHandlerReceiver) {
+ appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack> imeMonitorHandlerReceiver) {
if (listeners == null) listeners = new HashMap<>();
listeners.remove(imeMonitorHandlerReceiver);
}
@@ -203,15 +206,12 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
@Override
@Optional.Method(modid = "appliedenergistics2")
- public appeng.api.storage.data.IAEItemStack injectItems(
- final appeng.api.storage.data.IAEItemStack input,
- final appeng.api.config.Actionable mode,
- final appeng.api.networking.security.BaseActionSource src) {
+ public appeng.api.storage.data.IAEItemStack injectItems(final appeng.api.storage.data.IAEItemStack input,
+ final appeng.api.config.Actionable mode, final appeng.api.networking.security.BaseActionSource src) {
final ItemStack inputStack = input.getItemStack();
if (inputStack == null) return null;
if (getBaseMetaTileEntity() == null) return input;
- if (mode != appeng.api.config.Actionable.SIMULATE)
- getBaseMetaTileEntity().markDirty();
+ if (mode != appeng.api.config.Actionable.SIMULATE) getBaseMetaTileEntity().markDirty();
ItemStack storedStack = getItemStack();
if (storedStack != null) {
if (GT_Utility.areStacksEqual(storedStack, inputStack)) {
@@ -244,14 +244,11 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
@Override
@Optional.Method(modid = "appliedenergistics2")
- public appeng.api.storage.data.IAEItemStack extractItems(
- final appeng.api.storage.data.IAEItemStack request,
- final appeng.api.config.Actionable mode,
- final appeng.api.networking.security.BaseActionSource src) {
+ public appeng.api.storage.data.IAEItemStack extractItems(final appeng.api.storage.data.IAEItemStack request,
+ final appeng.api.config.Actionable mode, final appeng.api.networking.security.BaseActionSource src) {
if (request.isSameType(getItemStack())) {
if (getBaseMetaTileEntity() == null) return null;
- if (mode != appeng.api.config.Actionable.SIMULATE)
- getBaseMetaTileEntity().markDirty();
+ if (mode != appeng.api.config.Actionable.SIMULATE) getBaseMetaTileEntity().markDirty();
if (request.getStackSize() >= getItemCount()) {
appeng.util.item.AEItemStack result = appeng.util.item.AEItemStack.create(getItemStack());
result.setStackSize(getItemCount());
@@ -278,21 +275,19 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
GT_Utility.sendChatToPlayer(
aPlayer,
StatCollector.translateToLocal(
- mVoidOverflow
- ? "GT5U.machines.digitalchest.voidoverflow.enabled"
+ mVoidOverflow ? "GT5U.machines.digitalchest.voidoverflow.enabled"
: "GT5U.machines.digitalchest.voidoverflow.disabled"));
}
@Override
- public boolean onSolderingToolRightClick(
- byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
+ public boolean onSolderingToolRightClick(byte aSide, byte aWrenchingSide, EntityPlayer aPlayer, float aX, float aY,
+ float aZ) {
if (super.onSolderingToolRightClick(aSide, aWrenchingSide, aPlayer, aX, aY, aZ)) return true;
mDisableFilter = !mDisableFilter;
GT_Utility.sendChatToPlayer(
aPlayer,
StatCollector.translateToLocal(
- mDisableFilter
- ? "GT5U.machines.digitalchest.inputfilter.disabled"
+ mDisableFilter ? "GT5U.machines.digitalchest.inputfilter.disabled"
: "GT5U.machines.digitalchest.inputfilter.enabled"));
return true;
}
@@ -312,8 +307,7 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
ItemStack stack = getItemStack();
int savedCount = count;
- if ((mInventory[0] != null)
- && ((count < getMaxItemCount()) || mVoidOverflow)
+ if ((mInventory[0] != null) && ((count < getMaxItemCount()) || mVoidOverflow)
&& GT_Utility.areStacksEqual(mInventory[0], stack)) {
count += mInventory[0].stackSize;
if (count <= getMaxItemCount()) {
@@ -331,13 +325,12 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
mInventory[1] = stack.copy();
mInventory[1].stackSize = Math.min(stack.getMaxStackSize(), count);
count -= mInventory[1].stackSize;
- } else if ((count > 0)
- && GT_Utility.areStacksEqual(mInventory[1], stack)
+ } else if ((count > 0) && GT_Utility.areStacksEqual(mInventory[1], stack)
&& mInventory[1].getMaxStackSize() > mInventory[1].stackSize) {
- int tmp = Math.min(count, mInventory[1].getMaxStackSize() - mInventory[1].stackSize);
- mInventory[1].stackSize += tmp;
- count -= tmp;
- }
+ int tmp = Math.min(count, mInventory[1].getMaxStackSize() - mInventory[1].stackSize);
+ mInventory[1].stackSize += tmp;
+ count -= tmp;
+ }
setItemCount(count);
if (stack != null) {
mInventory[2] = stack.copy();
@@ -379,8 +372,7 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
@Override
public int getProgresstime() {
- return getItemCount()
- + (mInventory[0] == null ? 0 : mInventory[0].stackSize)
+ return getItemCount() + (mInventory[0] == null ? 0 : mInventory[0].stackSize)
+ (mInventory[1] == null ? 0 : mInventory[1].stackSize);
}
@@ -398,21 +390,23 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
public String[] getInfoData() {
if (getItemStack() == null) {
- return new String[] {
- EnumChatFormatting.BLUE + chestName() + EnumChatFormatting.RESET,
- "Stored Items:",
- EnumChatFormatting.GOLD + "No Items" + EnumChatFormatting.RESET,
- EnumChatFormatting.GREEN + "0" + EnumChatFormatting.RESET + " " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(getMaxItemCount()) + EnumChatFormatting.RESET
- };
+ return new String[] { EnumChatFormatting.BLUE + chestName() + EnumChatFormatting.RESET, "Stored Items:",
+ EnumChatFormatting.GOLD + "No Items" + EnumChatFormatting.RESET,
+ EnumChatFormatting.GREEN + "0"
+ + EnumChatFormatting.RESET
+ + " "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getMaxItemCount())
+ + EnumChatFormatting.RESET };
}
- return new String[] {
- EnumChatFormatting.BLUE + chestName() + EnumChatFormatting.RESET,
- "Stored Items:",
- EnumChatFormatting.GOLD + getItemStack().getDisplayName() + EnumChatFormatting.RESET,
- EnumChatFormatting.GREEN + GT_Utility.formatNumbers(getItemCount()) + EnumChatFormatting.RESET + " "
- + EnumChatFormatting.YELLOW + GT_Utility.formatNumbers(getMaxItemCount()) + EnumChatFormatting.RESET
- };
+ return new String[] { EnumChatFormatting.BLUE + chestName() + EnumChatFormatting.RESET, "Stored Items:",
+ EnumChatFormatting.GOLD + getItemStack().getDisplayName() + EnumChatFormatting.RESET,
+ EnumChatFormatting.GREEN + GT_Utility.formatNumbers(getItemCount())
+ + EnumChatFormatting.RESET
+ + " "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getMaxItemCount())
+ + EnumChatFormatting.RESET };
}
@Override
@@ -442,8 +436,8 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
@Optional.Method(modid = "appliedenergistics2")
private boolean hasActiveMEConnection() {
if (listeners == null || listeners.isEmpty()) return false;
- for (Map.Entry<appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack>, Object> e :
- listeners.entrySet()) {
+ for (Map.Entry<appeng.api.storage.IMEMonitorHandlerReceiver<appeng.api.storage.data.IAEItemStack>, Object> e : listeners
+ .entrySet()) {
if ((e.getKey() instanceof appeng.api.parts.IPart)) {
appeng.api.networking.IGridNode n = ((appeng.api.parts.IPart) e.getKey()).getGridNode();
if (n != null && n.isActive()) return true;
@@ -488,39 +482,30 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
- if (aSide != aFacing) return new ITexture[] {MACHINE_CASINGS[mTier][aColorIndex + 1]};
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(OVERLAY_SCHEST),
- TextureFactory.builder().addIcon(OVERLAY_SCHEST_GLOW).glow().build()
- };
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
+ if (aSide != aFacing) return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1] };
+ return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_SCHEST),
+ TextureFactory.builder().addIcon(OVERLAY_SCHEST_GLOW).glow().build() };
}
@Override
- public void getWailaBody(
- ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
+ public void getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor,
+ IWailaConfigHandler config) {
super.getWailaBody(itemStack, currenttip, accessor, config);
NBTTagCompound tag = accessor.getNBTData();
if (tag.hasKey("itemType", Constants.NBT.TAG_COMPOUND)) {
currenttip.add("Item Count: " + GT_Utility.parseNumberToString(tag.getInteger("itemCount")));
- currenttip.add("Item Type: "
- + ItemStack.loadItemStackFromNBT(tag.getCompoundTag("itemType"))
- .getDisplayName());
+ currenttip.add(
+ "Item Type: " + ItemStack.loadItemStackFromNBT(tag.getCompoundTag("itemType")).getDisplayName());
} else {
currenttip.add("Chest Empty");
}
}
@Override
- public void getWailaNBTData(
- EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y, int z) {
+ public void getWailaNBTData(EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y,
+ int z) {
super.getWailaNBTData(player, tile, tag, world, x, y, z);
ItemStack is = getItemStack();
if (GT_Utility.isStackInvalid(is)) return;
@@ -538,29 +523,27 @@ public abstract class GT_MetaTileEntity_DigitalChestBase extends GT_MetaTileEnti
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK)
- .setPos(7, 16)
- .setSize(71, 45))
- .widget(new SlotWidget(inventoryHandler, 0)
- .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_IN)
- .setPos(79, 16))
- .widget(new SlotWidget(inventoryHandler, 1)
- .setAccess(true, false)
- .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_OUT)
- .setPos(79, 52))
- .widget(SlotWidget.phantom(inventoryHandler, 2)
- .disableInteraction()
- .setBackground(GT_UITextures.TRANSPARENT)
- .setPos(59, 42))
- .widget(new TextWidget("Item Amount")
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(10, 20))
- .widget(TextWidget.dynamicString(() -> GT_Utility.parseNumberToString(
- this instanceof GT_MetaTileEntity_QuantumChest
- ? ((GT_MetaTileEntity_QuantumChest) this).mItemCount
- : 0))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(10, 30));
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK).setPos(7, 16).setSize(71, 45))
+ .widget(
+ new SlotWidget(inventoryHandler, 0)
+ .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_IN)
+ .setPos(79, 16))
+ .widget(
+ new SlotWidget(inventoryHandler, 1).setAccess(true, false)
+ .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_OUT)
+ .setPos(79, 52))
+ .widget(
+ SlotWidget.phantom(inventoryHandler, 2).disableInteraction()
+ .setBackground(GT_UITextures.TRANSPARENT).setPos(59, 42))
+ .widget(
+ new TextWidget("Item Amount").setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(10, 20))
+ .widget(
+ TextWidget.dynamicString(
+ () -> GT_Utility.parseNumberToString(
+ this instanceof GT_MetaTileEntity_QuantumChest
+ ? ((GT_MetaTileEntity_QuantumChest) this).mItemCount
+ : 0))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(10, 30));
}
}
diff --git a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalTankBase.java b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalTankBase.java
index 278e4b3d15..15171ae747 100644
--- a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalTankBase.java
+++ b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_DigitalTankBase.java
@@ -3,6 +3,25 @@ package gregtech.common.tileentities.storage;
import static gregtech.api.enums.Textures.BlockIcons.*;
import static gregtech.api.metatileentity.BaseTileEntity.TOOLTIP_DELAY;
+import java.util.List;
+
+import mcp.mobius.waila.api.IWailaConfigHandler;
+import mcp.mobius.waila.api.IWailaDataAccessor;
+
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.entity.player.EntityPlayerMP;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+import net.minecraft.tileentity.TileEntity;
+import net.minecraft.util.StatCollector;
+import net.minecraft.world.World;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.Fluid;
+import net.minecraftforge.fluids.FluidRegistry;
+import net.minecraftforge.fluids.FluidStack;
+import net.minecraftforge.fluids.FluidTankInfo;
+import net.minecraftforge.fluids.IFluidHandler;
+
import com.gtnewhorizons.modularui.api.screen.ModularWindow;
import com.gtnewhorizons.modularui.api.screen.UIBuildContext;
import com.gtnewhorizons.modularui.common.internal.network.NetworkUtils;
@@ -10,6 +29,7 @@ import com.gtnewhorizons.modularui.common.widget.CycleButtonWidget;
import com.gtnewhorizons.modularui.common.widget.DrawableWidget;
import com.gtnewhorizons.modularui.common.widget.SlotWidget;
import com.gtnewhorizons.modularui.common.widget.TextWidget;
+
import gregtech.api.gui.modularui.GT_UIInfos;
import gregtech.api.gui.modularui.GT_UITextures;
import gregtech.api.interfaces.IFluidAccess;
@@ -21,35 +41,26 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_BasicTank;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
import gregtech.common.gui.modularui.widget.FluidDisplaySlotWidget;
-import java.util.List;
-import mcp.mobius.waila.api.IWailaConfigHandler;
-import mcp.mobius.waila.api.IWailaDataAccessor;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.entity.player.EntityPlayerMP;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.StatCollector;
-import net.minecraft.world.World;
-import net.minecraftforge.common.util.ForgeDirection;
-import net.minecraftforge.fluids.Fluid;
-import net.minecraftforge.fluids.FluidRegistry;
-import net.minecraftforge.fluids.FluidStack;
-import net.minecraftforge.fluids.FluidTankInfo;
-import net.minecraftforge.fluids.IFluidHandler;
public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntity_BasicTank
implements IFluidLockable, IAddUIWidgets {
+
public boolean mOutputFluid = false, mVoidFluidPart = false, mVoidFluidFull = false, mLockFluid = false;
protected String lockedFluidName = null;
public boolean mAllowInputFromOutputSide = false;
public GT_MetaTileEntity_DigitalTankBase(int aID, String aName, String aNameRegional, int aTier) {
- super(aID, aName, aNameRegional, aTier, 3, new String[] {
- StatCollector.translateToLocalFormatted(
- "GT5U.machines.digitaltank.tooltip", GT_Utility.formatNumbers(commonSizeCompute(aTier))),
- StatCollector.translateToLocal("GT5U.machines.digitaltank.tooltip1"),
- });
+ super(
+ aID,
+ aName,
+ aNameRegional,
+ aTier,
+ 3,
+ new String[] {
+ StatCollector.translateToLocalFormatted(
+ "GT5U.machines.digitaltank.tooltip",
+ GT_Utility.formatNumbers(commonSizeCompute(aTier))),
+ StatCollector.translateToLocal("GT5U.machines.digitaltank.tooltip1"), });
}
protected static int commonSizeCompute(int tier) {
@@ -133,9 +144,7 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
@Override
public boolean isFluidInputAllowed(FluidStack aFluid) {
- return !mLockFluid
- || lockedFluidName == null
- || lockedFluidName.equals(aFluid.getFluid().getName());
+ return !mLockFluid || lockedFluidName == null || lockedFluidName.equals(aFluid.getFluid().getName());
}
@Override
@@ -222,23 +231,15 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide != ForgeDirection.UP.ordinal()) {
if (aSide == aBaseMetaTileEntity.getFrontFacing()) {
- return new ITexture[] {MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPE)};
- } else return new ITexture[] {MACHINE_CASINGS[mTier][aColorIndex + 1]};
+ return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_PIPE) };
+ } else return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1] };
}
- return new ITexture[] {
- MACHINE_CASINGS[mTier][aColorIndex + 1],
- TextureFactory.of(OVERLAY_QTANK),
- TextureFactory.builder().addIcon(OVERLAY_QTANK_GLOW).glow().build()
- };
+ return new ITexture[] { MACHINE_CASINGS[mTier][aColorIndex + 1], TextureFactory.of(OVERLAY_QTANK),
+ TextureFactory.builder().addIcon(OVERLAY_QTANK_GLOW).glow().build() };
}
@Override
@@ -252,7 +253,8 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
if (aSide == getBaseMetaTileEntity().getFrontFacing()) {
mAllowInputFromOutputSide = !mAllowInputFromOutputSide;
GT_Utility.sendChatToPlayer(
- aPlayer, mAllowInputFromOutputSide ? GT_Utility.getTrans("095") : GT_Utility.getTrans("096"));
+ aPlayer,
+ mAllowInputFromOutputSide ? GT_Utility.getTrans("095") : GT_Utility.getTrans("096"));
}
}
@@ -314,8 +316,8 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
getOutputSlot(),
GT_Utility.getContainerForFilledItem(mInventory[getInputSlot()], true),
1)) {
- getFillableStack().amount +=
- Math.min(tFluid.amount, getRealCapacity() - getFillableStack().amount);
+ getFillableStack().amount += Math
+ .min(tFluid.amount, getRealCapacity() - getFillableStack().amount);
aBaseMetaTileEntity.decrStackSize(getInputSlot(), 1);
}
}
@@ -325,8 +327,8 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
}
if (doesFillContainers()) {
- ItemStack tOutput =
- GT_Utility.fillFluidContainer(getDrainableStack(), mInventory[getInputSlot()], false, true);
+ ItemStack tOutput = GT_Utility
+ .fillFluidContainer(getDrainableStack(), mInventory[getInputSlot()], false, true);
if (tOutput != null && aBaseMetaTileEntity.addStackToSlot(getOutputSlot(), tOutput, 1)) {
FluidStack tFluid = GT_Utility.getFluidForFilledItem(tOutput, true);
aBaseMetaTileEntity.decrStackSize(getInputSlot(), 1);
@@ -339,11 +341,11 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
@Override
public int fill(FluidStack aFluid, boolean doFill) {
- if (aFluid == null
- || aFluid.getFluid().getID() <= 0
+ if (aFluid == null || aFluid.getFluid().getID() <= 0
|| aFluid.amount <= 0
|| !canTankBeFilled()
- || !isFluidInputAllowed(aFluid)) return 0;
+ || !isFluidInputAllowed(aFluid))
+ return 0;
if (getFillableStack() != null && !getFillableStack().isFluidEqual(aFluid)) {
return 0;
}
@@ -373,12 +375,13 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
FluidStack tDrained = drain(commonSizeCompute(mTier) / 100, false);
if (tDrained != null) {
int tFilledAmount = tTank.fill(
- ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()), tDrained, false);
- if (tFilledAmount > 0)
- tTank.fill(
- ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()),
- drain(tFilledAmount, true),
- true);
+ ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()),
+ tDrained,
+ false);
+ if (tFilledAmount > 0) tTank.fill(
+ ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()),
+ drain(tFilledAmount, true),
+ true);
}
}
}
@@ -441,28 +444,28 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
@Override
public FluidTankInfo[] getTankInfo(ForgeDirection aSide) {
- return new FluidTankInfo[] {getInfo()};
+ return new FluidTankInfo[] { getInfo() };
}
@Override
- public void getWailaBody(
- ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor, IWailaConfigHandler config) {
+ public void getWailaBody(ItemStack itemStack, List<String> currenttip, IWailaDataAccessor accessor,
+ IWailaConfigHandler config) {
super.getWailaBody(itemStack, currenttip, accessor, config);
NBTTagCompound tag = accessor.getNBTData();
FluidStack fluid = tag.hasKey("mFluid") ? FluidStack.loadFluidStackFromNBT(tag.getCompoundTag("mFluid")) : null;
if (fluid != null && fluid.amount > 0) {
currenttip.remove(0);
- currenttip.add(
- 0, String.format("%d / %d mB %s", fluid.amount, getRealCapacity(), fluid.getLocalizedName()));
+ currenttip
+ .add(0, String.format("%d / %d mB %s", fluid.amount, getRealCapacity(), fluid.getLocalizedName()));
} else {
currenttip.add(0, "Tank Empty");
}
}
@Override
- public void getWailaNBTData(
- EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y, int z) {
+ public void getWailaNBTData(EntityPlayerMP player, TileEntity tile, NBTTagCompound tag, World world, int x, int y,
+ int z) {
super.getWailaNBTData(player, tile, tag, world, x, y, z);
FluidStack fluid = getFluid();
if (fluid != null) tag.setTag("mFluid", fluid.writeToNBT(new NBTTagCompound()));
@@ -476,141 +479,117 @@ public abstract class GT_MetaTileEntity_DigitalTankBase extends GT_MetaTileEntit
@Override
public void addUIWidgets(ModularWindow.Builder builder, UIBuildContext buildContext) {
- builder.widget(new DrawableWidget()
- .setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK)
- .setPos(7, 16)
- .setSize(71, 45))
- .widget(new SlotWidget(inventoryHandler, getInputSlot())
- .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_IN)
- .setPos(79, 16))
- .widget(new SlotWidget(inventoryHandler, getOutputSlot())
- .setAccess(true, false)
- .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_OUT)
- .setPos(79, 43))
- .widget(new FluidDisplaySlotWidget(inventoryHandler, getStackDisplaySlot())
- .setFluidAccessConstructor(() -> constructFluidAccess(false))
- .setIHasFluidDisplay(this)
- .setCanDrain(true)
- .setCanFill(!isDrainableStackSeparate())
- .setActionRealClick(FluidDisplaySlotWidget.Action.TRANSFER)
- .setActionDragAndDrop(FluidDisplaySlotWidget.Action.LOCK)
- .setBeforeRealClick((clickData, widget) -> {
- if (NetworkUtils.isClient()) {
- // propagate display item content to actual fluid stored in this tank
- setDrainableStack(GT_Utility.getFluidFromDisplayStack(
- widget.getMcSlot().getStack()));
- }
- return true;
- })
- .setBackground(GT_UITextures.TRANSPARENT)
- .setPos(58, 41))
- .widget(new TextWidget("Liquid Amount")
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(10, 20))
- .widget(TextWidget.dynamicString(
- () -> GT_Utility.parseNumberToString(mFluid != null ? mFluid.amount : 0))
- .setDefaultColor(COLOR_TEXT_WHITE.get())
- .setPos(10, 30))
- .widget(new CycleButtonWidget()
- .setToggle(() -> mOutputFluid, val -> {
- mOutputFluid = val;
- if (!mOutputFluid) {
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(),
- GT_Utility.trans("262", "Fluid Auto Output Disabled"));
- } else {
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(), GT_Utility.trans("263", "Fluid Auto Output Enabled"));
- }
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ builder.widget(
+ new DrawableWidget().setDrawable(GT_UITextures.PICTURE_SCREEN_BLACK).setPos(7, 16).setSize(71, 45))
+ .widget(
+ new SlotWidget(inventoryHandler, getInputSlot())
+ .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_IN)
+ .setPos(79, 16))
+ .widget(
+ new SlotWidget(inventoryHandler, getOutputSlot()).setAccess(true, false)
+ .setBackground(getGUITextureSet().getItemSlot(), GT_UITextures.OVERLAY_SLOT_OUT)
+ .setPos(79, 43))
+ .widget(
+ new FluidDisplaySlotWidget(inventoryHandler, getStackDisplaySlot())
+ .setFluidAccessConstructor(() -> constructFluidAccess(false)).setIHasFluidDisplay(this)
+ .setCanDrain(true).setCanFill(!isDrainableStackSeparate())
+ .setActionRealClick(FluidDisplaySlotWidget.Action.TRANSFER)
+ .setActionDragAndDrop(FluidDisplaySlotWidget.Action.LOCK)
+ .setBeforeRealClick((clickData, widget) -> {
+ if (NetworkUtils.isClient()) {
+ // propagate display item content to actual fluid stored in this tank
+ setDrainableStack(
+ GT_Utility.getFluidFromDisplayStack(widget.getMcSlot().getStack()));
+ }
+ return true;
+ }).setBackground(GT_UITextures.TRANSPARENT).setPos(58, 41))
+ .widget(new TextWidget("Liquid Amount").setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(10, 20))
+ .widget(
+ TextWidget
+ .dynamicString(() -> GT_Utility.parseNumberToString(mFluid != null ? mFluid.amount : 0))
+ .setDefaultColor(COLOR_TEXT_WHITE.get()).setPos(10, 30))
+ .widget(new CycleButtonWidget().setToggle(() -> mOutputFluid, val -> {
+ mOutputFluid = val;
+ if (!mOutputFluid) {
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("262", "Fluid Auto Output Disabled"));
+ } else {
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("263", "Fluid Auto Output Enabled"));
+ }
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_AUTOOUTPUT_FLUID)
.setGTTooltip(() -> mTooltipCache.getData("GT5U.machines.digitaltank.autooutput.tooltip"))
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setPos(7, 63)
- .setSize(18, 18))
- .widget(new CycleButtonWidget()
- .setToggle(() -> mLockFluid, val -> {
- mLockFluid = val;
-
- String inBrackets;
- if (mLockFluid) {
- if (mFluid == null) {
- setLockedFluidName(null);
- inBrackets = GT_Utility.trans(
- "264", "currently none, will be locked to the next that is put in");
- } else {
- setLockedFluidName(
- getDrainableStack().getFluid().getName());
- inBrackets = getDrainableStack().getLocalizedName();
- }
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(),
- String.format(
- "%s (%s)", GT_Utility.trans("265", "1 specific Fluid"), inBrackets));
- } else {
- setLockedFluidName(null);
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(), GT_Utility.trans("266", "Lock Fluid Mode Disabled"));
- }
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setPos(7, 63).setSize(18, 18))
+ .widget(new CycleButtonWidget().setToggle(() -> mLockFluid, val -> {
+ mLockFluid = val;
+
+ String inBrackets;
+ if (mLockFluid) {
+ if (mFluid == null) {
+ setLockedFluidName(null);
+ inBrackets = GT_Utility
+ .trans("264", "currently none, will be locked to the next that is put in");
+ } else {
+ setLockedFluidName(getDrainableStack().getFluid().getName());
+ inBrackets = getDrainableStack().getLocalizedName();
+ }
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ String.format("%s (%s)", GT_Utility.trans("265", "1 specific Fluid"), inBrackets));
+ } else {
+ setLockedFluidName(null);
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("266", "Lock Fluid Mode Disabled"));
+ }
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_LOCK)
.setGTTooltip(() -> mTooltipCache.getData("GT5U.machines.digitaltank.lockfluid.tooltip"))
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setPos(25, 63)
- .setSize(18, 18))
- .widget(new CycleButtonWidget()
- .setToggle(() -> mAllowInputFromOutputSide, val -> {
- mAllowInputFromOutputSide = val;
- if (!mAllowInputFromOutputSide) {
- GT_Utility.sendChatToPlayer(buildContext.getPlayer(), GT_Utility.getTrans("096"));
- } else {
- GT_Utility.sendChatToPlayer(buildContext.getPlayer(), GT_Utility.getTrans("095"));
- }
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setPos(25, 63).setSize(18, 18))
+ .widget(new CycleButtonWidget().setToggle(() -> mAllowInputFromOutputSide, val -> {
+ mAllowInputFromOutputSide = val;
+ if (!mAllowInputFromOutputSide) {
+ GT_Utility.sendChatToPlayer(buildContext.getPlayer(), GT_Utility.getTrans("096"));
+ } else {
+ GT_Utility.sendChatToPlayer(buildContext.getPlayer(), GT_Utility.getTrans("095"));
+ }
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_INPUT_FROM_OUTPUT_SIDE)
.setGTTooltip(() -> mTooltipCache.getData("GT5U.machines.digitaltank.inputfromoutput.tooltip"))
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setPos(43, 63)
- .setSize(18, 18))
- .widget(new CycleButtonWidget()
- .setToggle(() -> mVoidFluidPart, val -> {
- mVoidFluidPart = val;
- if (!mVoidFluidPart) {
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(),
- GT_Utility.trans("267", "Overflow Voiding Mode Disabled"));
- } else {
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(),
- GT_Utility.trans("268", "Overflow Voiding Mode Enabled"));
- }
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setPos(43, 63).setSize(18, 18))
+ .widget(new CycleButtonWidget().setToggle(() -> mVoidFluidPart, val -> {
+ mVoidFluidPart = val;
+ if (!mVoidFluidPart) {
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("267", "Overflow Voiding Mode Disabled"));
+ } else {
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("268", "Overflow Voiding Mode Enabled"));
+ }
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_VOID_EXCESS)
.setGTTooltip(() -> mTooltipCache.getData("GT5U.machines.digitaltank.voidoverflow.tooltip"))
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setPos(151, 7)
- .setSize(18, 18))
- .widget(new CycleButtonWidget()
- .setToggle(() -> mVoidFluidFull, val -> {
- mVoidFluidFull = val;
- if (!mVoidFluidFull) {
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(), GT_Utility.trans("269", "Void Full Mode Disabled"));
- } else {
- GT_Utility.sendChatToPlayer(
- buildContext.getPlayer(), GT_Utility.trans("270", "Void Full Mode Enabled"));
- }
- })
- .setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setPos(151, 7).setSize(18, 18))
+ .widget(new CycleButtonWidget().setToggle(() -> mVoidFluidFull, val -> {
+ mVoidFluidFull = val;
+ if (!mVoidFluidFull) {
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("269", "Void Full Mode Disabled"));
+ } else {
+ GT_Utility.sendChatToPlayer(
+ buildContext.getPlayer(),
+ GT_Utility.trans("270", "Void Full Mode Enabled"));
+ }
+ }).setVariableBackground(GT_UITextures.BUTTON_STANDARD_TOGGLE)
.setStaticTexture(GT_UITextures.OVERLAY_BUTTON_VOID_ALL)
.setGTTooltip(() -> mTooltipCache.getData("GT5U.machines.digitaltank.voidfull.tooltip"))
- .setTooltipShowUpDelay(TOOLTIP_DELAY)
- .setPos(151, 25)
- .setSize(18, 18));
+ .setTooltipShowUpDelay(TOOLTIP_DELAY).setPos(151, 25).setSize(18, 18));
}
@Override
diff --git a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_Locker.java b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_Locker.java
index b4d5345391..3d81076bc9 100644
--- a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_Locker.java
+++ b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_Locker.java
@@ -5,6 +5,10 @@ import static gregtech.api.enums.Textures.BlockIcons.MACHINE_CASINGS;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAYS_ENERGY_IN;
import static gregtech.api.enums.Textures.BlockIcons.OVERLAY_LOCKER;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraft.nbt.NBTTagCompound;
+
import gregtech.api.enums.SoundResource;
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
@@ -13,11 +17,9 @@ import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_TieredMachi
import gregtech.api.objects.GT_ItemStack;
import gregtech.api.render.TextureFactory;
import gregtech.api.util.GT_Utility;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
-import net.minecraft.nbt.NBTTagCompound;
public class GT_MetaTileEntity_Locker extends GT_MetaTileEntity_TieredMachineBlock {
+
public byte mType = 0;
public GT_MetaTileEntity_Locker(int aID, String aName, String aNameRegional, int aTier) {
@@ -44,30 +46,22 @@ public class GT_MetaTileEntity_Locker extends GT_MetaTileEntity_TieredMachineBlo
public ITexture[][][] getTextureSet(ITexture[] aTextures) {
ITexture[][][] rTextures = new ITexture[3][17][];
for (byte i = -1; i < 16; i = (byte) (i + 1)) {
- ITexture[] tmp0 = {MACHINE_CASINGS[this.mTier][(i + 1)]};
+ ITexture[] tmp0 = { MACHINE_CASINGS[this.mTier][(i + 1)] };
rTextures[0][(i + 1)] = tmp0;
- ITexture[] tmp1 = {MACHINE_CASINGS[this.mTier][(i + 1)], OVERLAYS_ENERGY_IN[this.mTier]};
+ ITexture[] tmp1 = { MACHINE_CASINGS[this.mTier][(i + 1)], OVERLAYS_ENERGY_IN[this.mTier] };
rTextures[1][(i + 1)] = tmp1;
- ITexture[] tmp2 = {MACHINE_CASINGS[this.mTier][(i + 1)], TextureFactory.of(OVERLAY_LOCKER)};
+ ITexture[] tmp2 = { MACHINE_CASINGS[this.mTier][(i + 1)], TextureFactory.of(OVERLAY_LOCKER) };
rTextures[2][(i + 1)] = tmp2;
}
return rTextures;
}
@Override
- public ITexture[] getTexture(
- IGregTechTileEntity aBaseMetaTileEntity,
- byte aSide,
- byte aFacing,
- byte aColorIndex,
- boolean aActive,
- boolean aRedstone) {
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
+ boolean aActive, boolean aRedstone) {
if (aSide == aFacing) {
- return new ITexture[] {
- this.mTextures[2][(aColorIndex + 1)][0],
- this.mTextures[2][(aColorIndex + 1)][1],
- LOCKERS[Math.abs(this.mType % LOCKERS.length)]
- };
+ return new ITexture[] { this.mTextures[2][(aColorIndex + 1)][0], this.mTextures[2][(aColorIndex + 1)][1],
+ LOCKERS[Math.abs(this.mType % LOCKERS.length)] };
}
return this.mTextures[0][(aColorIndex + 1)];
}
@@ -182,8 +176,8 @@ public class GT_MetaTileEntity_Locker extends GT_MetaTileEntity_TieredMachineBlo
}
@Override
- public boolean onRightclick(
- IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer, byte aSide, float aX, float aY, float aZ) {
+ public boolean onRightclick(IGregTechTileEntity aBaseMetaTileEntity, EntityPlayer aPlayer, byte aSide, float aX,
+ float aY, float aZ) {
if ((aBaseMetaTileEntity.isServerSide()) && (aSide == aBaseMetaTileEntity.getFrontFacing())) {
for (int i = 0; i < 4; i++) {
ItemStack tSwapStack = this.mInventory[i];
diff --git a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumChest.java b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumChest.java
index 18d54215a1..7b00a9746c 100644
--- a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumChest.java
+++ b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumChest.java
@@ -1,14 +1,16 @@
package gregtech.common.tileentities.storage;
-import gregtech.api.interfaces.ITexture;
-import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
-import gregtech.api.metatileentity.MetaTileEntity;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.nbt.NBTTagList;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.metatileentity.MetaTileEntity;
+
public class GT_MetaTileEntity_QuantumChest extends GT_MetaTileEntity_DigitalChestBase {
+
public int mItemCount = 0;
public ItemStack mItemStack = null;
NBTTagList mInvData = null;
diff --git a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumTank.java b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumTank.java
index 886dd676e7..d6a936c745 100644
--- a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumTank.java
+++ b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_QuantumTank.java
@@ -1,12 +1,14 @@
package gregtech.common.tileentities.storage;
+import net.minecraft.util.EnumChatFormatting;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.util.GT_Utility;
-import net.minecraft.util.EnumChatFormatting;
public class GT_MetaTileEntity_QuantumTank extends GT_MetaTileEntity_DigitalTankBase {
+
public GT_MetaTileEntity_QuantumTank(int aID, String aName, String aNameRegional, int aTier) {
super(aID, aName, aNameRegional, aTier);
}
@@ -28,22 +30,26 @@ public class GT_MetaTileEntity_QuantumTank extends GT_MetaTileEntity_DigitalTank
public String[] getInfoData() {
if (mFluid == null) {
- return new String[] {
- EnumChatFormatting.BLUE + "Quantum Tank" + EnumChatFormatting.RESET,
- "Stored Fluid:",
- EnumChatFormatting.GOLD + "No Fluid" + EnumChatFormatting.RESET,
- EnumChatFormatting.GREEN + Integer.toString(0) + " L" + EnumChatFormatting.RESET + " "
- + EnumChatFormatting.YELLOW + GT_Utility.formatNumbers(getCapacity()) + " L"
- + EnumChatFormatting.RESET
- };
+ return new String[] { EnumChatFormatting.BLUE + "Quantum Tank" + EnumChatFormatting.RESET, "Stored Fluid:",
+ EnumChatFormatting.GOLD + "No Fluid" + EnumChatFormatting.RESET,
+ EnumChatFormatting.GREEN + Integer.toString(0)
+ + " L"
+ + EnumChatFormatting.RESET
+ + " "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getCapacity())
+ + " L"
+ + EnumChatFormatting.RESET };
}
- return new String[] {
- EnumChatFormatting.BLUE + "Quantum Tank" + EnumChatFormatting.RESET,
- "Stored Fluid:",
- EnumChatFormatting.GOLD + mFluid.getLocalizedName() + EnumChatFormatting.RESET,
- EnumChatFormatting.GREEN + GT_Utility.formatNumbers(mFluid.amount) + " L" + EnumChatFormatting.RESET + " "
- + EnumChatFormatting.YELLOW + GT_Utility.formatNumbers(getCapacity()) + " L"
- + EnumChatFormatting.RESET
- };
+ return new String[] { EnumChatFormatting.BLUE + "Quantum Tank" + EnumChatFormatting.RESET, "Stored Fluid:",
+ EnumChatFormatting.GOLD + mFluid.getLocalizedName() + EnumChatFormatting.RESET,
+ EnumChatFormatting.GREEN + GT_Utility.formatNumbers(mFluid.amount)
+ + " L"
+ + EnumChatFormatting.RESET
+ + " "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getCapacity())
+ + " L"
+ + EnumChatFormatting.RESET };
}
}
diff --git a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_SuperTank.java b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_SuperTank.java
index 3b7fb8e849..5dac66e49a 100644
--- a/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_SuperTank.java
+++ b/src/main/java/gregtech/common/tileentities/storage/GT_MetaTileEntity_SuperTank.java
@@ -1,12 +1,14 @@
package gregtech.common.tileentities.storage;
+import net.minecraft.util.EnumChatFormatting;
+
import gregtech.api.interfaces.ITexture;
import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.MetaTileEntity;
import gregtech.api.util.GT_Utility;
-import net.minecraft.util.EnumChatFormatting;
public class GT_MetaTileEntity_SuperTank extends GT_MetaTileEntity_DigitalTankBase {
+
public GT_MetaTileEntity_SuperTank(int aID, String aName, String aNameRegional, int aTier) {
super(aID, aName, aNameRegional, aTier);
}
@@ -28,21 +30,25 @@ public class GT_MetaTileEntity_SuperTank extends GT_MetaTileEntity_DigitalTankBa
public String[] getInfoData() {
if (mFluid == null) {
- return new String[] {
- EnumChatFormatting.BLUE + "Super Tank" + EnumChatFormatting.RESET,
- "Stored Fluid:",
- EnumChatFormatting.GOLD + "No Fluid" + EnumChatFormatting.RESET,
- EnumChatFormatting.GREEN + "0 L" + EnumChatFormatting.RESET + " " + EnumChatFormatting.YELLOW
- + GT_Utility.formatNumbers(getCapacity()) + " L" + EnumChatFormatting.RESET
- };
+ return new String[] { EnumChatFormatting.BLUE + "Super Tank" + EnumChatFormatting.RESET, "Stored Fluid:",
+ EnumChatFormatting.GOLD + "No Fluid" + EnumChatFormatting.RESET,
+ EnumChatFormatting.GREEN + "0 L"
+ + EnumChatFormatting.RESET
+ + " "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getCapacity())
+ + " L"
+ + EnumChatFormatting.RESET };
}
- return new String[] {
- EnumChatFormatting.BLUE + "Super Tank" + EnumChatFormatting.RESET,
- "Stored Fluid:",
- EnumChatFormatting.GOLD + mFluid.getLocalizedName() + EnumChatFormatting.RESET,
- EnumChatFormatting.GREEN + GT_Utility.formatNumbers(mFluid.amount) + " L" + EnumChatFormatting.RESET + " "
- + EnumChatFormatting.YELLOW + GT_Utility.formatNumbers(getCapacity()) + " L"
- + EnumChatFormatting.RESET
- };
+ return new String[] { EnumChatFormatting.BLUE + "Super Tank" + EnumChatFormatting.RESET, "Stored Fluid:",
+ EnumChatFormatting.GOLD + mFluid.getLocalizedName() + EnumChatFormatting.RESET,
+ EnumChatFormatting.GREEN + GT_Utility.formatNumbers(mFluid.amount)
+ + " L"
+ + EnumChatFormatting.RESET
+ + " "
+ + EnumChatFormatting.YELLOW
+ + GT_Utility.formatNumbers(getCapacity())
+ + " L"
+ + EnumChatFormatting.RESET };
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool.java b/src/main/java/gregtech/common/tools/GT_Tool.java
index bd17809e59..15bbaf976d 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool.java
@@ -1,10 +1,7 @@
package gregtech.common.tools;
-import gregtech.api.damagesources.GT_DamageSources;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.interfaces.IToolStats;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.enchantment.Enchantment;
import net.minecraft.entity.Entity;
@@ -18,9 +15,15 @@ import net.minecraft.util.IChatComponent;
import net.minecraft.world.World;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.api.damagesources.GT_DamageSources;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.interfaces.IToolStats;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public abstract class GT_Tool implements IToolStats {
- public static final Enchantment[] FORTUNE_ENCHANTMENT = {Enchantment.fortune};
- public static final Enchantment[] LOOTING_ENCHANTMENT = {Enchantment.looting};
+
+ public static final Enchantment[] FORTUNE_ENCHANTMENT = { Enchantment.fortune };
+ public static final Enchantment[] LOOTING_ENCHANTMENT = { Enchantment.looting };
public static final Enchantment[] ZERO_ENCHANTMENTS = new Enchantment[0];
public static final int[] ZERO_ENCHANTMENT_LEVELS = new int[0];
@@ -138,18 +141,8 @@ public abstract class GT_Tool implements IToolStats {
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
return 0;
}
@@ -179,27 +172,20 @@ public abstract class GT_Tool implements IToolStats {
public void onStatsAddedToTool(GT_MetaGenerated_Tool aItem, int aID) {}
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
return aOriginalDamage;
}
@Override
- public float getMagicDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getMagicDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
return aOriginalDamage;
}
@Override
- public float getMiningSpeed(
- Block aBlock,
- byte aMetaData,
- float aDefault,
- EntityPlayer aPlayer,
- World worldObj,
- int aX,
- int aY,
- int aZ) {
+ public float getMiningSpeed(Block aBlock, byte aMetaData, float aDefault, EntityPlayer aPlayer, World worldObj,
+ int aX, int aY, int aZ) {
return aDefault;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Axe.java b/src/main/java/gregtech/common/tools/GT_Tool_Axe.java
index 5155d061fe..94c4681aa3 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Axe.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Axe.java
@@ -1,11 +1,7 @@
package gregtech.common.tools;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -17,7 +13,14 @@ import net.minecraft.util.IChatComponent;
import net.minecraft.world.World;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Axe extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -95,21 +98,10 @@ public class GT_Tool_Axe extends GT_Tool {
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
int rAmount = 0;
- if ((GregTech_API.sTimber)
- && (!aPlayer.isSneaking())
+ if ((GregTech_API.sTimber) && (!aPlayer.isSneaking())
&& (OrePrefixes.log.contains(new ItemStack(aBlock, 1, aMetaData)))) {
int tY = aY + 1;
for (int tH = aPlayer.worldObj.getHeight(); tY < tH; tY++) {
@@ -124,29 +116,25 @@ public class GT_Tool_Axe extends GT_Tool {
}
@Override
- public float getMiningSpeed(
- Block aBlock, byte aMetaData, float aDefault, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ) {
+ public float getMiningSpeed(Block aBlock, byte aMetaData, float aDefault, EntityPlayer aPlayer, World aWorld,
+ int aX, int aY, int aZ) {
if (aBlock.isWood(aPlayer.worldObj, aX, aY, aZ)
&& OrePrefixes.log.contains(new ItemStack(aBlock, 1, aMetaData))) {
float rAmount = 1.0F;
float tIncrement = 1.0F;
if ((GregTech_API.sTimber) && !aPlayer.isSneaking()) {
int tY = aY + 1;
- for (int tH = aPlayer.worldObj.getHeight();
- (tY < tH) && (aPlayer.worldObj.getBlock(aX, tY, aZ) == aBlock);
- tY++) {
+ for (int tH = aPlayer.worldObj.getHeight(); (tY < tH)
+ && (aPlayer.worldObj.getBlock(aX, tY, aZ) == aBlock); tY++) {
tIncrement += 0.1F;
rAmount += tIncrement;
}
}
return 2.0F * aDefault / rAmount;
}
- return (aBlock.getMaterial() == Material.leaves)
- || (aBlock.getMaterial() == Material.vine)
- || (aBlock.getMaterial() == Material.plants)
- || (aBlock.getMaterial() == Material.gourd)
- ? aDefault / 4.0F
- : aDefault;
+ return (aBlock.getMaterial() == Material.leaves) || (aBlock.getMaterial() == Material.vine)
+ || (aBlock.getMaterial() == Material.plants)
+ || (aBlock.getMaterial() == Material.gourd) ? aDefault / 4.0F : aDefault;
}
@Override
@@ -157,18 +145,15 @@ public class GT_Tool_Axe extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[OrePrefixes.toolHeadAxe.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool
+ .getPrimaryMaterial(aStack).mIconSet.mTextures[OrePrefixes.toolHeadAxe.mTextureIndex]
+ : GT_MetaGenerated_Tool
+ .getSecondaryMaterial(aStack).mIconSet.mTextures[OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -177,8 +162,12 @@ public class GT_Tool_Axe extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " has been chopped by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has been chopped by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_BranchCutter.java b/src/main/java/gregtech/common/tools/GT_Tool_BranchCutter.java
index 228d06d2a7..a4ea2f701d 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_BranchCutter.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_BranchCutter.java
@@ -1,12 +1,7 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ModHandler;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -19,7 +14,15 @@ import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ModHandler;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.api.util.GT_Utility;
+
public class GT_Tool_BranchCutter extends GT_Tool {
+
@Override
public float getBaseDamage() {
return 2.5F;
@@ -41,21 +44,11 @@ public class GT_Tool_BranchCutter extends GT_Tool {
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
if (aBlock.getMaterial() == Material.leaves) {
- aEvent.dropChance = Math.min(
- 1.0F, Math.max(aEvent.dropChance, (aStack.getItem().getHarvestLevel(aStack, "") + 1) * 0.2F));
+ aEvent.dropChance = Math
+ .min(1.0F, Math.max(aEvent.dropChance, (aStack.getItem().getHarvestLevel(aStack, "") + 1) * 0.2F));
if (aBlock == Blocks.leaves) {
aDrops.clear();
if (((aMetaData & 0x3) == 0) && (aPlayer.worldObj.rand.nextInt(9) <= aFortune * 2)) {
@@ -87,15 +80,18 @@ public class GT_Tool_BranchCutter extends GT_Tool {
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " has been trimmed by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has been trimmed by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_ButcheryKnife.java b/src/main/java/gregtech/common/tools/GT_Tool_ButcheryKnife.java
index ab10e40bae..a99dac9e57 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_ButcheryKnife.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_ButcheryKnife.java
@@ -1,8 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import net.minecraft.block.Block;
import net.minecraft.enchantment.Enchantment;
import net.minecraft.entity.Entity;
@@ -12,7 +9,12 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public class GT_Tool_ButcheryKnife extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 200;
@@ -70,7 +72,7 @@ public class GT_Tool_ButcheryKnife extends GT_Tool {
@Override
public int[] getEnchantmentLevels(ItemStack aStack) {
- return new int[] {(2 + GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mToolQuality) / 2};
+ return new int[] { (2 + GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mToolQuality) / 2 };
}
@Override
@@ -80,16 +82,19 @@ public class GT_Tool_ButcheryKnife extends GT_Tool {
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE + " has butchered "
- + EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has butchered "
+ + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
@Override
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_BuzzSaw.java b/src/main/java/gregtech/common/tools/GT_Tool_BuzzSaw.java
index db57a82cb8..b12b8d37ea 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_BuzzSaw.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_BuzzSaw.java
@@ -1,9 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -11,7 +7,13 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public class GT_Tool_BuzzSaw extends GT_Tool_Saw {
+
@Override
public int getToolDamagePerContainerCraft() {
return 100;
@@ -55,23 +57,25 @@ public class GT_Tool_BuzzSaw extends GT_Tool_Saw {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadBuzzSaw.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadBuzzSaw.mTextureIndex]
: Textures.ItemIcons.HANDLE_BUZZSAW;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " got buzzed by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got buzzed by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_HV.java b/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_HV.java
index a031fbc9da..1895eff282 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_HV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_HV.java
@@ -1,10 +1,12 @@
package gregtech.common.tools;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Chainsaw_HV extends GT_Tool_Chainsaw_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return 800;
@@ -48,9 +50,8 @@ public class GT_Tool_Chainsaw_HV extends GT_Tool_Chainsaw_LV {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadChainsaw.mTextureIndex]
+ ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadChainsaw.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_HV;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_LV.java b/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_LV.java
index f0b26eb913..5ed7647859 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_LV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_LV.java
@@ -1,14 +1,8 @@
package gregtech.common.tools;
-import gregtech.GT_Mod;
-import gregtech.api.GregTech_API;
-import gregtech.api.enums.OrePrefixes;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import java.util.ArrayList;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -22,7 +16,16 @@ import net.minecraft.world.World;
import net.minecraftforge.common.IShearable;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.GT_Mod;
+import gregtech.api.GregTech_API;
+import gregtech.api.enums.OrePrefixes;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public class GT_Tool_Chainsaw_LV extends GT_Tool_Saw {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -99,41 +102,29 @@ public class GT_Tool_Chainsaw_LV extends GT_Tool_Saw {
try {
GT_Mod.achievements.issueAchievement(aPlayer, "brrrr");
GT_Mod.achievements.issueAchievement(aPlayer, "buildChainsaw");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
int rAmount = 0;
if ((aBlock.getMaterial() == Material.leaves) && ((aBlock instanceof IShearable))) {
aPlayer.worldObj.setBlock(aX, aY, aZ, aBlock, aMetaData, 0);
if (((IShearable) aBlock).isShearable(aStack, aPlayer.worldObj, aX, aY, aZ)) {
- ArrayList<ItemStack> tDrops =
- ((IShearable) aBlock).onSheared(aStack, aPlayer.worldObj, aX, aY, aZ, aFortune);
+ ArrayList<ItemStack> tDrops = ((IShearable) aBlock)
+ .onSheared(aStack, aPlayer.worldObj, aX, aY, aZ, aFortune);
aDrops.clear();
}
aPlayer.worldObj.setBlock(aX, aY, aZ, Blocks.air, 0, 0);
} else if (((aBlock.getMaterial() == Material.ice) || (aBlock.getMaterial() == Material.packedIce))
&& (aDrops.isEmpty())) {
- aDrops.add(new ItemStack(aBlock, 1, aMetaData));
- aPlayer.worldObj.setBlockToAir(aX, aY, aZ);
- aEvent.dropChance = 1.0F;
- return 1;
- }
- if ((GregTech_API.sTimber)
- && (!aPlayer.isSneaking())
+ aDrops.add(new ItemStack(aBlock, 1, aMetaData));
+ aPlayer.worldObj.setBlockToAir(aX, aY, aZ);
+ aEvent.dropChance = 1.0F;
+ return 1;
+ }
+ if ((GregTech_API.sTimber) && (!aPlayer.isSneaking())
&& (OrePrefixes.log.contains(new ItemStack(aBlock, 1, aMetaData)))) {
int tY = aY + 1;
for (int tH = aPlayer.worldObj.getHeight(); tY < tH; tY++) {
@@ -148,51 +139,49 @@ public class GT_Tool_Chainsaw_LV extends GT_Tool_Saw {
}
@Override
- public float getMiningSpeed(
- Block aBlock, byte aMetaData, float aDefault, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ) {
+ public float getMiningSpeed(Block aBlock, byte aMetaData, float aDefault, EntityPlayer aPlayer, World aWorld,
+ int aX, int aY, int aZ) {
if (aBlock.isWood(aPlayer.worldObj, aX, aY, aZ)
&& OrePrefixes.log.contains(new ItemStack(aBlock, 1, aMetaData))) {
float rAmount = 1.0F;
float tIncrement = 1.0F;
if ((GregTech_API.sTimber) && !aPlayer.isSneaking()) {
int tY = aY + 1;
- for (int tH = aPlayer.worldObj.getHeight();
- (tY < tH) && (aPlayer.worldObj.getBlock(aX, tY, aZ) == aBlock);
- tY++) {
+ for (int tH = aPlayer.worldObj.getHeight(); (tY < tH)
+ && (aPlayer.worldObj.getBlock(aX, tY, aZ) == aBlock); tY++) {
tIncrement += 0.1F;
rAmount += tIncrement;
}
}
return 2.0F * aDefault / rAmount;
}
- return (aBlock.getMaterial() == Material.leaves)
- || (aBlock.getMaterial() == Material.vine)
- || (aBlock.getMaterial() == Material.plants)
- || (aBlock.getMaterial() == Material.gourd)
- ? aDefault / 4.0F
- : aDefault;
+ return (aBlock.getMaterial() == Material.leaves) || (aBlock.getMaterial() == Material.vine)
+ || (aBlock.getMaterial() == Material.plants)
+ || (aBlock.getMaterial() == Material.gourd) ? aDefault / 4.0F : aDefault;
}
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadChainsaw.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadChainsaw.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_LV;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " was massacred by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " was massacred by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_MV.java b/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_MV.java
index c28f89e361..863c26ac82 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_MV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Chainsaw_MV.java
@@ -1,10 +1,12 @@
package gregtech.common.tools;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Chainsaw_MV extends GT_Tool_Chainsaw_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return 200;
@@ -48,9 +50,8 @@ public class GT_Tool_Chainsaw_MV extends GT_Tool_Chainsaw_LV {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadChainsaw.mTextureIndex]
+ ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadChainsaw.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_MV;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Crowbar.java b/src/main/java/gregtech/common/tools/GT_Tool_Crowbar.java
index aeff5ecd17..a774ab7856 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Crowbar.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Crowbar.java
@@ -1,13 +1,7 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.interfaces.IToolStats;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.common.items.GT_MetaGenerated_Tool_01;
-import gregtech.common.items.behaviors.Behaviour_Crowbar;
import java.util.Iterator;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -16,7 +10,16 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.interfaces.IToolStats;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.common.items.GT_MetaGenerated_Tool_01;
+import gregtech.common.items.behaviors.Behaviour_Crowbar;
+
public class GT_Tool_Crowbar extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -94,12 +97,8 @@ public class GT_Tool_Crowbar extends GT_Tool {
}
String tTool = aBlock.getHarvestTool(aMetaData);
if ((tTool == null) || (tTool.equals(""))) {
- for (Iterator i$ = GT_MetaGenerated_Tool_01.INSTANCE
- .mToolStats
- .values()
- .iterator();
- i$.hasNext();
- i$.next()) {
+ for (Iterator i$ = GT_MetaGenerated_Tool_01.INSTANCE.mToolStats.values().iterator(); i$.hasNext(); i$
+ .next()) {
if (((i$ instanceof GT_Tool_Crowbar)) && (!((IToolStats) i$).isMinableBlock(aBlock, aMetaData))) {
return false;
}
@@ -132,7 +131,11 @@ public class GT_Tool_Crowbar extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " was removed by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " was removed by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Drill_HV.java b/src/main/java/gregtech/common/tools/GT_Tool_Drill_HV.java
index 018bf3d636..77ab501e46 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Drill_HV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Drill_HV.java
@@ -1,12 +1,14 @@
package gregtech.common.tools;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.item.ItemStack;
+
import gregtech.GT_Mod;
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Drill_HV extends GT_Tool_Drill_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return GT_Mod.gregtechproxy.mHardRock ? 400 : 800;
@@ -53,16 +55,14 @@ public class GT_Tool_Drill_HV extends GT_Tool_Drill_LV {
try {
GT_Mod.instance.achievements.issueAchievement(aPlayer, "highpowerdrill");
GT_Mod.instance.achievements.issueAchievement(aPlayer, "buildDDrill");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadDrill.mTextureIndex]
+ ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadDrill.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_HV;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Drill_LV.java b/src/main/java/gregtech/common/tools/GT_Tool_Drill_LV.java
index 202d9750ad..395c7753ff 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Drill_LV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Drill_LV.java
@@ -1,11 +1,5 @@
package gregtech.common.tools;
-import gregtech.GT_Mod;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -16,7 +10,15 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.GT_Mod;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Drill_LV extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return GT_Mod.gregtechproxy.mHardRock ? 25 : 50;
@@ -111,16 +113,14 @@ public class GT_Tool_Drill_LV extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadDrill.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadDrill.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_LV;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -135,14 +135,18 @@ public class GT_Tool_Drill_LV extends GT_Tool {
try {
GT_Mod.achievements.issueAchievement(aPlayer, "driltime");
GT_Mod.achievements.issueAchievement(aPlayer, "buildDrill");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " got the Drill! (by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + ")");
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got the Drill! (by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + ")");
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Drill_MV.java b/src/main/java/gregtech/common/tools/GT_Tool_Drill_MV.java
index b512a9d0bb..e9aa60aa69 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Drill_MV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Drill_MV.java
@@ -1,11 +1,13 @@
package gregtech.common.tools;
+import net.minecraft.item.ItemStack;
+
import gregtech.GT_Mod;
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Drill_MV extends GT_Tool_Drill_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return GT_Mod.gregtechproxy.mHardRock ? 100 : 200;
@@ -49,9 +51,8 @@ public class GT_Tool_Drill_MV extends GT_Tool_Drill_LV {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadDrill.mTextureIndex]
+ ? gregtech.api.items.GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadDrill.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_MV;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_File.java b/src/main/java/gregtech/common/tools/GT_Tool_File.java
index 6dfcaf685e..b642592775 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_File.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_File.java
@@ -1,9 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -11,7 +7,13 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_File extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -95,16 +97,14 @@ public class GT_Tool_File extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadFile.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadFile.mTextureIndex]
: Textures.ItemIcons.HANDLE_FILE;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -113,8 +113,12 @@ public class GT_Tool_File extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " has been filed D for 'Dead' by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has been filed D for 'Dead' by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_HardHammer.java b/src/main/java/gregtech/common/tools/GT_Tool_HardHammer.java
index 355078497e..c8ebcf14f2 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_HardHammer.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_HardHammer.java
@@ -2,16 +2,9 @@ package gregtech.common.tools;
import static gregtech.GT_Mod.MAX_IC2;
-import gregtech.GT_Mod;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_Recipe;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.api.util.GT_Utility;
-import gregtech.common.items.behaviors.Behaviour_Prospecting;
import java.util.Arrays;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.Entity;
@@ -24,13 +17,23 @@ import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.GT_Mod;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_Recipe;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.api.util.GT_Utility;
+import gregtech.common.items.behaviors.Behaviour_Prospecting;
+
public class GT_Tool_HardHammer extends GT_Tool {
- public static final List<String> mEffectiveList =
- Arrays.asList(EntityIronGolem.class.getName(), "EntityTowerGuardian");
+
+ public static final List<String> mEffectiveList = Arrays
+ .asList(EntityIronGolem.class.getName(), "EntityTowerGuardian");
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
String tName = aEntity.getClass().getName();
tName = tName.substring(tName.lastIndexOf('.') + 1);
return (mEffectiveList.contains(tName)) || (tName.contains("Golem")) ? aOriginalDamage * 2.0F : aOriginalDamage;
@@ -119,31 +122,21 @@ public class GT_Tool_HardHammer extends GT_Tool {
@Override
public boolean isMinableBlock(Block aBlock, byte aMetaData) {
return GT_ToolHarvestHelper.isAppropriateTool(aBlock, aMetaData, "hammer", "pickaxe")
- || GT_ToolHarvestHelper.isAppropriateMaterial(
- aBlock, Material.rock, Material.glass, Material.ice, Material.packedIce)
+ || GT_ToolHarvestHelper
+ .isAppropriateMaterial(aBlock, Material.rock, Material.glass, Material.ice, Material.packedIce)
|| GT_Recipe.GT_Recipe_Map.sHammerRecipes.containsInput(new ItemStack(aBlock, 1, aMetaData));
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
int rConversions = 0;
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes.findRecipe(
- null, true, MAX_IC2, null, new ItemStack(aBlock, 1, aMetaData));
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes
+ .findRecipe(null, true, MAX_IC2, null, new ItemStack(aBlock, 1, aMetaData));
if ((tRecipe == null) || (aBlock.hasTileEntity(aMetaData))) {
for (ItemStack tDrop : aDrops) {
- tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes.findRecipe(
- null, true, MAX_IC2, null, GT_Utility.copyAmount(1L, tDrop));
+ tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes
+ .findRecipe(null, true, MAX_IC2, null, GT_Utility.copyAmount(1L, tDrop));
if (tRecipe != null) {
ItemStack tHammeringOutput = tRecipe.getOutput(0);
if (tHammeringOutput != null) {
@@ -170,18 +163,15 @@ public class GT_Tool_HardHammer extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadHammer.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadHammer.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -193,8 +183,12 @@ public class GT_Tool_HardHammer extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " was squashed by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " was squashed by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
@Override
@@ -202,7 +196,6 @@ public class GT_Tool_HardHammer extends GT_Tool {
super.onToolCrafted(aStack, aPlayer);
try {
GT_Mod.achievements.issueAchievement(aPlayer, "tools");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Hoe.java b/src/main/java/gregtech/common/tools/GT_Tool_Hoe.java
index 84dbdba266..a108e7014c 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Hoe.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Hoe.java
@@ -1,9 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_Hoe;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -14,7 +10,13 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_Hoe;
+
public class GT_Tool_Hoe extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -94,18 +96,15 @@ public class GT_Tool_Hoe extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadHoe.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadHoe.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -122,8 +121,12 @@ public class GT_Tool_Hoe extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " has been called a stupid Hoe by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has been called a stupid Hoe by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_JackHammer.java b/src/main/java/gregtech/common/tools/GT_Tool_JackHammer.java
index 220ac01aba..aad96098fa 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_JackHammer.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_JackHammer.java
@@ -1,12 +1,7 @@
package gregtech.common.tools;
-import gregtech.GT_Mod;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.util.GT_Recipe;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.api.util.GT_Utility;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -17,7 +12,15 @@ import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.GT_Mod;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.util.GT_Recipe;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.api.util.GT_Utility;
+
public class GT_Tool_JackHammer extends GT_Tool_Drill_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return GT_Mod.gregtechproxy.mHardRock ? 200 : 400;
@@ -67,29 +70,19 @@ public class GT_Tool_JackHammer extends GT_Tool_Drill_LV {
Material.glass, //
Material.ice, //
Material.packedIce //
- );
+ );
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
int rConversions = 0;
- GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes.findRecipe(
- null, true, 2147483647L, null, new ItemStack(aBlock, 1, aMetaData));
+ GT_Recipe tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes
+ .findRecipe(null, true, 2147483647L, null, new ItemStack(aBlock, 1, aMetaData));
if ((tRecipe == null) || (aBlock.hasTileEntity(aMetaData))) {
for (ItemStack tDrop : aDrops) {
- tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes.findRecipe(
- null, true, 2147483647L, null, GT_Utility.copyAmount(1L, new Object[] {tDrop}));
+ tRecipe = GT_Recipe.GT_Recipe_Map.sHammerRecipes
+ .findRecipe(null, true, 2147483647L, null, GT_Utility.copyAmount(1L, new Object[] { tDrop }));
if (tRecipe != null) {
ItemStack tHammeringOutput = tRecipe.getOutput(0);
if (tHammeringOutput != null) {
@@ -113,8 +106,7 @@ public class GT_Tool_JackHammer extends GT_Tool_Drill_LV {
super.onToolCrafted(aStack, aPlayer);
try {
GT_Mod.instance.achievements.issueAchievement(aPlayer, "hammertime");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
@Override
@@ -124,8 +116,12 @@ public class GT_Tool_JackHammer extends GT_Tool_Drill_LV {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " has been jackhammered into pieces by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has been jackhammered into pieces by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Knife.java b/src/main/java/gregtech/common/tools/GT_Tool_Knife.java
index c211e1ac27..8354840ed7 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Knife.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Knife.java
@@ -1,7 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -9,7 +7,11 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+
public class GT_Tool_Knife extends GT_Tool_Sword {
+
@Override
public int getToolDamagePerBlockBreak() {
return 100;
@@ -57,9 +59,18 @@ public class GT_Tool_Knife extends GT_Tool_Sword {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText("<" + EnumChatFormatting.RED + aEntity.getCommandSenderName()
- + EnumChatFormatting.WHITE + "> " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + " what are you doing?, " + EnumChatFormatting.GREEN
- + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE + "?!? STAHP!!!");
+ return new ChatComponentText(
+ "<" + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + "> "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " what are you doing?, "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + "?!? STAHP!!!");
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Mortar.java b/src/main/java/gregtech/common/tools/GT_Tool_Mortar.java
index 1042ab6344..e7aae56c05 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Mortar.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Mortar.java
@@ -1,9 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.Dyes;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -11,7 +7,13 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.Dyes;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public class GT_Tool_Mortar extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -108,7 +110,11 @@ public class GT_Tool_Mortar extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " was grounded by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " was grounded by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Pickaxe.java b/src/main/java/gregtech/common/tools/GT_Tool_Pickaxe.java
index ce7707b4c2..58394491eb 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Pickaxe.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Pickaxe.java
@@ -1,9 +1,5 @@
package gregtech.common.tools;
-import gregtech.GT_Mod;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -14,7 +10,13 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.GT_Mod;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Pickaxe extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return GT_Mod.gregtechproxy.mHardRock ? 25 : 50;
@@ -99,18 +101,15 @@ public class GT_Tool_Pickaxe extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadPickaxe.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadPickaxe.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -124,14 +123,17 @@ public class GT_Tool_Pickaxe extends GT_Tool {
aPlayer.triggerAchievement(AchievementList.buildBetterPickaxe);
try {
GT_Mod.instance.achievements.issueAchievement(aPlayer, "flintpick");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " got mined by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got mined by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Plow.java b/src/main/java/gregtech/common/tools/GT_Tool_Plow.java
index dcf5c2675e..97b7092e36 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Plow.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Plow.java
@@ -1,9 +1,7 @@
package gregtech.common.tools;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.Entity;
@@ -17,12 +15,17 @@ import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Plow extends GT_Tool {
+
private ThreadLocal<Object> sIsHarvestingRightNow = new ThreadLocal();
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
return (aEntity instanceof EntitySnowman) ? aOriginalDamage * 4.0F : aOriginalDamage;
}
@@ -38,18 +41,8 @@ public class GT_Tool_Plow extends GT_Tool {
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
int rConversions = 0;
if ((this.sIsHarvestingRightNow.get() == null) && ((aPlayer instanceof EntityPlayerMP))) {
this.sIsHarvestingRightNow.set(this);
@@ -57,14 +50,12 @@ public class GT_Tool_Plow extends GT_Tool {
for (int j = -1; j < 2; j++) {
for (int k = -1; k < 2; k++) {
if (((i != 0) || (j != 0) || (k != 0))
- && (aStack.getItem()
- .getDigSpeed(
- aStack,
- aPlayer.worldObj.getBlock(aX + i, aY + j, aZ + k),
- aPlayer.worldObj.getBlockMetadata(aX + i, aY + j, aZ + k))
- > 0.0F)
- && (((EntityPlayerMP) aPlayer)
- .theItemInWorldManager.tryHarvestBlock(aX + i, aY + j, aZ + k))) {
+ && (aStack.getItem().getDigSpeed(
+ aStack,
+ aPlayer.worldObj.getBlock(aX + i, aY + j, aZ + k),
+ aPlayer.worldObj.getBlockMetadata(aX + i, aY + j, aZ + k)) > 0.0F)
+ && (((EntityPlayerMP) aPlayer).theItemInWorldManager
+ .tryHarvestBlock(aX + i, aY + j, aZ + k))) {
rConversions++;
}
}
@@ -78,25 +69,26 @@ public class GT_Tool_Plow extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadPlow.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadPlow.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + " plew through the yard of " + EnumChatFormatting.RED
- + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " plew through the yard of "
+ + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Plunger.java b/src/main/java/gregtech/common/tools/GT_Tool_Plunger.java
index a8f557045f..b08e76dca3 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Plunger.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Plunger.java
@@ -1,5 +1,12 @@
package gregtech.common.tools;
+import net.minecraft.block.Block;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.ChatComponentText;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.IChatComponent;
+
import gregtech.api.enums.SoundResource;
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
@@ -9,14 +16,9 @@ import gregtech.api.util.GT_ToolHarvestHelper;
import gregtech.api.util.GT_Utility;
import gregtech.common.items.behaviors.Behaviour_Plunger_Fluid;
import gregtech.common.items.behaviors.Behaviour_Plunger_Item;
-import net.minecraft.block.Block;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.IChatComponent;
public class GT_Tool_Plunger extends GT_Tool {
+
@Override
public float getBaseDamage() {
return 1.25F;
@@ -54,8 +56,7 @@ public class GT_Tool_Plunger extends GT_Tool {
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -73,14 +74,17 @@ public class GT_Tool_Plunger extends GT_Tool {
if ((tObject instanceof IItemBehaviour)) {
aItem.addItemBehavior(aID, (IItemBehaviour) tObject);
}
- } catch (Throwable ignored) {
- }
+ } catch (Throwable ignored) {}
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " got stuck trying to escape through a Pipe while fighting " + EnumChatFormatting.GREEN
- + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got stuck trying to escape through a Pipe while fighting "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_RollingPin.java b/src/main/java/gregtech/common/tools/GT_Tool_RollingPin.java
index 3b554c39a4..ca9b9d3fa8 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_RollingPin.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_RollingPin.java
@@ -1,9 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.Dyes;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -11,7 +7,13 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.Dyes;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public class GT_Tool_RollingPin extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -57,8 +59,12 @@ public class GT_Tool_RollingPin extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " got flattened by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got flattened by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Saw.java b/src/main/java/gregtech/common/tools/GT_Tool_Saw.java
index 881ed6f61f..8fa1494a7e 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Saw.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Saw.java
@@ -1,11 +1,8 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import java.util.ArrayList;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -18,7 +15,13 @@ import net.minecraft.util.IChatComponent;
import net.minecraftforge.common.IShearable;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Saw extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -75,23 +78,13 @@ public class GT_Tool_Saw extends GT_Tool {
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
if ((aBlock.getMaterial() == Material.leaves) && ((aBlock instanceof IShearable))) {
aPlayer.worldObj.setBlock(aX, aY, aZ, aBlock, aMetaData, 0);
if (((IShearable) aBlock).isShearable(aStack, aPlayer.worldObj, aX, aY, aZ)) {
- ArrayList<ItemStack> tDrops =
- ((IShearable) aBlock).onSheared(aStack, aPlayer.worldObj, aX, aY, aZ, aFortune);
+ ArrayList<ItemStack> tDrops = ((IShearable) aBlock)
+ .onSheared(aStack, aPlayer.worldObj, aX, aY, aZ, aFortune);
aDrops.clear();
aDrops.addAll(tDrops);
aEvent.dropChance = 1.0F;
@@ -99,11 +92,11 @@ public class GT_Tool_Saw extends GT_Tool {
aPlayer.worldObj.setBlock(aX, aY, aZ, Blocks.air, 0, 0);
} else if (((aBlock.getMaterial() == Material.ice) || (aBlock.getMaterial() == Material.packedIce))
&& (aDrops.isEmpty())) {
- aDrops.add(new ItemStack(aBlock, 1, aMetaData));
- aPlayer.worldObj.setBlockToAir(aX, aY, aZ);
- aEvent.dropChance = 1.0F;
- return 1;
- }
+ aDrops.add(new ItemStack(aBlock, 1, aMetaData));
+ aPlayer.worldObj.setBlockToAir(aX, aY, aZ);
+ aEvent.dropChance = 1.0F;
+ return 1;
+ }
return 0;
}
@@ -128,16 +121,14 @@ public class GT_Tool_Saw extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadSaw.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadSaw.mTextureIndex]
: Textures.ItemIcons.HANDLE_SAW;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -146,8 +137,12 @@ public class GT_Tool_Saw extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " was getting cut down by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " was getting cut down by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Scoop.java b/src/main/java/gregtech/common/tools/GT_Tool_Scoop.java
index 06423f2d45..f0ad65d838 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Scoop.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Scoop.java
@@ -1,5 +1,13 @@
package gregtech.common.tools;
+import net.minecraft.block.Block;
+import net.minecraft.block.material.Material;
+import net.minecraft.entity.EntityLivingBase;
+import net.minecraft.item.ItemStack;
+import net.minecraft.util.ChatComponentText;
+import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.util.IChatComponent;
+
import cpw.mods.fml.common.Loader;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.Textures;
@@ -8,15 +16,9 @@ import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.api.util.GT_ToolHarvestHelper;
import gregtech.common.items.behaviors.Behaviour_None;
import gregtech.common.items.behaviors.Behaviour_Scoop;
-import net.minecraft.block.Block;
-import net.minecraft.block.material.Material;
-import net.minecraft.entity.EntityLivingBase;
-import net.minecraft.item.ItemStack;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-import net.minecraft.util.IChatComponent;
public class GT_Tool_Scoop extends GT_Tool {
+
public static Material sBeeHiveMaterial;
@Override
@@ -102,8 +104,7 @@ public class GT_Tool_Scoop extends GT_Tool {
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -118,8 +119,12 @@ public class GT_Tool_Scoop extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " got scooped up by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got scooped up by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver.java b/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver.java
index 1007c81f9f..42542bb75d 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver.java
@@ -1,13 +1,8 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_Screwdriver;
import java.util.Arrays;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.Entity;
@@ -20,7 +15,15 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_Screwdriver;
+
public class GT_Tool_Screwdriver extends GT_Tool {
+
public static final List<String> mEffectiveList = Arrays.asList(
EntityCaveSpider.class.getName(),
EntitySpider.class.getName(),
@@ -30,8 +33,8 @@ public class GT_Tool_Screwdriver extends GT_Tool {
"EntityTFTowerBroodling");
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
String tName = aEntity.getClass().getName();
tName = tName.substring(tName.lastIndexOf('.') + 1);
return mEffectiveList.contains(tName) ? aOriginalDamage * 2.0F : aOriginalDamage;
@@ -126,16 +129,14 @@ public class GT_Tool_Screwdriver extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadScrewdriver.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadScrewdriver.mTextureIndex]
: Textures.ItemIcons.HANDLE_SCREWDRIVER;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -147,7 +148,12 @@ public class GT_Tool_Screwdriver extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " is screwed! (by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE + ")");
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " is screwed! (by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + ")");
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver_LV.java b/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver_LV.java
index 4243e9549f..acb032b26e 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver_LV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Screwdriver_LV.java
@@ -1,11 +1,13 @@
package gregtech.common.tools;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Screwdriver_LV extends GT_Tool_Screwdriver {
+
@Override
public float getMaxDurabilityMultiplier() {
return 1.0F;
@@ -19,16 +21,14 @@ public class GT_Tool_Screwdriver_LV extends GT_Tool_Screwdriver {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadScrewdriver.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadScrewdriver.mTextureIndex]
: Textures.ItemIcons.HANDLE_ELECTRIC_SCREWDRIVER;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Sense.java b/src/main/java/gregtech/common/tools/GT_Tool_Sense.java
index 18245a7897..dd6cae9aaf 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Sense.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Sense.java
@@ -1,10 +1,7 @@
package gregtech.common.tools;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_Sense;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -16,7 +13,13 @@ import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
import net.minecraftforge.event.world.BlockEvent;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_Sense;
+
public class GT_Tool_Sense extends GT_Tool {
+
private ThreadLocal<Object> sIsHarvestingRightNow = new ThreadLocal();
@Override
@@ -36,18 +39,8 @@ public class GT_Tool_Sense extends GT_Tool {
}
@Override
- public int convertBlockDrops(
- List<ItemStack> aDrops,
- ItemStack aStack,
- EntityPlayer aPlayer,
- Block aBlock,
- int aX,
- int aY,
- int aZ,
- byte aMetaData,
- int aFortune,
- boolean aSilkTouch,
- BlockEvent.HarvestDropsEvent aEvent) {
+ public int convertBlockDrops(List<ItemStack> aDrops, ItemStack aStack, EntityPlayer aPlayer, Block aBlock, int aX,
+ int aY, int aZ, byte aMetaData, int aFortune, boolean aSilkTouch, BlockEvent.HarvestDropsEvent aEvent) {
int rConversions = 0;
if ((this.sIsHarvestingRightNow.get() == null) && ((aPlayer instanceof EntityPlayerMP))) {
this.sIsHarvestingRightNow.set(this);
@@ -55,14 +48,12 @@ public class GT_Tool_Sense extends GT_Tool {
for (int j = -2; j < 3; j++) {
for (int k = -2; k < 3; k++) {
if (((i != 0) || (j != 0) || (k != 0))
- && (aStack.getItem()
- .getDigSpeed(
- aStack,
- aPlayer.worldObj.getBlock(aX + i, aY + j, aZ + k),
- aPlayer.worldObj.getBlockMetadata(aX + i, aY + j, aZ + k))
- > 0.0F)
- && (((EntityPlayerMP) aPlayer)
- .theItemInWorldManager.tryHarvestBlock(aX + i, aY + j, aZ + k))) {
+ && (aStack.getItem().getDigSpeed(
+ aStack,
+ aPlayer.worldObj.getBlock(aX + i, aY + j, aZ + k),
+ aPlayer.worldObj.getBlockMetadata(aX + i, aY + j, aZ + k)) > 0.0F)
+ && (((EntityPlayerMP) aPlayer).theItemInWorldManager
+ .tryHarvestBlock(aX + i, aY + j, aZ + k))) {
rConversions++;
}
}
@@ -76,18 +67,15 @@ public class GT_Tool_Sense extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadSense.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadSense.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -98,8 +86,12 @@ public class GT_Tool_Sense extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + " has taken the Soul of " + EnumChatFormatting.RED
- + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has taken the Soul of "
+ + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Shovel.java b/src/main/java/gregtech/common/tools/GT_Tool_Shovel.java
index 1cd88bf281..91a0802c3d 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Shovel.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Shovel.java
@@ -1,8 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -11,7 +8,12 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Shovel extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -81,7 +83,12 @@ public class GT_Tool_Shovel extends GT_Tool {
public boolean isMinableBlock(Block aBlock, byte aMetaData) {
return GT_ToolHarvestHelper.isAppropriateTool(aBlock, aMetaData, "shovel")
|| GT_ToolHarvestHelper.isAppropriateMaterial(
- aBlock, Material.sand, Material.grass, Material.ground, Material.snow, Material.clay);
+ aBlock,
+ Material.sand,
+ Material.grass,
+ Material.ground,
+ Material.snow,
+ Material.clay);
}
@Override
@@ -92,18 +99,15 @@ public class GT_Tool_Shovel extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadShovel.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadShovel.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -113,7 +117,11 @@ public class GT_Tool_Shovel extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
return new ChatComponentText(
- EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE + " got dug up by "
- + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName() + EnumChatFormatting.WHITE);
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got dug up by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_SoftHammer.java b/src/main/java/gregtech/common/tools/GT_Tool_SoftHammer.java
index 09e4174c96..0745359227 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_SoftHammer.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_SoftHammer.java
@@ -1,10 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_SoftHammer;
import net.minecraft.block.Block;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
@@ -13,7 +8,14 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_SoftHammer;
+
public class GT_Tool_SoftHammer extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -107,18 +109,15 @@ public class GT_Tool_SoftHammer extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadMallet.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.handleMallet.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadMallet.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.handleMallet.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -129,8 +128,12 @@ public class GT_Tool_SoftHammer extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " was hammered to death by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " was hammered to death by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Soldering_Iron.java b/src/main/java/gregtech/common/tools/GT_Tool_Soldering_Iron.java
index 2d4728e4da..d9ffb86059 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Soldering_Iron.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Soldering_Iron.java
@@ -1,13 +1,8 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_Screwdriver;
import java.util.Arrays;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.Entity;
@@ -20,7 +15,15 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_Screwdriver;
+
public class GT_Tool_Soldering_Iron extends GT_Tool {
+
public static final List<String> mEffectiveList = Arrays.asList(
EntityCaveSpider.class.getName(),
EntitySpider.class.getName(),
@@ -30,8 +33,8 @@ public class GT_Tool_Soldering_Iron extends GT_Tool {
"EntityTFTowerBroodling");
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
String tName = aEntity.getClass().getName();
tName = tName.substring(tName.lastIndexOf('.') + 1);
return mEffectiveList.contains(tName) ? aOriginalDamage * 2.0F : aOriginalDamage;
@@ -120,15 +123,13 @@ public class GT_Tool_Soldering_Iron extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mIconSet.mTextures[49]
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mIconSet.mTextures[49]
: Textures.ItemIcons.HANDLE_SOLDERING;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -139,8 +140,13 @@ public class GT_Tool_Soldering_Iron extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " got soldert! (by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + ")");
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " got soldert! (by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + ")");
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Sword.java b/src/main/java/gregtech/common/tools/GT_Tool_Sword.java
index baafab6136..bb8222d221 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Sword.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Sword.java
@@ -1,16 +1,18 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.stats.AchievementList;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_Sword extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 200;
@@ -107,16 +109,14 @@ public class GT_Tool_Sword extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadSword.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadSword.mTextureIndex]
: Textures.ItemIcons.HANDLE_SWORD;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return !aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return !aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Turbine.java b/src/main/java/gregtech/common/tools/GT_Tool_Turbine.java
index dd5d2b424e..12d4d79884 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Turbine.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Turbine.java
@@ -1,7 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -9,7 +7,11 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public abstract class GT_Tool_Turbine extends GT_Tool {
+
@Override
public abstract float getBaseDamage();
@@ -30,9 +32,15 @@ public abstract class GT_Tool_Turbine extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + " put " + EnumChatFormatting.RED + aEntity.getCommandSenderName() + "s"
- + EnumChatFormatting.WHITE + " head into a turbine");
+ return new ChatComponentText(
+ EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " put "
+ + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + "s"
+ + EnumChatFormatting.WHITE
+ + " head into a turbine");
}
public abstract IIconContainer getTurbineIcon();
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Huge.java b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Huge.java
index c4bb45c778..46b0de72d9 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Huge.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Huge.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
public class GT_Tool_Turbine_Huge extends GT_Tool_Turbine {
+
@Override
public float getSpeedMultiplier() {
return 4.0F;
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Large.java b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Large.java
index d8bff76ca8..7e8307f6b0 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Large.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Large.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
public class GT_Tool_Turbine_Large extends GT_Tool_Turbine {
+
@Override
public float getSpeedMultiplier() {
return 3.0F;
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Normal.java b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Normal.java
index a4ff2368d9..ac2fc29a89 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Normal.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Normal.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
public class GT_Tool_Turbine_Normal extends GT_Tool_Turbine {
+
@Override
public float getSpeedMultiplier() {
return 2.0F;
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Small.java b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Small.java
index d9517525c2..fab527386e 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Small.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Turbine_Small.java
@@ -4,6 +4,7 @@ import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
public class GT_Tool_Turbine_Small extends GT_Tool_Turbine {
+
@Override
public float getSpeedMultiplier() {
return 1.0F;
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_UniversalSpade.java b/src/main/java/gregtech/common/tools/GT_Tool_UniversalSpade.java
index b534ef2d23..1038c60dc4 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_UniversalSpade.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_UniversalSpade.java
@@ -1,10 +1,5 @@
package gregtech.common.tools;
-import gregtech.GT_Mod;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_Crowbar;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.EntityLivingBase;
@@ -15,7 +10,14 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.GT_Mod;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_Crowbar;
+
public class GT_Tool_UniversalSpade extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 50;
@@ -119,18 +121,15 @@ public class GT_Tool_UniversalSpade extends GT_Tool {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadUniversalSpade.mTextureIndex]
- : GT_MetaGenerated_Tool.getSecondaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadUniversalSpade.mTextureIndex]
+ : GT_MetaGenerated_Tool.getSecondaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.stick.mTextureIndex];
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -145,14 +144,17 @@ public class GT_Tool_UniversalSpade extends GT_Tool {
aPlayer.triggerAchievement(AchievementList.buildSword);
try {
GT_Mod.achievements.issueAchievement(aPlayer, "unitool");
- } catch (Exception ignored) {
- }
+ } catch (Exception ignored) {}
}
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE
- + " has been digged by " + EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.RED + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has been digged by "
+ + EnumChatFormatting.GREEN
+ + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_WireCutter.java b/src/main/java/gregtech/common/tools/GT_Tool_WireCutter.java
index dedf87a553..2080d435ee 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_WireCutter.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_WireCutter.java
@@ -1,10 +1,5 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
import net.minecraft.block.Block;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
@@ -12,7 +7,14 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+
public class GT_Tool_WireCutter extends GT_Tool {
+
@Override
public int getToolDamagePerBlockBreak() {
return 100;
@@ -95,8 +97,7 @@ public class GT_Tool_WireCutter extends GT_Tool {
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
@@ -105,8 +106,12 @@ public class GT_Tool_WireCutter extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + " has cut the Cable for the Life Support Machine of "
- + EnumChatFormatting.RED + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " has cut the Cable for the Life Support Machine of "
+ + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Wrench.java b/src/main/java/gregtech/common/tools/GT_Tool_Wrench.java
index 77aac357e8..955765287f 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Wrench.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Wrench.java
@@ -1,13 +1,8 @@
package gregtech.common.tools;
-import gregtech.api.enums.SoundResource;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
-import gregtech.api.util.GT_ToolHarvestHelper;
-import gregtech.common.items.behaviors.Behaviour_Wrench;
import java.util.Arrays;
import java.util.List;
+
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.entity.Entity;
@@ -20,13 +15,21 @@ import net.minecraft.util.ChatComponentText;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IChatComponent;
+import gregtech.api.enums.SoundResource;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+import gregtech.api.util.GT_ToolHarvestHelper;
+import gregtech.common.items.behaviors.Behaviour_Wrench;
+
public class GT_Tool_Wrench extends GT_Tool {
- public static final List<String> mEffectiveList =
- Arrays.asList(EntityIronGolem.class.getName(), "EntityTowerGuardian");
+
+ public static final List<String> mEffectiveList = Arrays
+ .asList(EntityIronGolem.class.getName(), "EntityTowerGuardian");
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
String tName = aEntity.getClass().getName();
tName = tName.substring(tName.lastIndexOf('.') + 1);
return (mEffectiveList.contains(tName)) || (tName.contains("Golem")) ? aOriginalDamage * 2.0F : aOriginalDamage;
@@ -136,8 +139,12 @@ public class GT_Tool_Wrench extends GT_Tool {
@Override
public IChatComponent getDeathMessage(EntityLivingBase aPlayer, EntityLivingBase aEntity) {
- return new ChatComponentText(EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
- + EnumChatFormatting.WHITE + " threw a Monkey Wrench into the Plans of " + EnumChatFormatting.RED
- + aEntity.getCommandSenderName() + EnumChatFormatting.WHITE);
+ return new ChatComponentText(
+ EnumChatFormatting.GREEN + aPlayer.getCommandSenderName()
+ + EnumChatFormatting.WHITE
+ + " threw a Monkey Wrench into the Plans of "
+ + EnumChatFormatting.RED
+ + aEntity.getCommandSenderName()
+ + EnumChatFormatting.WHITE);
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Wrench_HV.java b/src/main/java/gregtech/common/tools/GT_Tool_Wrench_HV.java
index e0ccdfde4f..812c29dcec 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Wrench_HV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Wrench_HV.java
@@ -1,11 +1,13 @@
package gregtech.common.tools;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Wrench_HV extends GT_Tool_Wrench_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return 800;
@@ -54,16 +56,14 @@ public class GT_Tool_Wrench_HV extends GT_Tool_Wrench_LV {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadWrench.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadWrench.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_HV;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Wrench_LV.java b/src/main/java/gregtech/common/tools/GT_Tool_Wrench_LV.java
index 999d26ae9e..1ee87b442c 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Wrench_LV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Wrench_LV.java
@@ -1,16 +1,18 @@
package gregtech.common.tools;
-import gregtech.api.enums.Textures;
-import gregtech.api.interfaces.IIconContainer;
-import gregtech.api.items.GT_MetaGenerated_Tool;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
+import gregtech.api.enums.Textures;
+import gregtech.api.interfaces.IIconContainer;
+import gregtech.api.items.GT_MetaGenerated_Tool;
+
public class GT_Tool_Wrench_LV extends GT_Tool_Wrench {
+
@Override
- public float getNormalDamageAgainstEntity(
- float aOriginalDamage, Entity aEntity, ItemStack aStack, EntityPlayer aPlayer) {
+ public float getNormalDamageAgainstEntity(float aOriginalDamage, Entity aEntity, ItemStack aStack,
+ EntityPlayer aPlayer) {
return aOriginalDamage;
}
@@ -62,16 +64,14 @@ public class GT_Tool_Wrench_LV extends GT_Tool_Wrench {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadWrench.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadWrench.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_LV;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
}
diff --git a/src/main/java/gregtech/common/tools/GT_Tool_Wrench_MV.java b/src/main/java/gregtech/common/tools/GT_Tool_Wrench_MV.java
index fe2f0611ab..b8218eb3df 100644
--- a/src/main/java/gregtech/common/tools/GT_Tool_Wrench_MV.java
+++ b/src/main/java/gregtech/common/tools/GT_Tool_Wrench_MV.java
@@ -1,11 +1,13 @@
package gregtech.common.tools;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Wrench_MV extends GT_Tool_Wrench_LV {
+
@Override
public int getToolDamagePerBlockBreak() {
return 200;
@@ -54,16 +56,14 @@ public class GT_Tool_Wrench_MV extends GT_Tool_Wrench_LV {
@Override
public IIconContainer getIcon(boolean aIsToolHead, ItemStack aStack) {
return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack)
- .mIconSet
- .mTextures[gregtech.api.enums.OrePrefixes.toolHeadWrench.mTextureIndex]
+ ? GT_MetaGenerated_Tool.getPrimaryMaterial(
+ aStack).mIconSet.mTextures[gregtech.api.enums.OrePrefixes.toolHeadWrench.mTextureIndex]
: Textures.ItemIcons.POWER_UNIT_MV;
}
@Override
public short[] getRGBa(boolean aIsToolHead, ItemStack aStack) {
- return aIsToolHead
- ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
+ return aIsToolHead ? GT_MetaGenerated_Tool.getPrimaryMaterial(aStack).mRGBa
: GT_MetaGenerated_Tool.getSecondaryMaterial(aStack).mRGBa;
}
}
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_BranchCutter.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_BranchCutter.java
index 0265fc899a..b831306df9 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_BranchCutter.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_BranchCutter.java
@@ -1,13 +1,15 @@
package gregtech.common.tools.pocket;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool_BranchCutter;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_BranchCutter extends GT_Tool_BranchCutter {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_BranchCutter(int aSwitchIndex) {
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_File.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_File.java
index eb114ef6a1..84372b1d98 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_File.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_File.java
@@ -1,13 +1,15 @@
package gregtech.common.tools.pocket;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool_File;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_File extends GT_Tool_File {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_File(int aSwitchIndex) {
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Knife.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Knife.java
index 8073b3449a..2b43984c51 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Knife.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Knife.java
@@ -1,13 +1,15 @@
package gregtech.common.tools.pocket;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool_Knife;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_Knife extends GT_Tool_Knife {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_Knife(int aSwitchIndex) {
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Multitool.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Multitool.java
index c071b6b072..16ab9229c6 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Multitool.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Multitool.java
@@ -1,14 +1,16 @@
package gregtech.common.tools.pocket;
+import net.minecraft.block.Block;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool;
-import net.minecraft.block.Block;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_Multitool extends GT_Tool {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_Multitool(int aSwitchIndex) {
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Saw.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Saw.java
index 2bcbc1513e..579f809f2a 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Saw.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Saw.java
@@ -1,13 +1,15 @@
package gregtech.common.tools.pocket;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool_Saw;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_Saw extends GT_Tool_Saw {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_Saw(int aSwitchIndex) {
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Screwdriver.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Screwdriver.java
index 0ac6782a3b..ce04ba2d15 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Screwdriver.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_Screwdriver.java
@@ -1,13 +1,15 @@
package gregtech.common.tools.pocket;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool_Screwdriver;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_Screwdriver extends GT_Tool_Screwdriver {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_Screwdriver(int aSwitchIndex) {
diff --git a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_WireCutter.java b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_WireCutter.java
index 13bfe896d1..6907ff6735 100644
--- a/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_WireCutter.java
+++ b/src/main/java/gregtech/common/tools/pocket/GT_Tool_Pocket_WireCutter.java
@@ -1,13 +1,15 @@
package gregtech.common.tools.pocket;
+import net.minecraft.item.ItemStack;
+
import gregtech.api.enums.Textures;
import gregtech.api.interfaces.IIconContainer;
import gregtech.api.items.GT_MetaGenerated_Tool;
import gregtech.common.items.behaviors.Behaviour_Switch_Metadata;
import gregtech.common.tools.GT_Tool_WireCutter;
-import net.minecraft.item.ItemStack;
public class GT_Tool_Pocket_WireCutter extends GT_Tool_WireCutter {
+
public final int mSwitchIndex;
public GT_Tool_Pocket_WireCutter(int aSwitchIndex) {