Added mod files

This commit is contained in:
Jacob Vinding
2025-12-26 21:38:55 +01:00
parent 64c4d60c47
commit c4ad0f3e2e
5039 changed files with 894558 additions and 0 deletions

View File

@@ -0,0 +1,157 @@
ServerEvents.recipes(event => {
let alchemy_mix = (output, catalyst, r1, r2, amount) => {
event.recipes.create.mixing([Item.of("kubejs:substrate_" + output, amount ? amount : 1), Item.of("kubejs:substrate_" + catalyst)], [Item.of("kubejs:substrate_" + catalyst), Item.of("kubejs:substrate_" + r1, 2), Item.of("kubejs:substrate_" + r2)]).heated()
}
let alchemy_smelt = (output, catalyst, r1, r2, amount) => {
event.recipes.thermal.smelter([Item.of(Item.of("kubejs:substrate_" + output, amount ? amount : 1)), Item.of("kubejs:substrate_" + catalyst)], [Item.of("kubejs:substrate_" + r1, 2), Item.of("kubejs:substrate_" + catalyst), Item.of("kubejs:substrate_" + r2)], 0, 6400)
}
alchemy_mix("red", "herbal", "diorite", "andesite")
alchemy_mix("orange", "herbal", "granite", "diorite")
alchemy_mix("yellow", "herbal", "cobblestone", "granite")
alchemy_mix("green", "herbal", "basalt", "cobblestone")
alchemy_mix("blue", "herbal", "scoria", "basalt")
alchemy_mix("magenta", "herbal", "andesite", "scoria")
alchemy_smelt("nether", "volatile", "red", "scoria")
alchemy_smelt("blaze", "volatile", "orange", "andesite")
alchemy_smelt("gunpowder", "volatile", "yellow", "diorite")
alchemy_smelt("slime", "volatile", "green", "granite")
alchemy_smelt("prismarine", "volatile", "blue", "cobblestone")
alchemy_smelt("obsidian", "volatile", "magenta", "basalt")
alchemy_mix("fluix", "crystal", "nether", "magenta")
alchemy_mix("niter", "crystal", "blaze", "red")
alchemy_mix("quartz", "crystal", "gunpowder", "orange")
alchemy_mix("sulfur", "crystal", "slime", "yellow")
alchemy_mix("apatite", "crystal", "prismarine", "green")
alchemy_mix("certus", "crystal", "obsidian", "blue")
alchemy_smelt("lead", "metal", "fluix", "obsidian")
alchemy_smelt("copper", "metal", "niter", "nether")
alchemy_smelt("gold", "metal", "quartz", "blaze")
alchemy_smelt("nickel", "metal", "sulfur", "gunpowder")
alchemy_smelt("zinc", "metal", "apatite", "slime")
alchemy_smelt("iron", "metal", "certus", "prismarine")
alchemy_smelt("andesite", "igneous", "emerald", "iron", 20)
alchemy_smelt("diorite", "igneous", "sapphire", "lead", 20)
alchemy_smelt("granite", "igneous", "diamond", "copper", 20)
alchemy_smelt("cobblestone", "igneous", "lapis", "gold", 20)
alchemy_smelt("basalt", "igneous", "ruby", "nickel", 20)
alchemy_smelt("scoria", "igneous", "cinnabar", "zinc", 20)
let mundane = (id, outputs) => {
let jsonOut = []
if (outputs[0] > 0)
jsonOut.push({
"item": "supplementaries:ash",
"count": outputs[0]
})
if (outputs[1] > 0)
jsonOut.push({
"item": "minecraft:redstone",
"count": outputs[1]
})
if (outputs[2] > 0)
jsonOut.push({
"item": "minecraft:glowstone_dust",
"count": outputs[2]
})
event.custom({
"type": "thermal:centrifuge",
"ingredient": {
"item": `kubejs:failed_alchemy_${id}`
},
"result": jsonOut
})
}
let i = 0;
mundane(i++, [4, 0, 0])
mundane(i++, [3, 1, 0])
mundane(i++, [3, 0, 1])
mundane(i++, [2, 2, 0])
mundane(i++, [2, 0, 2])
mundane(i++, [2, 1, 1])
mundane(i++, [1, 3, 0])
mundane(i++, [1, 0, 3])
mundane(i++, [1, 2, 1])
mundane(i++, [1, 1, 2])
mundane(i++, [0, 4, 0])
mundane(i++, [0, 0, 4])
mundane(i++, [0, 3, 1])
mundane(i++, [0, 1, 3])
mundane(i++, [0, 2, 2])
// Subtrate bottling and extracting
event.remove({ type: "thermal:sawmill" })
event.remove({ type: "thermal:centrifuge" })
global.substrates.forEach(a => {
a.forEach(e => {
if (!e.ingredient)
return
event.custom({
"type": "thermal:bottler",
"ingredients": [Ingredient.of(e.ingredient).toJson(), { "fluid": "tconstruct:molten_glass", "amount": 100 }],
"result": [{ "item": e.id }]
})
event.custom({
"type": "thermal:sawmill",
"ingredient": { "item": e.id },
"result": [{ "item": e.outputItem ? e.outputItem : typeof e.ingredient == "string" ? e.ingredient : e.ingredient[0], "chance": 0.75 }],
"energy": 2000
})
})
})
// Silicon and silver special cases
event.custom({
"type": "thermal:sawmill",
"ingredient": { "item": "kubejs:substrate_silicon" },
"result": [{ "item": "ae2:silicon", "count": 1 }],
"energy": 2000
})
event.custom({
"type": "thermal:sawmill",
"ingredient": { "item": "kubejs:substrate_silver" },
"result": [{ "item": "thermal:silver_dust", "count": 1 }],
"energy": 2000
})
// Accelerators
event.custom({
"type": "thermal:bottler",
"ingredients": [
{ "item": "thermal:signalum_nugget" },
{ "fluid": "tconstruct:molten_glass", "amount": 100 }
],
"result": [{ "item": "kubejs:accellerator_redstone" }]
})
event.custom({
"type": "thermal:bottler",
"ingredients": [
{ "item": "thermal:lumium_nugget" },
{ "fluid": "tconstruct:molten_glass", "amount": 100 }
],
"result": [{ "item": "kubejs:accellerator_glowstone" }]
})
// Not sure why silver subtrate has a recipe
event.custom({
"type": "thermal:bottler",
"ingredients": [
{ "item": "thermal:silver_dust" },
{ "fluid": "tconstruct:molten_glass", "amount": 100 }
],
"result": [{ "item": "kubejs:substrate_silver" }]
})
})

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,31 @@
ServerEvents.recipes(event => {
let stone = Item.of("minecraft:cobblestone", 1).withChance(.5)
let experience = Item.of("create:experience_nugget", 1).withChance(0.75)
event.recipes.create.crushing([Item.of("thermal:sapphire", 2), Item.of("thermal:sapphire", 1).withChance(.25), experience,stone], "thermal:sapphire_ore")
event.recipes.create.crushing([Item.of("thermal:ruby", 2), Item.of("thermal:ruby", 1).withChance(.25), experience,stone], "thermal:ruby_ore")
event.recipes.create.milling(Item.of("minecraft:redstone", 4), "thermal:cinnabar").processingTime(700)
event.recipes.create.crushing(Item.of("minecraft:redstone", 6), "thermal:cinnabar").processingTime(500)
event.remove({ id: "thermal:machines/pulverizer/pulverizer_cinnabar" })
event.recipes.thermal.pulverizer(Item.of("minecraft:redstone", 8), "thermal:cinnabar", 0, 10000)
event.recipes.create.milling("thermal:sulfur_dust", "#forge:gems/sulfur").processingTime(500)
event.recipes.create.milling("thermal:niter_dust", "#forge:gems/niter").processingTime(500)
event.recipes.create.milling("thermal:apatite_dust", "#forge:gems/apatite").processingTime(500)
// recompacting gem dusts into their gem form
let recompact = (id, id2) => {
event.recipes.create.compacting(id2, [id])
}
recompact("#forge:dusts/obsidian", "minecraft:obsidian")
recompact("#forge:dusts/diamond", "minecraft:diamond")
recompact("#forge:dusts/emerald", "minecraft:emerald")
recompact("#forge:dusts/lapis", "minecraft:lapis_lazuli")
recompact("#forge:dusts/sulfur", "thermal:sulfur")
recompact("#forge:dusts/apatite", "thermal:apatite")
recompact("#forge:dusts/niter", "thermal:niter")
recompact("#forge:dusts/sapphire", "thermal:sapphire")
recompact("#forge:dusts/ruby", "thermal:ruby")
recompact("#forge:dusts/quartz", "minecraft:quartz")
})

