neuralgia/kubejs/startup_scripts/gtceu/machines.js
Redeix f61a6615dd
More things (#1468)
* - Yeast recipe conflict fix

* - Fixed seed oil voiding in barrels. And item weight inconsistency.

* - Reduced loading screen logo size by 4MB

* - Update Changelog

* - Compressed loading screen images to maybe help with ram

* - Added default gui scale to make the main menu look better on first launch

* - Update Changelog

* - Added utility script for adding circuits to existing recipes

* fixed changelog conflict

Signed-off-by: Redeix <59435925+Redeix@users.noreply.github.com>

* - Added harvest baskets

* - Fixed baked potato recipe mixing from oven

* - Allowed elytras to be repaired regardless of damage

* - Fixed sea water barrel recipe

* - Gave plants tags to bushes so they can have other uses

* - Pushed stubborn models

* - updated Changelog

* - Changelog typo

* - Integrated Ad Astra wood

* - Updated changelog

* - Treated chipboard composite barrel lang

* - Some Tacz fixes

* - Jar dupe fix

* - tacz data

* - updated changelog

* - we hate git

* - Loading screen and main menu optimizations

* - image push

* - I think I got the title screen looking good on all resolutions

* - Updated Changelog

* - Added scale fix to loading screen too

* - Fix pixel alignment

* - Recipes, tags, assets+ for railgun

* - Brick interaction events and new function for interacting with blocks

* - Added parameter boolean to decide if blockstate should be copied

* - Change for block interaction event constant that may fix linux crash

* - Moved global array to the events file and some linter fixes.

* - Updated Changelog

* - Some more model fixes and remove gtceu metal armor

* - always a stubborn file

* - Large Solar Panel Change

---------

Signed-off-by: Redeix <59435925+Redeix@users.noreply.github.com>
Signed-off-by: Pyritie <pyritie@gmail.com>
Co-authored-by: Pyritie <pyritie@gmail.com>
2025-07-28 15:03:48 +10:00

289 lines
No EOL
25 KiB
JavaScript

// priority: 0
const registerGTCEuMachines = (event) => {
const $SteamMulti = Java.loadClass('com.gregtechceu.gtceu.common.machine.multiblock.steam.SteamParallelMultiblockMachine');
const $Tags = Java.loadClass("dev.latvian.mods.kubejs.util.Tags")
//#region Nether Dome
event.create('nether_dome', 'multiblock')
.rotationState(RotationState.NON_Y_AXIS)
.recipeType('nether_dome')
.appearanceBlock(GTBlocks.CASING_PTFE_INERT)
.pattern(definition => FactoryBlockPattern.start()
.aisle(" CCCCC ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " F ")
.aisle("CBBBBBC", "Q#####Q", "Q#####Q", "Q#####Q", "QTTTTTQ", " QQQQQ ")
.aisle("CBBBBBC", "Q#####Q", "Q#####Q", "Q#####Q", "QTTTTTQ", " QQQQQ ")
.aisle("CBBBBBC", "F#####F", "F#####F", "F#####F", "FTTTTTF", "FQQQQQF")
.aisle("CBBBBBC", "Q#####Q", "Q#####Q", "Q#####Q", "QTTTTTQ", " QQQQQ ")
.aisle("CBBBBBC", "Q#####Q", "Q#####Q", "Q#####Q", "QTTTTTQ", " QQQQQ ")
.aisle(" CCXCC ", " QGOGQ ", " QOPOQ ", " QOPOQ ", " QGOGQ ", " ")
.where('X', Predicates.controller(Predicates.blocks(definition.get())))
.where('B', Predicates.blocks('tfc:rock/magma/basalt').setMinGlobalLimited(6)
.or(Predicates.blocks('minecraft:netherrack').setMinGlobalLimited(10)))
.where('T', Predicates.blocks('minecraft:glowstone').setMinGlobalLimited(5)
.or(Predicates.blocks('minecraft:netherrack').setMinGlobalLimited(10)))
.where('O', Predicates.blocks('minecraft:obsidian'))
.where('F', Predicates.frames('black_steel'))
.where('Q', Predicates.blocks('ae2:quartz_glass'))
.where('G', Predicates.blocks('minecraft:gold_block')
.or(Predicates.blocks('tfc:rock/raw/basalt'))
.or(Predicates.blocks('tfc:rock/hardened/basalt'))
.or(Predicates.blocks('tfc:rock/bricks/basalt'))
.or(Predicates.blocks('tfc:rock/chiseled/basalt'))
.or(Predicates.blocks('minecraft:obsidian'))
.or(Predicates.blocks('minecraft:nether_bricks')))
.where('P', Predicates.blocks('minecraft:purple_stained_glass_pane'))
.where('C', Predicates.blocks(GTBlocks.CASING_PTFE_INERT.get()).setMinGlobalLimited(10)
.or(Predicates.autoAbilities(definition.getRecipeTypes()))
.or(Predicates.abilities(PartAbility.MAINTENANCE).setExactLimit(1)))
.where('#', Predicates.air()
.or(Predicates.blocks('minecraft:netherrack'))
.or(Predicates.blocks('tfc:rock/magma/basalt'))
.or(Predicates.blocks('minecraft:glowstone'))
.or(Predicates.blocks('minecraft:nether_bricks')))
.where(' ', Predicates.any())
.build()
)
.shapeInfo(controller => MultiblockShapeInfo.builder()
.aisle(" CeCeC ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " F ")
.aisle("CMMMNNC", "Q NQ", "Q Q", "Q Q", "QNTTNNQ", " QQQQQ ")
.aisle("iMMNNNf", "QR Q", "QR Q", "Q T Q", "QNTTTNQ", " QQQQQ ")
.aisle("CNMMMNC", "F NF", "F F", "F F", "FNNTNNF", "FQQQQQF")
.aisle("tNNNMNl", "Q NQ", "Q NQ", "Q Q", "QNNNNNQ", " QQQQQ ")
.aisle("CNNNNNC", "QN NNQ", "Q NQ", "Q NQ", "QNNNNNQ", " QQQQQ ")
.aisle(" mCXCC ", " QGOGQ ", " QOPOQ ", " QOPOQ ", " QGOGQ ", " ")
.where('X', controller, Direction.SOUTH)
.where('C', GTBlocks.CASING_PTFE_INERT.get())
.where('N', Block.getBlock('minecraft:netherrack'))
.where('M', Block.getBlock('tfc:rock/magma/basalt'))
.where('T', Block.getBlock('minecraft:glowstone'))
.where('Q', Block.getBlock('ae2:quartz_glass'))
.where('F', Block.getBlock('gtceu:black_steel_frame'))
.where('G', Block.getBlock('minecraft:gold_block'))
.where('O', Block.getBlock('minecraft:obsidian'))
.where('P', Block.getBlock('minecraft:purple_stained_glass_pane'))
.where('R', Block.getBlock('minecraft:nether_bricks'))
.where(' ', Block.getBlock('minecraft:air'))
.where('m', GTMachines.MAINTENANCE_HATCH, Direction.SOUTH)
.where('i', GTMachines.ITEM_IMPORT_BUS[GTValues.ULV], Direction.WEST)
.where('t', GTMachines.ITEM_EXPORT_BUS[GTValues.ULV], Direction.WEST)
.where('f', GTMachines.FLUID_IMPORT_HATCH[GTValues.MV], Direction.EAST)
.where('l', GTMachines.FLUID_EXPORT_HATCH[GTValues.MV], Direction.EAST)
.where('e', GTMachines.ENERGY_INPUT_HATCH[GTValues.MV], Direction.NORTH)
.build()
)
.workableCasingModel(
"gtceu:block/casings/solid/machine_casing_inert_ptfe",
"gtceu:block/machines/gas_collector")
//#endregion
//#region End Dome
event.create('end_dome', 'multiblock')
.rotationState(RotationState.NON_Y_AXIS)
.recipeType('end_dome')
.appearanceBlock(GTBlocks.CASING_TITANIUM_STABLE)
.pattern(definition => FactoryBlockPattern.start()
.aisle(" CCCCC ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " F ", " ")
.aisle("CBBBBBC", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", " QSSSQ ", " GGG ")
.aisle("CBBBBBC", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", " SNNNS ", " G G ")
.aisle("CBBBBBC", "FOOEOOF", "FOOOOOF", "FOOOOOF", "FOOOOOF", "FSNNNSF", " G G ")
.aisle("CBBBBBC", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", " SNNNS ", " G G ")
.aisle("CBBBBBC", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", "QOOOOOQ", " QSSSQ ", " GGG ")
.aisle(" CCXCC ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " F ", " ")
.where('X', Predicates.controller(Predicates.blocks(definition.get())))
.where('B', Predicates.blocks('minecraft:end_stone').setMinGlobalLimited(20)
.or(Predicates.blocks('minecraft:black_concrete')))
.where('O', Predicates.blocks('minecraft:obsidian').setMinGlobalLimited(8)
.or(Predicates.air()))
.where('F', Predicates.frames('titanium'))
.where('Q', Predicates.blocks('ae2:quartz_glass'))
.where('E', Predicates.blocks('minecraft:dragon_egg'))
.where('S', Predicates.blocks('tfg:artificial_end_portal_frame'))
.where('N', Predicates.blocks('minecraft:black_concrete'))
.where('G', Predicates.blocks('tfc:ore/small_malachite')
.or(Predicates.blocks('tfc:ore/small_native_copper'))
.or(Predicates.blocks('tfc:ore/small_native_gold'))
.or(Predicates.blocks('tfc:ore/small_hematite'))
.or(Predicates.blocks('tfc:ore/small_native_silver'))
.or(Predicates.blocks('tfc:ore/small_cassiterite'))
.or(Predicates.blocks('tfc:ore/small_bismuthinite'))
.or(Predicates.blocks('tfc:ore/small_garnierite'))
.or(Predicates.blocks('tfc:ore/small_malachite'))
.or(Predicates.blocks('tfc:ore/small_magnetite'))
.or(Predicates.blocks('tfc:ore/small_limonite'))
.or(Predicates.blocks('tfc:ore/small_sphalerite'))
.or(Predicates.blocks('tfc:ore/small_tetrahedrite')))
.where('C', Predicates.blocks(GTBlocks.CASING_TITANIUM_STABLE.get()).setMinGlobalLimited(10)
.or(Predicates.autoAbilities(definition.getRecipeTypes()))
.or(Predicates.abilities(PartAbility.MAINTENANCE).setExactLimit(1)))
.where(' ', Predicates.any())
.build()
)
.shapeInfo(controller => MultiblockShapeInfo.builder()
.aisle(" CeCeC ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " F ", " ")
.aisle("CBBBBBC", "Q O Q", "Q O Q", "Q Q", "Q Q", " QSSSQ ", " 123 ")
.aisle("iBBBBBf", "QO OQ", "QO Q", "QO Q", "Q Q", " SNNNS ", " y 4 ")
.aisle("CBBBBBC", "F E F", "F F", "F F", "F F", "FSNNNSF", " z 5 ")
.aisle("tBBBBNl", "Q O Q", "Q O Q", "Q Q", "Q Q", " SNNNS ", " 0 6 ")
.aisle("CNBBNNC", "Q Q", "Q Q", "Q Q", "Q Q", " QSSSQ ", " 987 ")
.aisle(" mCXCC ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " QQFQQ ", " F ", " ")
.where('X', controller, Direction.SOUTH)
.where('C', GTBlocks.CASING_TITANIUM_STABLE.get())
.where('B', Block.getBlock('minecraft:end_stone'))
.where('N', Block.getBlock('minecraft:black_concrete'))
.where('O', Block.getBlock('minecraft:obsidian'))
.where('F', Block.getBlock('gtceu:titanium_frame'))
.where('Q', Block.getBlock('ae2:quartz_glass'))
.where(' ', Block.getBlock('minecraft:air'))
.where('S', Block.getBlock('tfg:artificial_end_portal_frame'))
.where('E', Block.getBlock('minecraft:dragon_egg'))
.where('1', Block.getBlock('tfc:ore/small_native_copper'))
.where('2', Block.getBlock('tfc:ore/small_native_gold'))
.where('3', Block.getBlock('tfc:ore/small_hematite'))
.where('4', Block.getBlock('tfc:ore/small_native_silver'))
.where('5', Block.getBlock('tfc:ore/small_cassiterite'))
.where('6', Block.getBlock('tfc:ore/small_bismuthinite'))
.where('7', Block.getBlock('tfc:ore/small_garnierite'))
.where('8', Block.getBlock('tfc:ore/small_malachite'))
.where('9', Block.getBlock('tfc:ore/small_magnetite'))
.where('0', Block.getBlock('tfc:ore/small_limonite'))
.where('z', Block.getBlock('tfc:ore/small_sphalerite'))
.where('y', Block.getBlock('tfc:ore/small_tetrahedrite'))
.where('m', GTMachines.MAINTENANCE_HATCH, Direction.SOUTH)
.where('i', GTMachines.ITEM_IMPORT_BUS[GTValues.ULV], Direction.WEST)
.where('t', GTMachines.ITEM_EXPORT_BUS[GTValues.ULV], Direction.WEST)
.where('f', GTMachines.FLUID_IMPORT_HATCH[GTValues.MV], Direction.EAST)
.where('l', GTMachines.FLUID_EXPORT_HATCH[GTValues.MV], Direction.EAST)
.where('e', GTMachines.ENERGY_INPUT_HATCH[GTValues.HV], Direction.NORTH)
.build()
)
.workableCasingModel(
"gtceu:block/casings/solid/machine_casing_stable_titanium",
"gtceu:block/machines/gas_collector")
//#endregion
//#region Steam Bloomery
event.create('steam_bloomery', 'multiblock')
.machine((holder) => new $SteamMulti(holder, 8))
.rotationState(RotationState.NON_Y_AXIS)
.recipeType('steam_bloomery')
.recipeModifier((machine, recipe) => $SteamMulti.recipeModifier(machine, recipe), true)
.appearanceBlock(GTBlocks.CASING_BRONZE_BRICKS)
.pattern(definition => FactoryBlockPattern.start()
.aisle(" F ", " C ", " E ", " E ", " E ")
.aisle("FCF", "C#C", "E#E", "E#E", "E#E")
.aisle(" F ", "CXC", " E ", " E ", " E ")
.where('X', Predicates.controller(Predicates.blocks(definition.get())))
.where('C', Predicates.blockTag($Tags.block("tfc:bloomery_insulation")))
.where('F', Predicates.blocks(GTBlocks.FIREBOX_BRONZE.get())
.or(Predicates.abilities(PartAbility.STEAM).setExactLimit(1)))
.where('E', Predicates.abilities(PartAbility.STEAM_IMPORT_ITEMS).setExactLimit(1)
.or(Predicates.abilities(PartAbility.STEAM_EXPORT_ITEMS).setExactLimit(1))
.or(Predicates.blockTag($Tags.block("tfc:bloomery_insulation"))))
.where('#', Predicates.air())
.where(' ', Predicates.any())
.build()
)
.shapeInfo(controller => MultiblockShapeInfo.builder()
.aisle(" F ", " C ", " C ", " C ", " C ")
.aisle("FCF", "C#C", "C#C", "C#C", "C#C")
.aisle(" i ", "CXC", " O ", " I ", " C ")
.where('X', controller, Direction.SOUTH)
.where('C', Block.getBlock('tfc:rock/bricks/rhyolite'))
.where('F', GTBlocks.FIREBOX_BRONZE.get())
.where('i', GTMachines.STEAM_HATCH, Direction.SOUTH)
.where('O', GTMachines.STEAM_EXPORT_BUS, Direction.SOUTH)
.where('I', GTMachines.STEAM_IMPORT_BUS, Direction.SOUTH)
.build()
)
.workableCasingModel(
"gtceu:block/casings/solid/machine_casing_bronze_plated_bricks",
"tfg:block/steam_bloomery")
//#endregion
event.create('large_solar_panel', 'multiblock')
.rotationState(RotationState.NON_Y_AXIS)
.generator(true)
.recipeType('large_solar_panel')
.noRecipeModifier()
.appearanceBlock(() => Block.getBlock('tfg:casings/machine_casing_iron_desh'))
.pattern(definition => FactoryBlockPattern.start()
.aisle(" B B ", " B B ", " CCCCC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " B B ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CCCCC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CC CC ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" CCC ", " CC CC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B CC CC B B ", " B C C B ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle("B B B", "B C C B", "C C", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" C FFF C B ", " C B B C ", "C B B C", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " EEE ", " GGG ", " GGG ", " GGG ")
.aisle(" C FIF C ", " C I C ", "C I C", " I ", " I ", " I ", " I ", " I ", " I ", " I ", " EIE ", " GIG ", " GKG ", " GGG ")
.aisle(" C FHF C ", " C B B C ", "C B B C", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " EEE ", " GGG ", " GGG ", " GGG ")
.aisle("B B B B", "B C C B", "C C", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B CC CC B B ", " B C C B ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" CCC ", " CC CC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CC CC ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CCCCC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " B B ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " B B ", " CCCCC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.where("H", Predicates.controller(Predicates.blocks(definition.get())))
.where("B", Predicates.blocks(ChemicalHelper.getBlock(TagPrefix.frameGt, GTMaterials.StainlessSteel)))
.where("C", Predicates.blocks("tfg:casings/machine_casing_red_solar_panel"))
.where("E", Predicates.blocks("ad_astra:iron_plateblock"))
.where("F", Predicates.blocks("tfg:casings/machine_casing_iron_desh")
.or(Predicates.autoAbilities(definition.getRecipeTypes()))
.or(Predicates.abilities(PartAbility.MAINTENANCE).setExactLimit(1))
)
.where("G", Predicates.blocks(GTBlocks.CASING_TEMPERED_GLASS.get()))
.where("I", Predicates.blocks("tfg:casings/machine_casing_iron_desh"))
.where("K", Predicates.blocks(ChemicalHelper.getBlock(TagPrefix.block, GTMaterials.Silver)))
.where(" ", Predicates.any())
.build()
)
.shapeInfo(controller => MultiblockShapeInfo.builder()
.aisle(" B B ", " B B ", " CCCCC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " B B ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CCCCC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CC CC ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" CCC ", " CC CC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B CC CC B B ", " B C C B ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle("B B B", "B C C B", "C C", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" C INI C B ", " C B B C ", "C B B C", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " EEE ", " GGG ", " GGG ", " GGG ")
.aisle(" C AIJ C ", " C I C ", "C I C", " I ", " I ", " I ", " I ", " I ", " I ", " I ", " EIE ", " GIG ", " GKG ", " GGG ")
.aisle(" C DHL C ", " C B B C ", "C B B C", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " B B ", " EEE ", " GGG ", " GGG ", " GGG ")
.aisle("B B B B", "B C C B", "C C", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B CC CC B B ", " B C C B ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" CCC ", " CC CC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CC CC ", " C C ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " CCCCC ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " B B ", " CC CC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.aisle(" B B ", " B B ", " CCCCC ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ", " ")
.where("H", controller, Direction.SOUTH)
.where("B", Block.getBlock("gtceu:stainless_steel_frame"))
.where("C", Block.getBlock("tfg:casings/machine_casing_red_solar_panel"))
.where("E", Block.getBlock("ad_astra:iron_plateblock"))
.where("A", GTMachines.ITEM_IMPORT_BUS[GTValues.ULV], Direction.WEST)
.where("D", GTMachines.MAINTENANCE_HATCH, Direction.SOUTH)
.where("J", GTMachines.FLUID_IMPORT_HATCH[GTValues.MV], Direction.EAST)
.where("L", GTMachines.FLUID_EXPORT_HATCH[GTValues.MV], Direction.EAST)
.where("N", GTMachines.ENERGY_OUTPUT_HATCH[GTValues.HV], Direction.NORTH)
.where("G", Block.getBlock("gtceu:tempered_glass"))
.where("I", Block.getBlock("tfg:casings/machine_casing_iron_desh"))
.where("K", Block.getBlock("gtceu:silver_block"))
.build()
)
.workableCasingModel('tfg:block/casings/machine_casing_iron_desh', 'gtceu:block/multiblock/hpca')
}