View File

@@ -0,0 +1,31 @@
ServerEvents.recipes(event => {
let illusion = (input) => {
const output = `kubejs:trial_${input.replace(/^minecraft:|^trials:/, "")}`;
event.custom({
"type": "create:filling",
"ingredients": [
{ "item": input },
{ "fluid": "supplementaries:lumisene", "amount": 90 }
],
"results": [
{ "item": `9x ${output}` }
]
})
}
illusion("minecraft:copper_block");
illusion("minecraft:cut_copper");
illusion("minecraft:cut_copper_stairs");
illusion("minecraft:cut_copper_slab");
illusion("minecraft:oxidized_copper");
illusion("minecraft:oxidized_cut_copper_stairs");
illusion("minecraft:oxidized_cut_copper_slab");
illusion("minecraft:oxidized_cut_copper");
if (Platform.isLoaded("trials")) {
illusion("trials:chiseled_copper");
illusion("trials:copper_grate");
illusion("trials:chiseled_copper_oxidized");
illusion("trials:copper_grate_oxidized");
}
})

View File

@@ -0,0 +1,458 @@
// priority: 10
// This script is important and needs to run early on.
// Redstone, silver and tin do not exist in A&B and we need a bit of scripting to remove them
ServerEvents.recipes(event => {
event.remove({ output: "#forge:nuggets/tin" })
event.remove({ output: "#forge:ingots/tin" })
event.remove({ output: "#forge:storage_blocks/tin" })
event.remove({ output: "#forge:plates/tin" })
event.remove({ output: "#forge:gears/tin" })
// metal replacements
const replacementFilter = [{ mod:"thermal", type:"minecraft:crafting_shaped"}, { mod:"thermal", type:"minecraft:crafting_shapeless"}, { mod:"exchangers", type:"minecraft:crafting_shaped"}]
event.replaceInput(replacementFilter, "#forge:ingots/tin", "#forge:ingots/zinc")
event.replaceInput(replacementFilter, "#forge:gears/tin", "#forge:gears/lead")
event.replaceInput(replacementFilter, "#forge:plates/bronze", "#forge:plates/nickel")
event.replaceInput(replacementFilter, "#forge:gears/bronze", "#forge:gears/nickel")
event.replaceInput(replacementFilter, "#forge:plates/silver", "#forge:ingots/invar")
event.replaceInput(replacementFilter, "#forge:gears/silver", "#forge:gears/invar")
event.replaceInput(replacementFilter, "#forge:plates/constantan", "#forge:plates/signalum")
event.replaceInput(replacementFilter, "#forge:gears/constantan", "#forge:gears/signalum")
event.replaceInput(replacementFilter, "#forge:ingots/electrum", "#forge:ingots/constantan")
event.replaceInput(replacementFilter, "#forge:plates/electrum", "#forge:plates/constantan")
event.replaceInput(replacementFilter, "#forge:gears/electrum", "#forge:gears/constantan")
event.replaceInput(replacementFilter, "#forge:plates/invar", "#forge:ingots/invar")
// // fix recipes broken by replacement
event.replaceInput({ id: "thermal:storage/electrum_nugget_from_ingot" }, "thermal:constantan_ingot", "#forge:ingots/electrum")
event.replaceInput({ id: "thermal:storage/electrum_block" }, "thermal:constantan_ingot", "#forge:ingots/electrum")
event.replaceInput({ id: "thermal:parts/electrum_gear" }, "thermal:constantan_ingot", "#forge:ingots/electrum")
event.replaceInput({ id: "thermal:storage/electrum_ingot_from_block"}, "thermal:electrum_block", "#forge:storage_blocks/electrum")
// Redstone exists in jei to provide a tooltip, we want to remove all of its recipes
event.remove({ input: "#forge:ores/redstone" })
})
// Tweaks for the metals that we actually want
ServerEvents.recipes(event => {
// Thermal recipes for zinc
event.recipes.thermal.pulverizer(["kubejs:zinc_dust"], "#forge:ingots/zinc", 0, 2000)
event.recipes.thermal.pulverizer(["kubejs:zinc_dust"], "#forge:plates/zinc", 0, 2000)
event.recipes.thermal.smelter(["create:zinc_ingot"], "#forge:plates/zinc", 0, 1600)
// Thermal's fire charge ingot crafting recipes. We don't want them
event.remove({ id: "thermal:fire_charge/invar_ingot_3" })
event.remove({ id: "thermal:fire_charge/enderium_ingot_2" })
event.remove({ id: "thermal:fire_charge/constantan_ingot_2" })
event.remove({ id: "thermal:fire_charge/bronze_ingot_4" })
event.remove({ id: "thermal:fire_charge/electrum_ingot_2" })
event.remove({ id: "thermal:fire_charge/lumium_ingot_4" })
event.remove({ id: "thermal:fire_charge/signalum_ingot_4" })
// Duplicate Recipes
event.remove({ id: "thermal:storage/silver_block"})
event.remove({ id: "thermal:storage/silver_ingot_from_block"})
event.remove({ id: "thermal:storage/silver_ingot_from_nuggets"})
event.remove({ id: "thermal:storage/silver_nugget_from_ingot"})
event.remove({ id: "thermal:smelting/silver_ingot_from_dust_smelting"})
event.remove({ id: "thermal:smelting/silver_ingot_from_dust_blasting"})
event.remove({ id: "thermal:storage/copper_nugget_from_ingot"})
event.remove({ id: "tconstruct:common/materials/copper_nugget_from_ingot"})
event.remove({ id: "thermal:storage/copper_ingot_from_nuggets"})
event.remove({ id: "tconstruct:common/materials/copper_ingot_from_nuggets"})
event.remove({ id: "thermal:storage/netherite_nugget_from_ingot"})
event.remove({ id: "tconstruct:common/materials/netherite_nugget_from_ingot"})
event.remove({ id: "thermal:storage/netherite_ingot_from_nuggets"})
event.remove({ id: "tconstruct:common/materials/netherite_ingot_from_nuggets"})
// Remove unwanted Alloying recipes
event.remove({ id: "create:mixing/brass_ingot" })
event.remove({id: /centrifuge_bronze_dust/})
// smeltery
event.remove({ id: "tconstruct:smeltery/alloys/molten_bronze" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_brass" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_invar" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_electrum" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_constantan" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_rose_gold" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_enderium" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_lumium" })
event.remove({ id: "tconstruct:smeltery/alloys/molten_signalum" })
// alloy smelter
event.remove({ id: "thermal:machines/smelter/smelter_alloy_signalum" })
event.remove({ id: "thermal:machines/smelter/smelter_alloy_lumium" })
event.remove({ id: "thermal:machines/smelter/smelter_alloy_enderium" })
event.remove({ id: "thermal:machines/smelter/smelter_alloy_invar" })
event.remove({ id: "thermal:machines/smelter/smelter_alloy_bronze" })
event.remove({ id: "thermal:compat/create/smelter_create_alloy_brass" })
event.remove({ id: "thermal:compat/tconstruct/smelter_alloy_tconstruct_rose_gold_ingot" })
// thermal handcrafting
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:constantan_dust" })
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:electrum_dust" })
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:lumium_dust" })
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:signalum_dust" })
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:enderium_dust" })
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:bronze_dust" })
event.remove({ type: "minecraft:crafting_shapeless", output: "thermal:invar_dust" })
// Create new alloying recipes
// Mixing Alloys
let moltenAlloy = function (fluidAlloy, fluid1, fluid2) {
// Recipe ids are actually important here since the id that comes later in alphabetical order is the one that is prioritized
event.custom({
"type": "create:mixing",
"ingredients": [
{ "amount": 2, "fluid": fluid1 },
{ "amount": 2, "fluid": fluid2 }
],
"results": [
{ "amount": 2, "fluid": "tconstruct:" + fluidAlloy }
],
processingTime: 1
}).id(`kubejs:mixing/${fluidAlloy}_2`)
}
moltenAlloy("molten_brass", "tconstruct:molten_copper", "tconstruct:molten_zinc")
moltenAlloy("molten_constantan", "tconstruct:molten_copper", "tconstruct:molten_nickel")
moltenAlloy("molten_rose_gold", "tconstruct:molten_copper", "tconstruct:molten_gold")
moltenAlloy("molten_electrum", "tconstruct:molten_silver", "tconstruct:molten_gold")
// remove existing smelter recipes because they accept dusts
event.remove({ id: "thermal:machines/smelter/smelter_alloy_constantan"})
event.remove({ id: "thermal:machines/smelter/smelter_alloy_electrum"})
event.remove({ id: "thermal:machines/smelter/smelter_alloy_netherite"})
// alloy smelter recipes
event.recipes.thermal.smelter(Item.of("create:brass_ingot", 2), ["#forge:ingots/copper", "#forge:ingots/zinc"])
event.recipes.thermal.smelter(Item.of("tconstruct:rose_gold_ingot", 2), ["#forge:ingots/copper", "#forge:ingots/gold"])
event.recipes.thermal.smelter(Item.of("thermal:constantan_ingot", 2), ["#forge:ingots/copper", "#forge:ingots/nickel"])
event.recipes.thermal.smelter(Item.of(getPreferredItemFromTag("forge:ingots/electrum"), 2), ["#forge:ingots/silver", "#forge:ingots/gold"])
event.recipes.thermal.smelter(Item.of("minecraft:netherite_ingot", 1), [Item.of("#forge:ingots/netherite_scrap", 4), Item.of("#forge:ingots/gold", 4)])
// bronze
event.recipes.thermal.smelter("3x thermal:bronze_ingot", [Item.of("minecraft:copper_ingot", 3), "#forge:sand"])
// Nickel Compound
event.shapeless("kubejs:nickel_compound", ["thermal:nickel_ingot", "thermal:iron_dust", "thermal:iron_dust", "thermal:iron_dust", "thermal:iron_dust"])
event.recipes.thermal.smelter(["kubejs:invar_compound", "kubejs:invar_compound"], ["thermal:nickel_ingot", "minecraft:iron_ingot"])
// Invar Compound
event.blasting("kubejs:invar_compound", "kubejs:nickel_compound")
{ // Invar ingots
let s = "kubejs:invar_compound"
event.recipes.create.sequenced_assembly([
"thermal:invar_ingot",
], "kubejs:invar_compound", [
event.recipes.create.pressing(s, s)
]).transitionalItem(s)
.loops(16)
.id("kubejs:invar")
}
// smeltery alloys
event.custom({
"type": "tconstruct:alloy",
"inputs": [
{ "name": "tconstruct:molten_silver", "amount": 90 },
{ "name": "tconstruct:molten_copper", "amount": 90 },
{ "name": "thermal:redstone", "amount": 1000 }
],
"result": {
"fluid": "tconstruct:molten_signalum",
"amount": 90
},
"temperature": 1000
})
event.custom({
"type": "tconstruct:alloy",
"inputs": [
{ "name": "tconstruct:molten_silver", "amount": 90 },
{ "name": "tconstruct:molten_copper", "amount": 90 },
{ "name": "thermal:glowstone", "amount": 1000 }
],
"result": {
"fluid": "tconstruct:molten_lumium",
"amount": 90
},
"temperature": 1000
})
event.custom({
"type": "tconstruct:alloy",
"inputs": [
{ "name": "tconstruct:molten_copper", "amount": 270 },
{ "name": "tconstruct:molten_glass", "amount": 1000 }
],
"result": {
"fluid": "tconstruct:molten_bronze",
"amount": 270
},
"temperature": 1000
})
// Thermal alloys
event.custom({
"type": "thermal:refinery",
"ingredient": {
"fluid": "thermal:glowstone",
"amount": 1000
},
"result": [
{
"item": "thermal:lumium_ingot"
}
],
"energy": 2000
})
event.custom({
"type": "thermal:refinery",
"ingredient": {
"fluid": "thermal:redstone",
"amount": 1000
},
"result": [
{
"item": "thermal:signalum_ingot"
}
],
"energy": 2000
})
// Plates
event.recipes.create.pressing(["thermal:lead_plate"], "thermal:lead_ingot")
event.recipes.create.pressing(["thermal:constantan_plate"], "thermal:constantan_ingot")
event.recipes.create.pressing(["thermal:nickel_plate"], "thermal:nickel_ingot")
event.recipes.create.pressing(["thermal:signalum_plate"], "thermal:signalum_ingot")
event.recipes.create.pressing(["thermal:lumium_plate"], "thermal:lumium_ingot")
event.recipes.create.pressing(["thermal:enderium_plate"], "thermal:enderium_ingot")
// dusts
event.recipes.create.milling("thermal:iron_dust", "#forge:ingots/iron")
event.recipes.create.milling("thermal:gold_dust", "#forge:ingots/gold")
event.recipes.create.milling("thermal:nickel_dust", "#forge:ingots/nickel")
event.recipes.create.milling("thermal:lead_dust", "#forge:ingots/lead")
event.recipes.create.milling("thermal:copper_dust", "#forge:ingots/copper")
event.recipes.create.milling("kubejs:zinc_dust", "#forge:ingots/zinc")
// other metal unification
event.replaceOutput({}, "#forge:ingots/silver", "thermal:silver_ingot")
event.replaceOutput({}, "#forge:ingots/bronze", "thermal:bronze_ingot")
event.replaceOutput({ id:"occultism:crafting/silver_block"}, "#forge:storage_blocks/silver", "thermal:silver_block")
// Ore processing
event.remove({ id: /thermal:machines\/smelter\/.*dust/ })
event.remove({ id: /tconstruct:smeltery\/.*\/ore/ })
event.remove({ input: "#create:crushed_raw_materials" })
native_metals.forEach(e => {
event.remove({ type: "minecraft:smelting", input: "#forge:dusts/" + e })
event.remove({ type: "minecraft:blasting", input: "#forge:dusts/" + e })
event.remove({ type: "tconstruct:melting", input: "#forge:dusts/" + e })
})
event.remove({ id: "thermal:smelting/silver_ingot_from_dust_smelting"})
event.remove({ id: "thermal:smelting/silver_ingot_from_dust_blasting"})
const stone = Item.of("minecraft:cobblestone", 1).withChance(.5)
let experience = Item.of("create:experience_nugget", 1).withChance(0.75)
let dust_process = (materialName, byproduct, ByproductName) => {
let crushedOre = "create:crushed_" + "raw_" + materialName
let oreTag = ("#forge:ores/" + materialName)
let crushedOreBlockTag = ("#forge:storage_blocks/raw_" + materialName)
let dustTag = ("#forge:dusts/" + materialName)
let fluid = "tconstruct:molten_" + materialName
let fluidByproduct = "tconstruct:molten_" + ByproductName
let rawOreTag = ("#forge:raw_materials/" + materialName)
// slightly slower than passing the name directly but it reduces how many parameters this function needs.
let ingot = getPreferredItemFromTag("forge:ingots/" + materialName);
let nugget = getPreferredItemFromTag("forge:nuggets/" + materialName);
let nuggetByproduct = getPreferredItemFromTag("forge:nuggets/" + ByproductName);
let dust = getPreferredItemFromTag("forge:dusts/" + materialName);
// raw ore block compression and decompression
event.replaceInput({type: "minecraft:crafting_shaped"}, rawOreTag, crushedOre)
event.replaceOutput({type: "minecraft:crafting_shapeless"}, rawOreTag, crushedOre)
event.remove([
{ type: "minecraft:smelting", input: rawOreTag },
{ type: "minecraft:blasting", input: rawOreTag },
{ type: "create:crushing", input: rawOreTag },
{ type: "occultism:crushing", input: rawOreTag },
{ type: "tconstruct:ore_melting", input: rawOreTag }
])
event.remove({ id: `thermal:machines/pulverizer/pulverizer_raw_${materialName}`})
event.remove({ id: `thermal:machines/smelter/smelter_raw_${materialName}`})
event.remove([
{ type: "thermal:smelter", input: oreTag },
{ type: "thermal:pulverizer", input: oreTag },
{ type: "minecraft:blasting", input: oreTag },
{ type: "minecraft:smelting", input: oreTag },
{ type: "create:crushing", input: oreTag },
{ type: "create:milling", input: oreTag },
{ type: "occultism:crushing", input: oreTag },
])
event.remove({ id: `thermal:machines/pulverizer/pulverizer_${materialName}_ore` })
event.remove({ id: `thermal:machines/smelter/smelter_${materialName}_ore` })
event.remove([
{ type: "minecraft:smelting", input: crushedOreBlockTag },
{ type: "minecraft:blasting", input: crushedOreBlockTag },
{ type: "create:crushing", input: crushedOreBlockTag },
{ type: "occultism:crushing", input: crushedOreBlockTag },
{ type: "tconstruct:ore_melting", input: crushedOreBlockTag }
])
// 'concentrated ore' to crushed ore
event.recipes.create.milling([Item.of(crushedOre, 5)], rawOreTag).id("kubejs:ore_processing/milling/raw_ore/" + materialName)
event.recipes.create.crushing([Item.of(crushedOre, 5), Item.of(crushedOre, 2).withChance(0.5)], rawOreTag).id("kubejs:ore_processing/crushing/raw_ore/" + materialName)
// ore to crushed ore
event.recipes.create.crushing([Item.of(crushedOre, 3), Item.of(crushedOre, 1).withChance(0.5), experience, stone], oreTag).id("kubejs:ore_processing/crushing/ore/" + materialName)
event.recipes.thermal.pulverizer([Item.of(crushedOre).withChance(4.5), Item.of("minecraft:gravel").withChance(0.2)], oreTag, 0.2).id("kubejs:ore_processing/pulverizing/ore/" + materialName)
event.recipes.occultism.crushing(Item.of(dust, 3), Item.of(crushedOre), 200, -1, false).id(`kubejs:occultism/crushing/${materialName}`)
// crushed ore to nuggets
event.smelting(Item.of(nugget, 3), crushedOre).id("kubejs:ore_processing/smelting/crushed/" + materialName)
event.recipes.create.splashing([Item.of(nugget, 2), Item.of(nuggetByproduct, 1).withChance(0.85)], dustTag).id("kubejs:ore_processing/splashing/dust/" + materialName)
// crushed ore to ore dust
event.recipes.create.milling([Item.of(dust, 3)], crushedOre).id("kubejs:ore_processing/milling/crushed/" + materialName)
event.recipes.create.crushing([Item.of(dust, 3), Item.of(dust, 3).withChance(0.5)], crushedOre).id("kubejs:ore_processing/crushing/crushed/" + materialName)
event.recipes.thermal.pulverizer([Item.of(dust, 6)], crushedOre, 0.2, 6400).id("kubejs:ore_processing/pulverizing/crushed/" + materialName)
// ore dust to nuggets
event.smelting(Item.of(nugget, 1), dustTag).cookingTime(40).id("kubejs:ore_processing/smelting/dust/" + materialName)
// ore dust to fluid
event.recipes.thermal.crucible(Fluid.of(fluid, 30), dustTag, 0, 3000).id("kubejs:ore_processing/crucible/dust/" + materialName)
event.recipes.create.mixing([Fluid.of(fluid, 180)], [Item.of(dustTag, 3), "ae2:matter_ball"]).superheated().id("kubejs:ore_processing/mixing/dust/" + materialName)
// ingots to fluid
// event.recipes.thermal.crucible(Fluid.of(fluid, 90), ingot, 2000).id('kubejs:ore_processing/crucible/ingot/'+materialName) //now automatically ported
// melting crushed ores to nuggets
event.custom({
"type": "thermal:smelter",
"ingredient": { "item": crushedOre },
"result": [
{ "item": nugget, "chance": 9.0 },
{ "item": byproduct, "chance": (byproduct.endsWith("nugget") ? 1.8 : 0.2) },
{ "item": "thermal:rich_slag", "chance": 0.2 }
],
"experience": 0.2,
"energy": 3200
}).id("kubejs:ore_processing/induction_smelting/crushed/" + materialName)
// melting ore dusts to fluid
event.custom({
"type": "tconstruct:melting",
"ingredient": { "tag": dustTag.slice(1) },
"result": { "fluid": fluid, "amount": 30 },
"temperature": 500,
"time": 30,
"byproducts": [{ "fluid": fluidByproduct, "amount": 10 }]
}).id("kubejs:ore_processing/melting/dust/" + materialName);
}
dust_process("nickel", "create:copper_nugget", "copper")
dust_process("lead", "minecraft:iron_nugget", "iron")
dust_process("iron", "thermal:nickel_nugget", "nickel")
dust_process("gold", "thermal:cinnabar", "zinc")
dust_process("copper", "minecraft:gold_nugget", "gold")
dust_process("zinc", "thermal:sulfur", "lead")
event.remove([
{ type: "minecraft:crafting_shaped", input: "#forge:raw_materials/silver" },
{ type: "minecraft:crafting_shapeless", input: "#forge:raw_materials/silver" },
{ type: "minecraft:smelting", input: "#forge:raw_materials/silver" },
{ type: "minecraft:blasting", input: "#forge:raw_materials/silver" },
{ type: "create:crushing", input: "#forge:raw_materials/silver" },
{ type: "occultism:crushing", input: "#forge:raw_materials/silver" },
{ type: "tconstruct:ore_melting", input: "#forge:raw_materials/silver" }
])
event.remove({ id: "thermal:machines/pulverizer/pulverizer_raw_silver"})
event.remove({ id: "thermal:machines/smelter/smelter_raw_silver"})
event.replaceInput({ id: "thermal:machine/smelter/smelter_iron_ore" }, "minecraft:iron_ore", "create:crushed_raw_iron")
event.replaceInput({ id: "thermal:machine/smelter/smelter_gold_ore" }, "minecraft:gold_ore", "create:crushed_raw_gold")
// Other Tweaks
event.custom({
"type": "tconstruct:ore_melting",
"ingredient": {
"tag": "forge:ores/cobalt"
},
"result": {
"fluid": "tconstruct:molten_cobalt",
"amount": 90
},
"temperature": 950,
"time": 97,
"rate": "metal",
"byproducts": [
{
"fluid": "tconstruct:molten_iron",
"amount": 30
}
]
})
event.custom({
"type": "tconstruct:ore_melting",
"ingredient": {
"tag": "forge:ores/netherite_scrap"
},
"result": {
"fluid": "tconstruct:molten_debris",
"amount": 90
},
"temperature": 1175,
"time": 143,
"rate": "metal",
"byproducts": [
{
"fluid": "tconstruct:molten_diamond",
"amount": 25
},
{
"fluid": "tconstruct:molten_gold",
"amount": 90
}
]
})
// metal recycling
event.custom({
"type": "tconstruct:melting",
"ingredient": { "tag": "kubejs:recycling/iron" },
"result": {
"fluid": "tconstruct:molten_iron",
"amount": 30
},
"temperature": 500,
"time": 40
})
event.custom({
"type": "tconstruct:melting",
"ingredient": { "tag": "kubejs:circuit_press" },
"result": {
"fluid": "tconstruct:molten_invar",
"amount": 180
},
"temperature": 500,
"time": 90
})
})

View File

@@ -0,0 +1,9 @@
ServerEvents.recipes(event => {
event.shaped("minecraft:bundle", [
"S",
"L"
], {
S: "minecraft:string",
L: "minecraft:leather",
})
})

View File

@@ -0,0 +1,40 @@
ServerEvents.recipes(event => {
// phantom membrane replacements
if (Platform.isLoaded("railways")) {
event.recipes.create.filling("railways:track_phantom", ["create:track", Fluid.of("create:potion", 50, '{Potion:"minecraft:invisibility"}')])
event.recipes.create.filling("railways:track_phantom", ["create:track", Fluid.of("create:potion", 50, '{Potion:"minecraft:long_invisibility"}')])
event.recipes.create.filling("railways:track_phantom", ["create:track", Fluid.of("cofh_core:potion", 50, '{Potion:"minecraft:invisibility"}')])
event.recipes.create.filling("railways:track_phantom", ["create:track", Fluid.of("cofh_core:potion", 50, '{Potion:"minecraft:long_invisibility"}')])
}
if (Platform.isLoaded("moreminecarts")) {
event.replaceInput({}, "minecraft:phantom_membrane", "thermal:blitz_powder")
event.recipes.create.crushing([Item.of("moreminecarts:levitation_powder"), Item.of("moreminecarts:levitation_powder", 1).withChance(.5)], "thermal:blitz_powder")
}
// alternate double jump recipe
event.custom({
"type": "tconstruct:modifier",
"inputs": [
{ "item": "minecraft:piston" },
{ "item": "tconstruct:sky_slime" },
{ "item": "minecraft:piston" },
{ "item": "trials:wind_charge" },
{ "item": "trials:wind_charge" }
],
"result": "tconstruct:double_jump",
"slots": {
"abilities": 1
},
"tools": {
"tag": "tconstruct:modifiable/armor/boots"
}
}).id("tconstruct:tools/modifiers/ability/double_jump")
// slow fall potion is in startup script potions.js
})
ServerEvents.loaded(event => {
if (!event.server.persistentData.insomniaDisabled) {
event.server.runCommandSilent("/gamerule doInsomnia false")
event.server.persistentData.insomniaDisabled = true;
}
})

View File

@@ -0,0 +1,44 @@
ServerEvents.recipes(event => {
event.remove({ input: "#forge:coins" })
event.recipes.thermal.numismatic_fuel("thermal:silver_coin", 100000)
event.recipes.thermal.numismatic_fuel("thermal:gold_coin", 6400000)
// remove all press recipes
event.remove({ type: "thermal:press" })
event.remove({ type: "thermal:numismatic_fuel" })
let trade = (card_id, ingredient, output) => {
event.custom({
type: "thermal:press",
ingredients: [
toThermalInputJson(ingredient),
toThermalInputJson(card_id),
],
result: [
toThermalOutputJson(output)
],
energy: 1000
})
}
global.trades.forEach(element => {
if (global.transactions[element])
global.transactions[element].forEach(transaction => {
if (!Item.of(transaction.in).isEmpty() && !Item.of(transaction.out).isEmpty()) {
trade("kubejs:trade_card_" + element, transaction.in, transaction.out)
} else console.warn(`tried to create trade, ${transaction.in} -> ${transaction.out}, but one of the items does not exist`)
})
});
global.professions.forEach(element => {
if (global.transactions[element])
global.transactions[element].forEach(transaction => {
if (!Item.of(transaction.in).isEmpty() && !Item.of(transaction.out).isEmpty()) {
trade("kubejs:profession_card_" + element, transaction.in, transaction.out)
} else console.warn(`tried to create trade, ${transaction.in} -> ${transaction.out}, but one of the items does not exist`)
})
});
trade("kubejs:missingno", "thermal:gold_coin", "128x supplementaries:candy")
})