Added mod files
This commit is contained in:
4
overrides/kubejs/server_scripts/_cabin_motd.js
Normal file
4
overrides/kubejs/server_scripts/_cabin_motd.js
Normal file
@@ -0,0 +1,4 @@
|
||||
PlayerEvents.loggedIn(event => {
|
||||
event.player.tell(["Welcome to ", Text.gold("CABIN"), " on 1.20"]);
|
||||
event.player.tell(["Report pack issues to ", Text.gold("the Github").underlined().clickOpenUrl("https://github.com/ThePansmith/CABIN").hover("Click to open"), "."]);
|
||||
})
|
||||
455
overrides/kubejs/server_scripts/_helper.js
Normal file
455
overrides/kubejs/server_scripts/_helper.js
Normal file
@@ -0,0 +1,455 @@
|
||||
// priority: 9999
|
||||
|
||||
// Java imports
|
||||
const Registry = Java.loadClass("net.minecraft.core.Registry"); // registries, needed for almost everything involving Java classes
|
||||
// const BlockPos = Java.loadClass('net.minecraft.core.BlockPos'); //Block position. For some reason we don't need to import this?
|
||||
const TagKey = Java.loadClass("net.minecraft.tags.TagKey");
|
||||
const AxisDirection = Java.loadClass("net.minecraft.core.Direction$AxisDirection");
|
||||
|
||||
const Random = Java.loadClass("java.util.Random")
|
||||
const InputItem = Java.loadClass("dev.latvian.mods.kubejs.item.InputItem")
|
||||
const OutputItem = Java.loadClass("dev.latvian.mods.kubejs.item.OutputItem")
|
||||
const InputFluid = Java.loadClass("dev.latvian.mods.kubejs.fluid.InputFluid")
|
||||
const OutputFluid = Java.loadClass("dev.latvian.mods.kubejs.fluid.OutputFluid")
|
||||
const FluidStackJS = Java.loadClass("dev.latvian.mods.kubejs.fluid.FluidStackJS")
|
||||
const JsonObject = Java.loadClass("com.google.gson.JsonObject")
|
||||
|
||||
const Level = Java.loadClass("net.minecraft.world.level.Level") // For some reason, Kubejs requires that you load this class to create explosions that damage blocks
|
||||
|
||||
const colours = ["white", "orange", "magenta", "light_blue", "lime", "pink", "purple", "light_gray", "gray", "cyan", "brown", "green", "blue", "red", "black", "yellow"]
|
||||
const native_metals = ["iron", "zinc", "lead", "copper", "nickel", "gold"]
|
||||
|
||||
const wood_types = ["minecraft:oak", "minecraft:spruce", "minecraft:birch", "minecraft:jungle", "minecraft:acacia", "minecraft:dark_oak", "minecraft:mangrove", "minecraft:cherry", "minecraft:crimson", "minecraft:warped"]
|
||||
|
||||
// None of the modded axes are registered for some reason
|
||||
const unregistered_axes = ["ae2:certus_quartz_axe", "ae2:nether_quartz_axe", "ae2:fluix_axe", "tconstruct:hand_axe", "tconstruct:mattock", "tconstruct:broad_axe", "thermal:flux_saw"]
|
||||
|
||||
const donutCraft = (event, output, center, ring) => {
|
||||
return event.shaped(output, [
|
||||
"SSS",
|
||||
"SCS",
|
||||
"SSS"
|
||||
], {
|
||||
C: center,
|
||||
S: ring
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Used to make smithing/mechanical crafting recipes which are common in A&B.
|
||||
* If the fourth parameter is excluded, then a stonecutting recipe will be created instead.
|
||||
*
|
||||
* First parmeter is the "base" ingredient,
|
||||
* third parameter is the output,
|
||||
* fourth parameter is the secondary ingredient.
|
||||
*
|
||||
* @param {ItemStackJS|string} machineItem
|
||||
* @param {RecipeEventJS} event
|
||||
* @param {ItemStackJS|string} outputIngredient
|
||||
* @param {ItemStackJS|string} inputIngredient
|
||||
*/
|
||||
// event is the second parameter so that machineItem doesn't look like it's the output item
|
||||
const createMachine = (machineItem, event, outputIngredient, inputIngredient) => {
|
||||
machineItem = Ingredient.of(machineItem)
|
||||
outputIngredient = Item.of(outputIngredient)
|
||||
|
||||
event.remove({ output: outputIngredient })
|
||||
if (inputIngredient) {
|
||||
inputIngredient = Ingredient.of(inputIngredient)
|
||||
event.custom({
|
||||
"type": "create:item_application",
|
||||
"ingredients": [
|
||||
machineItem.toJson(),
|
||||
inputIngredient.toJson()
|
||||
],
|
||||
|
||||
"results": (outputIngredient.isBlock() && outputIngredient.getCount() > 1) ?
|
||||
[
|
||||
|
||||
outputIngredient.withCount(1).toJson(),
|
||||
outputIngredient.withCount(outputIngredient.getCount() - 1).toJson()
|
||||
]
|
||||
:
|
||||
[
|
||||
outputIngredient.toJson()
|
||||
]
|
||||
|
||||
})
|
||||
}
|
||||
else
|
||||
event.stonecutting(outputIngredient, machineItem)
|
||||
}
|
||||
|
||||
const andesiteMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:andesite_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const copperMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:copper_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const goldMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:gold_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const brassMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:brass_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const zincMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:zinc_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const leadMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:lead_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
|
||||
const invarMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("thermal:machine_frame", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const enderiumMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("kubejs:enderium_machine", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const fluixMachine = (event, outputIngredient, inputIngredient) => {
|
||||
return createMachine("ae2:controller", event, outputIngredient, inputIngredient)
|
||||
}
|
||||
|
||||
const toThermalInputJson = (value) => {
|
||||
if (value instanceof InputFluid) {
|
||||
return (FluidStackJS.of(value)).toJson()
|
||||
}
|
||||
value = InputItem.of(value)
|
||||
if (value.count > 1) {
|
||||
let json = new JsonObject()
|
||||
json.add("value", value.ingredient.toJson())
|
||||
json.addProperty("count", value.count)
|
||||
return json
|
||||
} else {
|
||||
return value.ingredient.toJson();
|
||||
}
|
||||
}
|
||||
const toThermalOutputJson = (value) => {
|
||||
if (value instanceof OutputFluid) {
|
||||
return (FluidStackJS.of(value)).toJson();
|
||||
}
|
||||
value = OutputItem.of(value)
|
||||
let json = new JsonObject()
|
||||
json.addProperty("item", value.item.getId())
|
||||
json.addProperty("count", value.item.getCount())
|
||||
|
||||
if (value.getNbt() != null) {
|
||||
json.addProperty("nbt", value.getNbt().toString())
|
||||
}
|
||||
|
||||
if (value.hasChance()) {
|
||||
json.addProperty("chance", value.getChance())
|
||||
}
|
||||
|
||||
if (value.rolls != null) {
|
||||
json.addProperty("minRolls", value.rolls.getMinValue())
|
||||
json.addProperty("maxRolls", value.rolls.getMaxValue())
|
||||
}
|
||||
|
||||
return json;
|
||||
}
|
||||
|
||||
const addTreeOutput = (event, trunk, leaf, fluid) => {
|
||||
return event.custom({
|
||||
type: "thermal:tree_extractor",
|
||||
trunk: {
|
||||
Name: trunk,
|
||||
Properties: {
|
||||
axis: "y"
|
||||
}
|
||||
},
|
||||
leaves: {
|
||||
Name: leaf,
|
||||
Properties: {
|
||||
persistent: "false"
|
||||
}
|
||||
},
|
||||
// sapling: "minecraft:jungle_sapling",
|
||||
// min_height: 5,
|
||||
// max_height: 10,
|
||||
// min_leaves: 8,
|
||||
// max_leaves: 12,
|
||||
result: fluid ? toThermalOutputJson(fluid) : {
|
||||
fluid: "thermal:resin",
|
||||
amount: 25
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates smeltery casting recipes for nuggets, ingots, blocks, etc
|
||||
* Also creates a chilling recipe for the ingot
|
||||
* This helper function requires all the items and fluids involved to be tagged correctly with the nugget/ingot/block tags
|
||||
* @param {RecipeEventJS} event recipe event
|
||||
* @param {string} metalName the name of the metal to create casting recipes (ex: "forge:ingots/{metalName}")
|
||||
* @param {number} castingTime the time it takes to cast a block in a casting table (nugget and ingot casting times will be calculated based on that)
|
||||
*/
|
||||
const metalCasting = (event, metalName, castingTime) => {
|
||||
let fluidTag = "forge:molten_" + metalName
|
||||
|
||||
let blockTag = "forge:storage_blocks/" + metalName
|
||||
|
||||
// block casting
|
||||
if (Ingredient.of(`#forge:storage_blocks/${metalName}`).first != Item.empty) {
|
||||
event.custom({
|
||||
"type": "tconstruct:casting_basin",
|
||||
"fluid": {
|
||||
"tag": fluidTag,
|
||||
"amount": 810
|
||||
},
|
||||
"result": {"tag": blockTag},
|
||||
"cooling_time": castingTime
|
||||
}).id(`kubejs:smeltery/casting/metal/${metalName}/block`)
|
||||
}
|
||||
|
||||
let castTypes = [
|
||||
// {name: 'coin', fluidCost: 30, cooldownMultiplier: 1/(3*Math.sqrt(3))},
|
||||
{name: "gear", fluidCost: 360, cooldownMultiplier: 2 / 3},
|
||||
{name: "ingot", fluidCost: 90, cooldownMultiplier: 1 / 3},
|
||||
{name: "nugget", fluidCost: 10, cooldownMultiplier: 1 / 9},
|
||||
{name: "plate", fluidCost: 90, cooldownMultiplier: 1 / 3},
|
||||
{name: "rod", fluidCost: 45, cooldownMultiplier: 1 / (3 * Math.SQRT2)},
|
||||
{name: "wire", fluidCost: 45, cooldownMultiplier: 1 / (3 * Math.SQRT2)}
|
||||
]
|
||||
|
||||
// casting into casts
|
||||
castTypes.forEach(cast=>{
|
||||
if (Ingredient.of(`#forge:${cast.name}s/${metalName}`).first != Item.empty) {
|
||||
event.custom({
|
||||
"type": "tconstruct:casting_table",
|
||||
"cast": {
|
||||
"tag": `tconstruct:casts/multi_use/${cast.name}`
|
||||
},
|
||||
"fluid": {
|
||||
"tag": fluidTag,
|
||||
"amount": cast.fluidCost
|
||||
},
|
||||
"result": {"tag": `forge:${cast.name}s/${metalName}`},
|
||||
"cooling_time": Math.round(castingTime * cast.cooldownMultiplier)
|
||||
}).id(`kubejs:smeltery/casting/metal/${metalName}/${cast.name}_gold_cast`)
|
||||
|
||||
event.custom({
|
||||
"type": "tconstruct:casting_table",
|
||||
"cast": {
|
||||
"tag": `tconstruct:casts/single_use/${cast.name}`
|
||||
},
|
||||
"cast_consumed": true,
|
||||
"fluid": {
|
||||
"tag": fluidTag,
|
||||
"amount": cast.fluidCost
|
||||
},
|
||||
"result": {"tag": `forge:${cast.name}s/${metalName}`},
|
||||
"cooling_time": Math.round(castingTime * cast.cooldownMultiplier)
|
||||
}).id(`kubejs:smeltery/casting/metal/${metalName}/${cast.name}_sand_cast`)
|
||||
}
|
||||
})
|
||||
|
||||
// ingot chilling
|
||||
if (Ingredient.of(`#forge:ingots/${metalName}`).first != Item.empty) {
|
||||
event.custom({
|
||||
"type": "thermal:chiller",
|
||||
"ingredients": [{
|
||||
"fluid_tag": fluidTag,
|
||||
"amount": 90
|
||||
},{
|
||||
"item": "thermal:chiller_ingot_cast"
|
||||
}],
|
||||
"result": [{
|
||||
"item": getPreferredItemFromTag("forge:ingots/" + metalName),
|
||||
"count": 1
|
||||
}],
|
||||
"energy": 5000
|
||||
}).id(`kubejs:crucible/kubejs/smeltery/casting/metal/${metalName}/ingot_gold_cast`)
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Creates smeltery melting recipes for nuggets, ingots, blocks, etc
|
||||
* Also creates a magma crucible recipe for the ingot
|
||||
* @param {RecipeEventJS} event recipe event
|
||||
* @param {string} metalName the name of the metal to create melting recipes for
|
||||
* @param {number} meltingTime the time it takes to melt a block in the smeltery
|
||||
* @param {number} temperature the temperature required to melt a block in the smeltery
|
||||
*/
|
||||
const metalMelting = (event, metalName, outputFluid, meltingTime, temperature) => {
|
||||
let fluidTag = "forge:molten_" + metalName
|
||||
|
||||
let blockTag = "forge:storage_blocks/" + metalName
|
||||
|
||||
// block melting
|
||||
if (Ingredient.of(`#forge:storage_blocks/${metalName}`).first != Item.empty) {
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": {"tag": `forge:storage_blocks/${metalName}`},
|
||||
"result": {
|
||||
"fluid": outputFluid,
|
||||
"amount": 810
|
||||
},
|
||||
"temperature": temperature,
|
||||
"time": meltingTime
|
||||
}).id(`kubejs:smeltery/melting/metal/${metalName}/block`)
|
||||
}
|
||||
|
||||
let castTypes = [
|
||||
{name: "coin", fluidAmount: 30, timeMultiplier: 1 / (3 * Math.sqrt(3))},
|
||||
{name: "gear", fluidAmount: 360, timeMultiplier: 2 / 3},
|
||||
{name: "ingot", fluidAmount: 90, timeMultiplier: 1 / 3},
|
||||
{name: "nugget", fluidAmount: 10, timeMultiplier: 1 / 9},
|
||||
{name: "plate", fluidAmount: 90, timeMultiplier: 1 / 3},
|
||||
{name: "rod", fluidAmount: 45, timeMultiplier: 1 / (3 * Math.SQRT2)},
|
||||
{name: "wire", fluidAmount: 45, timeMultiplier: 1 / (3 * Math.SQRT2)}
|
||||
]
|
||||
|
||||
// melting cast shapes
|
||||
castTypes.forEach(cast=>{
|
||||
if (Ingredient.of(`#forge:${cast.name}s/${metalName}`).first != Item.empty) {
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": {"tag": `forge:${cast.name}s/${metalName}`},
|
||||
"result": {
|
||||
"fluid": outputFluid,
|
||||
"amount": cast.fluidAmount
|
||||
},
|
||||
"temperature": temperature,
|
||||
"time": meltingTime * cast.timeMultiplier
|
||||
}).id(`kubejs:smeltery/melting/metal/${metalName}/${cast.name}`)
|
||||
}
|
||||
})
|
||||
|
||||
// ingot crucible melting
|
||||
if (Ingredient.of(`#forge:ingots/${metalName}`).first != Item.empty) {
|
||||
event.custom({
|
||||
type:"thermal:crucible",
|
||||
ingredient: {
|
||||
"tag": `forge:ingots/${metalName}`
|
||||
},
|
||||
result:[{
|
||||
fluid: outputFluid,
|
||||
amount:90
|
||||
}],
|
||||
energy:Math.round(meltingTime / 3) * 50
|
||||
}).id(`kubejs:crucible/kubejs/smeltery/melting/metal/${metalName}/ingot`)
|
||||
}
|
||||
}
|
||||
|
||||
/** Used in datapack events instead of recipe events */
|
||||
const addChiselingRecipe = (event, id, items, overwrite) => {
|
||||
const json = {
|
||||
type: "rechiseled:chiseling",
|
||||
entries: [],
|
||||
overwrite: !!overwrite
|
||||
}
|
||||
items.forEach(item=>{
|
||||
json.entries.push({
|
||||
item: item
|
||||
})
|
||||
})
|
||||
event.addJson(id, json)
|
||||
}
|
||||
|
||||
/** Used in a datapack event to remove a configured feature by its resource location */
|
||||
const removeFeature = function(event, featureName) {
|
||||
featureName = featureName.split(":")
|
||||
let namespace = featureName[0]
|
||||
let identifier = featureName[1]
|
||||
event.addJson(`${namespace}:worldgen/configured_feature/${identifier}`, {
|
||||
"type": "minecraft:no_op",
|
||||
"config": {}
|
||||
})
|
||||
}
|
||||
|
||||
/** Used in a datapack event to add ore generation for an ore to the overworld
|
||||
* This function only works for ores with both a stone and deepslate variant
|
||||
*/
|
||||
const addOregenOverworld = function(event, featureName, blockName, heightType, heightMin, heightMax, veinCount, veinSize, discardChanceOnAirExposure) {
|
||||
featureName = featureName.split(":")
|
||||
let namespace = featureName[0]
|
||||
let identifier = featureName[1]
|
||||
|
||||
blockName = blockName.split(":")
|
||||
let blockNamespace = blockName[0]
|
||||
let blockIdentifier = blockName[1]
|
||||
|
||||
event.addJson(`${namespace}:worldgen/configured_feature/${identifier}`, {
|
||||
"type": "minecraft:ore",
|
||||
"config": {
|
||||
"discard_chance_on_air_exposure": discardChanceOnAirExposure,
|
||||
"size": veinSize,
|
||||
"targets": [
|
||||
{
|
||||
"state": {"Name": `${blockNamespace}:${blockIdentifier}`},
|
||||
"target": {"predicate_type": "minecraft:tag_match", "tag": "minecraft:stone_ore_replaceables"}
|
||||
},
|
||||
{
|
||||
"state": {"Name": `${blockNamespace}:deepslate_${blockIdentifier}`},
|
||||
"target": {"predicate_type": "minecraft:tag_match", "tag": "minecraft:deepslate_ore_replaceables"}
|
||||
}
|
||||
]
|
||||
}
|
||||
})
|
||||
let minInclusive = {"absolute": heightMin}
|
||||
let maxInclusive = {"absolute": heightMax}
|
||||
// EMI Oregen will display more useful information if we change to using Above Bottom where it makes sense to
|
||||
if (heightMin < -64) {
|
||||
minInclusive = {"above_bottom": heightMin + 64}
|
||||
maxInclusive = {"above_bottom": heightMax + 64}
|
||||
} else if (heightMax > 320) {
|
||||
minInclusive = {"below_top": -(heightMin - 320)}
|
||||
maxInclusive = {"below_top": -(heightMax - 320)}
|
||||
}
|
||||
|
||||
event.addJson(`${namespace}:worldgen/placed_feature/${identifier}`, {
|
||||
"feature": `${namespace}:${identifier}`,
|
||||
"placement": [
|
||||
{"type": "minecraft:count", "count": veinCount},
|
||||
{"type": "minecraft:in_square"},
|
||||
{
|
||||
"type": "minecraft:height_range",
|
||||
"height": {
|
||||
"type": heightType,
|
||||
"min_inclusive": minInclusive,
|
||||
"max_inclusive": maxInclusive
|
||||
}
|
||||
},
|
||||
{"type": "minecraft:biome"}
|
||||
]
|
||||
})
|
||||
|
||||
event.addJson(`${namespace}:forge/biome_modifier/${identifier}`, {
|
||||
"type": "forge:add_features",
|
||||
"biomes": "#minecraft:is_overworld",
|
||||
"features": `${namespace}:${identifier}`,
|
||||
"step": "underground_ores"
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the prefered item from a tag. Useful for porting Mantle recipes that use tags as outputs.
|
||||
* @param {string} tag Don't include a hashtag in the tag name
|
||||
*/
|
||||
// const ItemOutput = Java.loadClass('slimeknights.mantle.recipe.helper.ItemOutput');
|
||||
const getPreferredItemFromTag = (tag) => {
|
||||
/* Tried using mantle for this and it didn't work on first launch unfortunately */
|
||||
// return Item.of(ItemOutput.fromTag(TagKey.create(Registry.ITEM_REGISTRY, tag), 1).get()).getId();
|
||||
/* Create a copy of the mantle preferred mods list */
|
||||
const preferredMods = ["minecraft", "create", "alloyed", "createdeco", "createaddition", "createbigcannons", "create_dd", "thermal", "tconstruct", "tmechworks"];
|
||||
const tagItems = Ingredient.of("#" + tag).itemIds;
|
||||
for (let i = 0;i < preferredMods.length;++i) { let modId = preferredMods[i];
|
||||
for (let j = 0;j < tagItems.length;++j) { let itemId = tagItems[j];
|
||||
if (itemId.split(":")[0] === modId) {
|
||||
return itemId;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (tagItems.length > 0) {
|
||||
return tagItems[0];
|
||||
}
|
||||
return "minecraft:air";
|
||||
}
|
||||
8
overrides/kubejs/server_scripts/auto_reload_lang.js
Normal file
8
overrides/kubejs/server_scripts/auto_reload_lang.js
Normal file
@@ -0,0 +1,8 @@
|
||||
global._langReloaded = global._langReloaded || false;
|
||||
|
||||
ServerEvents.loaded(event => {
|
||||
if (!global._langReloaded) {
|
||||
event.server.runCommand("/kubejs reload lang")
|
||||
global._langReloaded = true
|
||||
}
|
||||
});
|
||||
62
overrides/kubejs/server_scripts/better_dynamo_placement.js
Normal file
62
overrides/kubejs/server_scripts/better_dynamo_placement.js
Normal file
@@ -0,0 +1,62 @@
|
||||
// Block Placement
|
||||
|
||||
function opposite(face) {
|
||||
if (face.equals("down"))
|
||||
return "up"
|
||||
if (face.equals("east"))
|
||||
return "west"
|
||||
if (face.equals("west"))
|
||||
return "east"
|
||||
if (face.equals("north"))
|
||||
return "south"
|
||||
if (face.equals("south"))
|
||||
return "north"
|
||||
return "down"
|
||||
}
|
||||
|
||||
EntityEvents.spawned(event => {
|
||||
let entity = event.getEntity()
|
||||
if (entity.getType() == "appliedenergistics2:singularity") {
|
||||
let item = entity.getItem()
|
||||
if (item == null)
|
||||
return
|
||||
if (!item.getId().contains("quantum"))
|
||||
return
|
||||
entity.setMotionX(0)
|
||||
entity.setMotionY(0)
|
||||
entity.setMotionZ(0)
|
||||
return
|
||||
}
|
||||
if (entity.getType() != "minecraft:item")
|
||||
return
|
||||
let item = entity.getItem()
|
||||
if (item == null)
|
||||
return
|
||||
if (!item.getId().startsWith("tconstruct:"))
|
||||
return
|
||||
if (!item.getId().endsWith("slime_fern"))
|
||||
return
|
||||
let block = entity.getBlock()
|
||||
if (block.getId() != "occultism:spirit_fire" && block.getDown().getId() != "occultism:spirit_fire")
|
||||
return
|
||||
entity.setMotionX(entity.getMotionX() / 16)
|
||||
entity.setMotionY(0.35)
|
||||
entity.setMotionZ(entity.getMotionZ() / 16)
|
||||
entity.setX(Math.floor(entity.getX()) + .5)
|
||||
entity.setY(Math.floor(entity.getY()) - .5)
|
||||
entity.setZ(Math.floor(entity.getZ()) + .5)
|
||||
})
|
||||
|
||||
BlockEvents.placed(event => {
|
||||
// Reverse placed Dynamos on Sneak
|
||||
if (event.getEntity() == null)
|
||||
return
|
||||
let block = event.getBlock();
|
||||
if (block.getId().startsWith("thermal:dynamo")) {
|
||||
let properties = block.getProperties()
|
||||
if (event.getEntity().isCrouching()) {
|
||||
properties["facing"] = opposite(properties["facing"].toString())
|
||||
block.set(block.getId(), properties)
|
||||
}
|
||||
}
|
||||
})
|
||||
623
overrides/kubejs/server_scripts/bonkers_chemistry.js
Normal file
623
overrides/kubejs/server_scripts/bonkers_chemistry.js
Normal file
@@ -0,0 +1,623 @@
|
||||
|
||||
global.cachedSeed = undefined
|
||||
global.cachedAlchemyData = {}
|
||||
|
||||
function colourMap(c) {
|
||||
switch (c) {
|
||||
case "white": return [255, 255, 255]
|
||||
case "orange": return [255, 150, 0]
|
||||
case "magenta": return [255, 39, 255]
|
||||
case "light_blue": return [170, 202, 255]
|
||||
|
||||
case "yellow": return [255, 255, 0]
|
||||
case "lime": return [160, 255, 0]
|
||||
case "pink": return [255, 109, 183]
|
||||
case "gray": return [127, 127, 127]
|
||||
|
||||
case "light_gray": return [223, 223, 223]
|
||||
case "cyan": return [0, 205, 205]
|
||||
case "purple": return [140, 0, 255]
|
||||
case "blue": return [29, 29, 255]
|
||||
|
||||
case "brown": return [119, 59, 0]
|
||||
case "green": return [12, 203, 0]
|
||||
case "red": return [244, 22, 9]
|
||||
default: return [47, 47, 47]
|
||||
}
|
||||
}
|
||||
|
||||
function shuffle(array, random) {
|
||||
for (let i = array.length - 1; i > 0; i--) {
|
||||
let j = random.nextInt(i + 1);
|
||||
let temp = array[i];
|
||||
array[i] = array[j];
|
||||
array[j] = temp;
|
||||
}
|
||||
return array
|
||||
}
|
||||
|
||||
function attackNearby(level, x, y, z) {
|
||||
// let aabb = AABB.CUBE.func_72317_d(x - .5, y + .5, z - .5).func_72321_a(-3, -3, -3).func_72321_a(3, 3, 3)
|
||||
// let list = level.minecraftLevel.func_217394_a(null, aabb, e => true)
|
||||
|
||||
let entities = level.getEntitiesWithin(AABB.of(x - 3,y - 3,z - 3,x + 3,y + 3,z + 3))
|
||||
|
||||
entities.forEach(e => {
|
||||
let entity = e
|
||||
if (!entity.isLiving())
|
||||
return
|
||||
entity.attack(entity.level.damageSources().generic(), 6)
|
||||
})
|
||||
}
|
||||
|
||||
function process(level, block, entity, face) {
|
||||
|
||||
if (global.cachedSeed != level.getSeed()) {
|
||||
global.cachedSeed = level.getSeed()
|
||||
let random = new Random(level.getSeed())
|
||||
let next = () => random.nextInt(6)
|
||||
let generateCode = () => [next(), next(), next(), next()]
|
||||
for (let cat = 0; cat < 7; cat++) {
|
||||
global.cachedAlchemyData[cat] = {
|
||||
code: generateCode(),
|
||||
result: cat == 6 ? "kubejs:substrate_chaos" : global.substrates[6][cat].id,
|
||||
mappings: shuffle(Array(0, 1, 2, 3, 4, 5), random)
|
||||
}
|
||||
}
|
||||
let total = []
|
||||
global.cachedAlchemyData["chaos_mapping"] = []
|
||||
for (let i = 0; i < 38; i++) {
|
||||
total.push(i)
|
||||
global.cachedAlchemyData["chaos_mapping"].push(0)
|
||||
}
|
||||
shuffle(total, random)
|
||||
for (let i = 0; i < 38; i += 2) {
|
||||
if (total[i] >= 36 && total[i + 1] >= 36) { // must not map silver-silicon
|
||||
if (i == 0) {
|
||||
let swap = total[i + 2]
|
||||
total[i + 2] = total[i + 1]
|
||||
total[i + 1] = swap
|
||||
} else {
|
||||
let swap = total[i - 1]
|
||||
total[i - 1] = total[i]
|
||||
total[i] = swap
|
||||
}
|
||||
}
|
||||
}
|
||||
for (let i = 0; i < 38; i += 2) {
|
||||
global.cachedAlchemyData["chaos_mapping"][total[i]] = total[i + 1]
|
||||
global.cachedAlchemyData["chaos_mapping"][total[i + 1]] = total[i]
|
||||
}
|
||||
}
|
||||
|
||||
let nbt = entity.nbt
|
||||
let items = nbt.Items
|
||||
|
||||
// Laser Recipe
|
||||
|
||||
let validForProcessing = true
|
||||
let validTool = undefined
|
||||
let toProcess = undefined
|
||||
let processAmount = 0
|
||||
let magnet = "thermal:flux_magnet"
|
||||
let staff = "ae2:charged_staff"
|
||||
let entropy = "ae2:entropy_manipulator"
|
||||
|
||||
items.forEach(e => {
|
||||
if (!validForProcessing)
|
||||
return
|
||||
if (e.id.startsWith(magnet) || e.id.startsWith(staff) || e.id.startsWith(entropy)) {
|
||||
if (validTool)
|
||||
validForProcessing = false
|
||||
validTool = e
|
||||
return
|
||||
}
|
||||
if (toProcess && toProcess != e.id) {
|
||||
validForProcessing = false
|
||||
return
|
||||
}
|
||||
toProcess = e.id
|
||||
processAmount += e.Count
|
||||
})
|
||||
|
||||
if (validTool && validForProcessing && toProcess) {
|
||||
let resultItem = undefined
|
||||
let particle = "effect"
|
||||
|
||||
if (!validTool.tag)
|
||||
return
|
||||
|
||||
if (validTool.id.startsWith(magnet)) {
|
||||
if (!toProcess.equals("minecraft:basalt"))
|
||||
return
|
||||
let energy = validTool.tag.getInt("Energy") - 80 * processAmount
|
||||
if (energy < 0)
|
||||
return
|
||||
validTool.tag.putInt("Energy", energy)
|
||||
resultItem = "thermal:basalz_rod"
|
||||
particle = "flame"
|
||||
}
|
||||
// if (validTool.id.startsWith(staff)) {
|
||||
// if (!toProcess.equals("kubejs:smoke_mote"))
|
||||
// return
|
||||
// let energy = validTool.tag.getDouble("internalCurrentPower") - 40 * processAmount
|
||||
// if (energy < 0)
|
||||
// return
|
||||
// validTool.tag.putDouble("internalCurrentPower", energy)
|
||||
// resultItem = "thermal:blitz_rod"
|
||||
// particle = "firework"
|
||||
// }
|
||||
if (validTool.id.startsWith(entropy)) {
|
||||
if (!toProcess.equals("minecraft:snowball"))
|
||||
return
|
||||
let energy = validTool.tag.getDouble("internalCurrentPower") - 40 * processAmount
|
||||
if (energy < 0)
|
||||
return
|
||||
validTool.tag.putDouble("internalCurrentPower", energy)
|
||||
resultItem = "thermal:blizz_rod"
|
||||
particle = "spit"
|
||||
}
|
||||
|
||||
if (!resultItem)
|
||||
return
|
||||
|
||||
level.server.runCommandSilent(`/particle minecraft:flash ${entity.x} ${entity.y + .5} ${entity.z} 0 0 0 .01 1`)
|
||||
level.server.runCommandSilent(`/particle ae2:matter_cannon_fx ${entity.x} ${entity.y + .5} ${entity.z}`)
|
||||
level.server.runCommandSilent(`/particle minecraft:${particle} ${entity.x} ${entity.y + .5} ${entity.z} .65 .65 .65 0 10`)
|
||||
level.server.runCommandSilent(`/playsound minecraft:block.enchantment_table.use block @a ${entity.x} ${entity.y} ${entity.z} 0.95 1.5`)
|
||||
attackNearby(level, entity.x, entity.y, entity.z)
|
||||
|
||||
let resultCount = Math.floor(processAmount / 2.0 + new Random().nextDouble())
|
||||
nbt.Items.clear()
|
||||
|
||||
let actualIndex = 0
|
||||
for (let i = 0; i < 5; i++) {
|
||||
if (i == validTool.Slot) {
|
||||
nbt.Items.add(actualIndex, validTool)
|
||||
actualIndex++
|
||||
continue
|
||||
}
|
||||
if (resultCount <= 0)
|
||||
continue
|
||||
|
||||
let resultItemNBT = Utils.newMap();
|
||||
resultItemNBT.put("Slot", i)
|
||||
resultItemNBT.put("id", resultItem)
|
||||
resultItemNBT.put("Count", Math.min(64, resultCount))
|
||||
nbt.Items.add(actualIndex, resultItemNBT)
|
||||
actualIndex++
|
||||
|
||||
resultCount = resultCount - 64
|
||||
}
|
||||
|
||||
entity.setNbt(nbt)
|
||||
return
|
||||
}
|
||||
|
||||
// Chaos Transmutation
|
||||
|
||||
let validForTransmutation = true
|
||||
let catalyst = undefined
|
||||
let toTransmute = undefined
|
||||
let transmuteAmount = 0
|
||||
let catalystId = 0
|
||||
|
||||
items.forEach(e => {
|
||||
if (!validForTransmutation)
|
||||
return
|
||||
if (!e.id.startsWith("kubejs:substrate_")) {
|
||||
validForTransmutation = false
|
||||
return
|
||||
}
|
||||
let mapping = global.substrate_mapping[e.id.replace("kubejs:substrate_", "")]
|
||||
if (e.id != "kubejs:substrate_silicon" && e.id != "kubejs:substrate_silver" && (!mapping || mapping.category == 6)) {
|
||||
if (catalyst || mapping) {
|
||||
validForTransmutation = false
|
||||
return
|
||||
}
|
||||
catalyst = e
|
||||
catalystId = mapping ? mapping.index : -1
|
||||
return
|
||||
}
|
||||
if (toTransmute && toTransmute != e.id) {
|
||||
validForTransmutation = false
|
||||
return
|
||||
}
|
||||
toTransmute = e.id
|
||||
transmuteAmount += e.Count
|
||||
})
|
||||
|
||||
if (validForTransmutation && catalyst && toTransmute) {
|
||||
let categoryMapping = global.substrate_mapping[toTransmute.replace("kubejs:substrate_", "")]
|
||||
|
||||
let id1
|
||||
// let id2
|
||||
// if (catalystId == -1) {
|
||||
if (toTransmute == "kubejs:substrate_silicon")
|
||||
categoryMapping = { category: 5, index: 6 }
|
||||
if (toTransmute == "kubejs:substrate_silver")
|
||||
categoryMapping = { category: 5, index: 7 }
|
||||
let data = global.cachedAlchemyData["chaos_mapping"]
|
||||
// let dataReversed = global.cachedAlchemyData["reverse_chaos_mapping"]
|
||||
let i1 = data[categoryMapping.category * 6 + categoryMapping.index]
|
||||
// let i2 = dataReversed[categoryMapping.category * 6 + categoryMapping.index]
|
||||
id1 = i1 == 36 ? "kubejs:substrate_silicon" : i1 == 37 ? "kubejs:substrate_silver" : global.substrates[Math.floor(i1 / 6)][i1 % 6].id
|
||||
// id2 = i2 == 36 ? "kubejs:substrate_silicon" : global.substrates[Math.floor(i2 / 6)][i2 % 6].id
|
||||
// }
|
||||
// else {
|
||||
// if (!categoryMapping || (categoryMapping.category + 1) % 6 != catalystId)
|
||||
// return
|
||||
// let data = global.cachedAlchemyData[catalystId]
|
||||
// id1 = global.substrates[catalystId][data.mappings[categoryMapping.index]].id
|
||||
// if (catalystId != 1) { // search for backwards connection
|
||||
// let prevCat = catalystId - 1;
|
||||
// if (catalystId == 0)
|
||||
// prevCat += 6
|
||||
// for (let i = 0; i < 6; i++)
|
||||
// if (global.cachedAlchemyData[prevCat].mappings[i] == categoryMapping.index)
|
||||
// id2 = global.substrates[prevCat - 1][i].id
|
||||
// }
|
||||
// if (id1 == "kubejs:substrate_cobblestone")
|
||||
// id1 = "kubejs:substrate_silicon"
|
||||
// }
|
||||
let resultItems = [id1]// , id2]
|
||||
|
||||
level.server.runCommandSilent(`/particle minecraft:flash ${entity.x} ${entity.y + .5} ${entity.z} 0 0 0 .01 1`)
|
||||
level.server.runCommandSilent(`/particle ae2:matter_cannon_fx ${entity.x} ${entity.y + .5} ${entity.z}`)
|
||||
level.server.runCommandSilent(`/particle minecraft:effect ${entity.x} ${entity.y + .5} ${entity.z} .75 .75 .75 .75 10`)
|
||||
level.server.runCommandSilent(`/playsound minecraft:block.enchantment_table.use block @a ${entity.x} ${entity.y} ${entity.z} 0.95 1.5`)
|
||||
attackNearby(level, entity.x, entity.y, entity.z)
|
||||
|
||||
let random = new Random()
|
||||
let resultCounts = [0]// , 0]
|
||||
|
||||
for (let i = 0; i < transmuteAmount; i++) {
|
||||
let next = random.nextInt(8)
|
||||
if (next < (catalystId == -1 ? 4 : 2))
|
||||
continue
|
||||
let index = 0// next == 11 ? 1 : 0
|
||||
resultCounts[index] = resultCounts[index] + 1
|
||||
}
|
||||
|
||||
nbt.Items.clear()
|
||||
|
||||
let actualIndex = 0
|
||||
let itemIndex = 0
|
||||
for (let i = 0; i < 5; i++) {
|
||||
if (i == catalyst.Slot) {
|
||||
nbt.Items.add(actualIndex, catalyst)
|
||||
actualIndex++
|
||||
continue
|
||||
}
|
||||
if (resultCounts[itemIndex] <= 0) {
|
||||
if (itemIndex == 0)// 1)
|
||||
continue
|
||||
itemIndex++
|
||||
if (!resultItems[itemIndex])
|
||||
continue
|
||||
}
|
||||
|
||||
let resultItemNBT = {
|
||||
Slot: i,
|
||||
id: resultItems[itemIndex],
|
||||
Count: Math.min(64, resultCounts[itemIndex])
|
||||
};
|
||||
nbt.Items.add(actualIndex, resultItemNBT)
|
||||
actualIndex++
|
||||
|
||||
resultCounts[itemIndex] = resultCounts[itemIndex] - 64
|
||||
}
|
||||
|
||||
entity.setNbt(nbt)
|
||||
return
|
||||
}
|
||||
|
||||
// Catalyst Mastermind
|
||||
|
||||
let catCode = -1;
|
||||
let guessedSet = []
|
||||
let reagents = []
|
||||
let guessedString = ""
|
||||
let count = 0;
|
||||
let redstoneAccellerator = false
|
||||
let glowstoneAccellerator = false
|
||||
let valid = true
|
||||
|
||||
if (items.length < 4)
|
||||
return
|
||||
|
||||
items.forEach(e => {
|
||||
if (e.Count > 1) {
|
||||
valid = false
|
||||
return
|
||||
}
|
||||
if (e.id.startsWith("kubejs:accellerator_redstone")) {
|
||||
redstoneAccellerator = true
|
||||
return
|
||||
}
|
||||
if (e.id.startsWith("kubejs:accellerator_glowstone")) {
|
||||
glowstoneAccellerator = true
|
||||
return
|
||||
}
|
||||
if (!e.id.startsWith("kubejs:substrate_")) {
|
||||
valid = false
|
||||
return
|
||||
}
|
||||
let mapping = global.substrate_mapping[e.id.replace("kubejs:substrate_", "")]
|
||||
if (!mapping)
|
||||
return
|
||||
if (catCode != -1 && catCode != mapping.category)
|
||||
return
|
||||
catCode = mapping.category
|
||||
guessedSet.push(mapping.index)
|
||||
reagents.push(e.id)
|
||||
count++
|
||||
guessedString = guessedString + "§6" + mapping.name + "§7" + (count < 4 ? ", " : "")
|
||||
})
|
||||
|
||||
if (!valid)
|
||||
return
|
||||
if (count != 4)
|
||||
return
|
||||
if (!global.cachedAlchemyData[catCode])
|
||||
return
|
||||
|
||||
let data = global.cachedAlchemyData[catCode]
|
||||
let unmatchedCorrectSet = data.code.slice()
|
||||
let unmatchedGuessedSet = guessedSet.slice()
|
||||
let result = [0, 0, 0]
|
||||
let resultEval = [0, 0, 0, 0]
|
||||
let trueFalse = [true, false]
|
||||
let retain = -1
|
||||
|
||||
trueFalse.forEach(exact => {
|
||||
for (let digit = 0; digit < 4; digit++) {
|
||||
let guessed = unmatchedGuessedSet[digit]
|
||||
for (let digit2 = 0; digit2 < unmatchedCorrectSet.length; digit2++) {
|
||||
let correct = unmatchedCorrectSet[digit2]
|
||||
if (correct != guessed)
|
||||
continue
|
||||
if (exact && digit != digit2)
|
||||
continue
|
||||
|
||||
resultEval[digit] = exact ? 2 : 1
|
||||
result[exact ? 2 : 1] = result[exact ? 2 : 1] + 1
|
||||
unmatchedGuessedSet[digit] = -2
|
||||
unmatchedCorrectSet[digit2] = -1
|
||||
break
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
if (glowstoneAccellerator || redstoneAccellerator) {
|
||||
let random = new Random()
|
||||
let shuffled = shuffle(Array(0, 1, 2, 3), random)
|
||||
for (let i = 0; i < 4; i++) {
|
||||
let j = shuffled[i]
|
||||
if (glowstoneAccellerator && resultEval[j] == 2) {
|
||||
retain = j
|
||||
break
|
||||
}
|
||||
if (redstoneAccellerator && resultEval[j] == 1) {
|
||||
retain = j
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
result[0] = 4 - result[2] - result[1]
|
||||
|
||||
// console.log("Correct: " + data.code)
|
||||
// console.log("Guessed: " + guessedSet)
|
||||
// console.log("Result: " + result)
|
||||
// console.log("Retained: " + retain)
|
||||
|
||||
let errorId = -1
|
||||
|
||||
if (result[0] == 4)
|
||||
errorId = 0
|
||||
if (result[0] == 3) {
|
||||
if (result[1] == 1)
|
||||
errorId = 1
|
||||
if (result[1] == 0)
|
||||
errorId = 2
|
||||
}
|
||||
if (result[0] == 2) {
|
||||
if (result[1] == 2)
|
||||
errorId = 3
|
||||
if (result[1] == 0)
|
||||
errorId = 4
|
||||
if (result[1] == 1)
|
||||
errorId = 5
|
||||
}
|
||||
if (result[0] == 1) {
|
||||
if (result[1] == 3)
|
||||
errorId = 6
|
||||
if (result[1] == 0)
|
||||
errorId = 7
|
||||
if (result[1] == 2)
|
||||
errorId = 8
|
||||
if (result[1] == 1)
|
||||
errorId = 9
|
||||
}
|
||||
if (result[0] == 0) {
|
||||
if (result[1] == 4)
|
||||
errorId = 10
|
||||
if (result[1] == 3)
|
||||
errorId = 12
|
||||
if (result[1] == 1)
|
||||
errorId = 13
|
||||
if (result[1] == 2)
|
||||
errorId = 14
|
||||
}
|
||||
|
||||
let success = errorId == -1
|
||||
let resultItem = success ? data.result : `kubejs:failed_alchemy_${errorId}`
|
||||
level.server.runCommandSilent(`/particle minecraft:flash ${entity.x} ${entity.y + .5} ${entity.z} 0 0 0 .01 1`)
|
||||
level.server.runCommandSilent(`/particle ae2:matter_cannon_fx ${entity.x} ${entity.y + .5} ${entity.z}`)
|
||||
level.server.runCommandSilent(`/particle minecraft:dust 0 1 1 1 ${entity.x} ${entity.y + .5} ${entity.z} .75 .75 .75 .75 ${success ? "80" : "6"}`)
|
||||
level.server.runCommandSilent(`/playsound minecraft:block.enchantment_table.use block @a ${entity.x} ${entity.y} ${entity.z} 0.95 ${success ? "2" : "1.25"}`)
|
||||
attackNearby(level, entity.x, entity.y, entity.z)
|
||||
if (success)
|
||||
level.server.runCommandSilent(`/playsound minecraft:block.beacon.activate block @a ${entity.x} ${entity.y} ${entity.z} 0.95 1.5`)
|
||||
nbt.Items.clear()
|
||||
|
||||
let resultItemNBT = {}
|
||||
// let resultItemTagNBT = {}
|
||||
// let resultItemLoreNBT = {}
|
||||
// let resultItemLoreList = []
|
||||
|
||||
// resultItemLoreList.push({text: "' + guessedString + '", italic: false})
|
||||
// resultItemLoreNBT.Lore = resultItemLoreList
|
||||
// resultItemTagNBT.display = resultItemLoreNBT
|
||||
|
||||
resultItemNBT.Slot = 0
|
||||
resultItemNBT.id = resultItem
|
||||
resultItemNBT.Count = 1
|
||||
// if (errorId != -1)
|
||||
// resultItemNBT.tag = resultItemTagNBT
|
||||
nbt.Items.add(0, resultItemNBT)
|
||||
|
||||
if (retain != -1) {
|
||||
resultItemNBT = {Slot: 1, id: reagents[retain], Count: 1};
|
||||
nbt.Items.add(1, resultItemNBT)
|
||||
}
|
||||
|
||||
entity.setNbt(nbt)
|
||||
|
||||
}
|
||||
|
||||
BlockEvents.leftClicked(event => {
|
||||
|
||||
let block = event.getBlock()
|
||||
let tags = block.getTags()
|
||||
|
||||
if (!block.id.startsWith("thermal:machine_frame"))
|
||||
return
|
||||
|
||||
let level = event.getLevel()
|
||||
let clickedFace = event.getFacing()
|
||||
let item = event.getItem()
|
||||
let player = event.getPlayer()
|
||||
|
||||
|
||||
if (!item.empty)
|
||||
return
|
||||
if (player.miningBlock) // This is true when the player is releasing left-click
|
||||
return
|
||||
|
||||
// if (player.name.text != "Deployer")
|
||||
// return
|
||||
|
||||
|
||||
let sound = false
|
||||
|
||||
Direction.ALL.values().forEach(face => {
|
||||
if (clickedFace.equals(face))
|
||||
return
|
||||
let laser = block.offset(face)
|
||||
|
||||
|
||||
if (!laser.hasTag("kubejs:alchemical_laser_lamps"))
|
||||
return
|
||||
|
||||
let color = ""
|
||||
|
||||
if (laser.hasTag("kubejs:alchemical_laser_lamps/white")) color = "white";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/orange")) color = "orange";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/magenta")) color = "magenta";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/light_blue")) color = "light_blue";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/yellow")) color = "yellow";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/lime")) color = "lime";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/pink")) color = "pink";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/gray")) color = "gray";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/light_gray")) color = "light_gray";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/cyan")) color = "cyan";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/purple")) color = "purple";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/blue")) color = "blue";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/brown")) color = "brown";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/green")) color = "green";
|
||||
else if (laser.hasTag("kubejs:alchemical_laser_lamps/red")) color = "red";
|
||||
|
||||
// let te = laser.getEntity()
|
||||
// if (!te)
|
||||
// return
|
||||
// let nbt = Utils.newMap().toNBT()
|
||||
// te.func_189515_b(nbt)
|
||||
// let parts = nbt.func_150295_c("parts", 10)
|
||||
// let color = ""
|
||||
// if (parts) {
|
||||
// parts.forEach(part => {
|
||||
// if (!part.id.endsWith("_cage_light"))
|
||||
// return
|
||||
// if (part.pow == part.id.contains("inverted"))
|
||||
// return
|
||||
// if (part.side != face.getOpposite().ordinal())
|
||||
// return
|
||||
// valid = true
|
||||
// color = part.id.replace("_inverted", "").replace("_cage_light", "").replace("projectred-illumination:", "")
|
||||
// })
|
||||
// }
|
||||
|
||||
// if (!valid)
|
||||
// return
|
||||
|
||||
let x = laser.x
|
||||
let y = laser.y
|
||||
let z = laser.z
|
||||
// let aabb = AABB.CUBE.func_72317_d(x, y, z).func_72321_a(4 * face.x, 4 * face.y, 4 * face.z)
|
||||
|
||||
// let list = level.minecraftWorld.func_217394_a(null, aabb, e => true)
|
||||
|
||||
|
||||
let laserVec3i = face.getNormal();
|
||||
let laserVec3d = new Vec3d(laserVec3i.x, laserVec3i.y, laserVec3i.z)
|
||||
// Note that the block's coordinate is located at the north-east-bottom corner of a block. So we need to use AABB.of x-2 to x+3
|
||||
let aa = new Vec3d(x - 0.25, y - 0.25, z - 0.25).add(laserVec3d.multiply(0.25, 0.25, 0.25))
|
||||
let bb = new Vec3d(x + 1.25, y + 1.25, z + 1.25).add(laserVec3d.multiply(0.25, 0.25, 0.25))
|
||||
if (face.getAxisDirection().equals(AxisDirection.POSITIVE)) {
|
||||
bb = bb.add(laserVec3d.multiply(3.75, 3.75, 3.75))
|
||||
} else {
|
||||
aa = aa.add(laserVec3d.multiply(3.75, 3.75, 3.75))
|
||||
}
|
||||
let entities = level.getEntitiesWithin(AABB.of(aa.x(), aa.y(), aa.z(), bb.x(), bb.y(), bb.z()))
|
||||
|
||||
entities.forEach(e => {
|
||||
let entity = e
|
||||
if (!entity.type.equals("minecraft:hopper_minecart")) {
|
||||
if (!entity.type.equals("minecraft:item"))
|
||||
entity.attack(entity.level.damageSources().generic(), 6)
|
||||
return
|
||||
}
|
||||
process(level, block, entity, face)
|
||||
entity.attack(entity.level.damageSources().generic(), 1)
|
||||
})
|
||||
|
||||
sound = true
|
||||
let rgb = colourMap(color)
|
||||
for (let i = 0; i < 22; i++) {
|
||||
let offset = (i / 20.0) * 4
|
||||
level.server.runCommandSilent(`/particle dust ${rgb[0] / 256} ${rgb[1] / 256} ${rgb[2] / 256} 1 ${x + .5 + face.x * offset} ${y + .5 + face.y * offset} ${z + .5 + face.z * offset} 0 0 0 .001 1`)
|
||||
}
|
||||
level.server.runCommandSilent(`/particle minecraft:end_rod ${x + .5 + face.x * 2} ${y + .5 + face.y * 2} ${z + .5 + face.z * 2} ${face.x * 2} ${face.y * 2} ${face.z * 2} .1 10`)
|
||||
|
||||
})
|
||||
|
||||
if (sound)
|
||||
level.server.runCommandSilent(`/playsound minecraft:entity.firework_rocket.blast block @a ${block.x} ${block.y} ${block.z} 0.55 0.5`)
|
||||
|
||||
|
||||
})
|
||||
|
||||
PlayerEvents.inventoryChanged(event => {
|
||||
let entity = event.getEntity()
|
||||
if (event.getItem().id == "kubejs:missingno") {
|
||||
event.player.inventory.clear("kubejs:missingno")
|
||||
event.getLevel().getBlock(entity.x, entity.y, entity.z)
|
||||
.createExplosion()
|
||||
.explosionMode(Level.ExplosionInteraction.TNT)
|
||||
.causesFire(true)
|
||||
.strength(4)
|
||||
.explode()
|
||||
}
|
||||
})
|
||||
10
overrides/kubejs/server_scripts/effectivetools.js
Normal file
10
overrides/kubejs/server_scripts/effectivetools.js
Normal file
@@ -0,0 +1,10 @@
|
||||
|
||||
|
||||
ServerEvents.tags("block", event => {
|
||||
event.add("minecraft:mineable/pickaxe", ["#forge:glass", "#forge:glass_panes"]);
|
||||
event.add("minecraft:mineable/pickaxe", /xtonesreworked:glaxx_block_/);
|
||||
event.add("minecraft:mineable/pickaxe", /enderio:clear_glass/);
|
||||
event.add("minecraft:mineable/pickaxe", /enderio:fused_quartz/);
|
||||
event.add("minecraft:mineable/pickaxe", "mbd2:strainer");
|
||||
event.add("minecraft:mineable/axe", "mbd2:strainer");
|
||||
})
|
||||
@@ -0,0 +1,2 @@
|
||||
The keymods folder is for misc changes involving the key mods for CABIN
|
||||
These mods likely also have changes in the main scripts like chapters.js and tags.js
|
||||
70
overrides/kubejs/server_scripts/key_mods/ad_astra.js
Normal file
70
overrides/kubejs/server_scripts/key_mods/ad_astra.js
Normal file
@@ -0,0 +1,70 @@
|
||||
ServerEvents.recipes(event => {
|
||||
// Most Ad Astra Recipes are added in chapters.js
|
||||
event.recipes.create.mixing(("3x ad_astra:steel_ingot"),["3x minecraft:iron_ingot", "minecraft:coal"]).heated()
|
||||
|
||||
event.remove({type: "ad_astra:alloying"})
|
||||
event.remove({type: "ad_astra:compressing"})
|
||||
event.remove({type: "ad_astra:cryo_freezing"})
|
||||
event.remove({type: "ad_astra:nasa_workbench"})
|
||||
event.remove({type: "ad_astra:refining"})
|
||||
|
||||
// Remove all the recipes we don't want from Ad Astra
|
||||
// We're in an awkward situation where we want half of the recipes and don't want the other half
|
||||
let begoneEarth = [
|
||||
"tier_1_rover", "launch_pad",
|
||||
"steel_cable", "desh_cable", "desh_fluid_pipe", "ostrum_fluid_pipe", "cable_duct", "fluid_pipe_duct",
|
||||
"coal_generator", "compressor", "etrionic_blast_furnace", "nasa_workbench", "fuel_refinery", "oxygen_loader",
|
||||
"solar_panel", "water_pump", "oxygen_distributor", "gravity_normalizer", "energizer", "cryo_freezer", "oxygen_sensor",
|
||||
/* "ti_69", "wrench",*/ "zip_gun",
|
||||
"etrionic_capacitor", "gas_tank", "large_gas_tank", // "photovoltaic_etrium_cell",
|
||||
"oxygen_gear", "wheel", "engine_frame", "fan", "rocket_nose_cone",
|
||||
"rocket_fin"
|
||||
]
|
||||
let begoneRegex = [
|
||||
/^ad_astra:(space|netherite_space|jet_suit)_(helmet|suit|pants|boots)$/,
|
||||
"ad_astra:jet_suit",
|
||||
/^ad_astra:(steel|desh|ostrum|calorite)_(tank|engine)$/,
|
||||
]
|
||||
begoneEarth.forEach(begone => { event.remove({ id: `ad_astra:${begone}` }) })
|
||||
begoneRegex.forEach(begone => { event.remove({ id: begone }) })
|
||||
|
||||
event.replaceInput({ id: "ad_astra:ti_69" }, "#forge:plates/steel", "kubejs:matter_plastics")
|
||||
})
|
||||
|
||||
ServerEvents.highPriorityData(event=>{
|
||||
let spaceStationRecipe = {
|
||||
type: "ad_astra:space_station_recipe",
|
||||
dimension: "ad_astra:earth_orbit",
|
||||
ingredients: [
|
||||
{
|
||||
ingredient: {
|
||||
item: "kubejs:computation_matrix"
|
||||
},
|
||||
count: 64
|
||||
},
|
||||
{
|
||||
ingredient: {
|
||||
item: "kubejs:enderium_machine"
|
||||
},
|
||||
count: 64
|
||||
},
|
||||
{
|
||||
ingredient: {
|
||||
item: "ae2:controller"
|
||||
},
|
||||
count: 64
|
||||
},
|
||||
{
|
||||
ingredient: {
|
||||
tag: "forge:storage_blocks/iron"
|
||||
},
|
||||
count: 64
|
||||
}
|
||||
],
|
||||
structure: "ad_astra:space_station"
|
||||
}
|
||||
|
||||
event.addJson("ad_astra:recipes/space_station/earth_orbit_space_station", spaceStationRecipe)
|
||||
spaceStationRecipe.dimension = "ad_astra:moon_orbit"
|
||||
event.addJson("ad_astra:recipes/space_station/moon_orbit_space_station", spaceStationRecipe)
|
||||
})
|
||||
8
overrides/kubejs/server_scripts/key_mods/ae2.js
Normal file
8
overrides/kubejs/server_scripts/key_mods/ae2.js
Normal file
@@ -0,0 +1,8 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ output: "ae2:vibration_chamber" })
|
||||
|
||||
event.remove({ id: "ae2:transform/flawed_budding_quartz" })
|
||||
event.remove({ id: "ae2:transform/chipped_budding_quartz" })
|
||||
event.remove({ id: "ae2:transform/damaged_budding_quartz" })
|
||||
})
|
||||
@@ -0,0 +1,13 @@
|
||||
// priority: 1
|
||||
|
||||
wood_types.push("architects_palette:twisted")
|
||||
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ id: "architects_palette:smelting/charcoal_block_from_logs_that_burn_smoking" })
|
||||
event.remove({ id: "architects_palette:charcoal_block" })
|
||||
event.stonecutting("architects_palette:charcoal_block", "minecraft:charcoal")
|
||||
donutCraft(event, Item.of("architects_palette:plating_block", 8), "create:iron_sheet", "minecraft:stone")
|
||||
event.replaceInput({ id: "architects_palette:wither_lamp" }, "architects_palette:withered_bone", "tconstruct:necrotic_bone")
|
||||
event.replaceInput({ id: "architects_palette:withered_bone_block" }, "architects_palette:withered_bone", "tconstruct:necrotic_bone")
|
||||
event.remove({ id: "architects_palette:withered_bone" })
|
||||
})
|
||||
58
overrides/kubejs/server_scripts/key_mods/create.js
Normal file
58
overrides/kubejs/server_scripts/key_mods/create.js
Normal file
@@ -0,0 +1,58 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
// casing recipe changes
|
||||
let tweak_casing = (name, mats) => {
|
||||
event.remove({ output: name + "_casing"})
|
||||
event.shapeless(Item.of(name + "_casing", 2), mats)
|
||||
}
|
||||
tweak_casing("create:andesite", ["create:andesite_alloy", "#minecraft:logs"])
|
||||
tweak_casing("create:copper", ["create:copper_sheet", "#minecraft:logs"])
|
||||
tweak_casing("create:railway", ["create:golden_sheet", "minecraft:deepslate"])
|
||||
tweak_casing("create:brass", ["create:brass_sheet", "#minecraft:logs"])
|
||||
tweak_casing("kubejs:zinc", ["create:zinc_ingot", "minecraft:stone"])
|
||||
tweak_casing("kubejs:lead", ["thermal:lead_plate", "minecraft:deepslate"])
|
||||
tweak_casing("kubejs:invar", ["thermal:invar_ingot", "minecraft:stone"])
|
||||
tweak_casing("kubejs:enderium", ["minecraft:ender_pearl", "minecraft:obsidian"])
|
||||
tweak_casing("kubejs:fluix", ["thermal:lead_plate", "minecraft:blackstone"])
|
||||
// tweak_casing('alloyed:steel', ["alloyed:steel_sheet", '#minecraft:logs'])
|
||||
tweak_casing("create:refined_radiance", ["create:refined_radiance", "#minecraft:logs"])
|
||||
tweak_casing("create:shadow_steel", ["create:shadow_steel", "#minecraft:logs"])
|
||||
// recipe changes
|
||||
event.replaceInput({ id: "create:crafting/kinetics/adjustable_chain_gearshift" }, "create:electron_tube", "minecraft:redstone")
|
||||
event.replaceInput({ id: "create:crafting/kinetics/rope_pulley" }, "#forge:wool", "#supplementaries:ropes")
|
||||
// windmill recipe tweaks
|
||||
event.remove({ id: "create:crafting/kinetics/white_sail" })
|
||||
event.shaped("2x create:white_sail", [
|
||||
"SSS",
|
||||
"NAN",
|
||||
"SSS"
|
||||
], {
|
||||
A: "#forge:wool",
|
||||
N: "minecraft:iron_nugget",
|
||||
S: "minecraft:stick"
|
||||
})
|
||||
// tweak obsidian crushing recipe
|
||||
event.remove({ id: "create:crushing/obsidian" })
|
||||
event.recipes.create.crushing("create:powdered_obsidian", "minecraft:obsidian")
|
||||
// recompacting obsidian dust into its resource
|
||||
event.recipes.create.compacting("#forge:dusts/obsidian", "minecraft:obsidian")
|
||||
|
||||
// Gravel and red sand washing buffs
|
||||
event.remove({ id: "create:splashing/gravel" })
|
||||
event.recipes.create.splashing([
|
||||
Item.of(Item.of("minecraft:iron_nugget", 2)).withChance(0.125),
|
||||
Item.of("minecraft:flint").withChance(0.25)
|
||||
], "minecraft:gravel")
|
||||
|
||||
event.remove({ id: "create:splashing/red_sand" })
|
||||
event.recipes.create.splashing([
|
||||
Item.of(Item.of("minecraft:gold_nugget", 2)).withChance(0.125),
|
||||
Item.of("minecraft:dead_bush").withChance(0.05)
|
||||
], "minecraft:red_sand")
|
||||
|
||||
// unify dough and allow the slime recipe to take dough from farmer's delight
|
||||
event.remove({ id: "create:crafting/appliances/dough" })
|
||||
event.replaceOutput({ id: "farmersdelight:wheat_dough_from_water" }, "farmersdelight:wheat_dough", "create:dough")
|
||||
event.replaceOutput({ id: "farmersdelight:wheat_dough_from_eggs" }, "farmersdelight:wheat_dough", "create:dough")
|
||||
event.replaceInput({ id: "create:crafting/appliances/slime_ball" }, "create:dough", "#forge:dough")
|
||||
})
|
||||
7
overrides/kubejs/server_scripts/key_mods/createdeco.js
Normal file
7
overrides/kubejs/server_scripts/key_mods/createdeco.js
Normal file
@@ -0,0 +1,7 @@
|
||||
ServerEvents.recipes(event => {
|
||||
// Recipes that don't use item tags when they should be
|
||||
event.replaceInput({id: "createdeco:cast_iron_ingot"}, "createdeco:cast_iron_nugget","#forge:nuggets/cast_iron")
|
||||
event.replaceInput({id: "createdeco:cast_iron_ingot_from_cast_iron_block"}, "createdeco:cast_iron_block","#forge:storage_blocks/cast_iron")
|
||||
event.replaceInput([{id: "createdeco:cast_iron_block"}, {id: "createdeco:cast_iron_nugget_from_cast_iron_ingot"}], "createdeco:cast_iron_ingot","#forge:ingots/cast_iron")
|
||||
event.replaceInput({id: "minecraft:pressing/cast_iron_sheet"}, "createdeco:cast_iron_ingot","#forge:ingots/cast_iron")
|
||||
})
|
||||
44
overrides/kubejs/server_scripts/key_mods/farmersdelight.js
Normal file
44
overrides/kubejs/server_scripts/key_mods/farmersdelight.js
Normal file
@@ -0,0 +1,44 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
// Fix farmer's delight recipe conflict with rechiseled
|
||||
event.remove({ id: "farmersdelight:flint_knife" })
|
||||
event.remove({ id: "farmersdelight:iron_knife" })
|
||||
event.remove({ id: "farmersdelight:golden_knife" })
|
||||
event.remove({ id: "farmersdelight:diamond_knife" })
|
||||
event.shaped("farmersdelight:flint_knife", ["S ", " M"], { M: "minecraft:flint", S: "#forge:rods/wooden" })
|
||||
event.shaped("farmersdelight:iron_knife", ["S ", " M"], { M: "minecraft:iron_ingot", S: "#forge:rods/wooden" })
|
||||
event.shaped("farmersdelight:golden_knife", ["S ", " M"], { M: "minecraft:gold_ingot", S: "#forge:rods/wooden" })
|
||||
event.shaped("farmersdelight:diamond_knife", ["S ", " M"], { M: "minecraft:diamond", S: "#forge:rods/wooden" })
|
||||
|
||||
// Modify farmer's delight log stripping
|
||||
event.remove({ input: "#minecraft:logs", type: "farmersdelight:cutting" })
|
||||
// laziness and its consequences have been a distaster for the human race
|
||||
wood_types.forEach(wood => {
|
||||
let log = wood + "_log"
|
||||
if (!Item.exists(log)) {
|
||||
log = wood + "_stem"
|
||||
}
|
||||
let woodLog = wood + "_wood"
|
||||
if (!Item.exists(woodLog)) {
|
||||
woodLog = wood + "_hyphae"
|
||||
}
|
||||
let strippedLog = log.replace(":",":stripped_")
|
||||
let strippedWood = woodLog.replace(":",":stripped_")
|
||||
if (Item.exists(log) && Item.exists(strippedLog)) {
|
||||
event.custom({
|
||||
"type": "farmersdelight:cutting",
|
||||
"ingredients": [{ "item": log }],
|
||||
"tool": { "tag": "forge:tools/axes" },
|
||||
"result": [{ "item": strippedLog }, { "item": "farmersdelight:tree_bark" }]
|
||||
})
|
||||
}
|
||||
if (Item.exists(woodLog) && Item.exists(strippedWood)) {
|
||||
event.custom({
|
||||
"type": "farmersdelight:cutting",
|
||||
"ingredients": [{ "item": woodLog }],
|
||||
"tool": { "tag": "forge:tools/axes" },
|
||||
"result": [{ "item": strippedWood }, { "item": "farmersdelight:tree_bark" }]
|
||||
})
|
||||
}
|
||||
})
|
||||
})
|
||||
4
overrides/kubejs/server_scripts/key_mods/ftbquests.js
Normal file
4
overrides/kubejs/server_scripts/key_mods/ftbquests.js
Normal file
@@ -0,0 +1,4 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ id:"ftbquests:loot_crate_opener"})
|
||||
})
|
||||
47
overrides/kubejs/server_scripts/key_mods/occultism.js
Normal file
47
overrides/kubejs/server_scripts/key_mods/occultism.js
Normal file
@@ -0,0 +1,47 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
// unify the output
|
||||
event.replaceOutput({ id: "occultism:crushing/obsidian_dust" }, "occultism:obsidian_dust", "create:powdered_obsidian")
|
||||
|
||||
// Remove unwanted ore miner ores
|
||||
event.remove({ id: "occultism:miner/ores/redstone_ore" })
|
||||
event.remove({ id: "occultism:miner/ores/aluminum_ore" })
|
||||
event.remove({ id: "occultism:miner/ores/tin_ore" })
|
||||
event.remove({ id: "occultism:miner/ores/silver_ore" })
|
||||
event.remove({ id: "occultism:miner/deeps/deepslate_redstone_ore" })
|
||||
event.remove({ id: "occultism:miner/deeps/deepslate_aluminum_ore" })
|
||||
event.remove({ id: "occultism:miner/deeps/deepslate_tin_ore" })
|
||||
event.remove({ id: "occultism:miner/deeps/deepslate_silver_ore" })
|
||||
|
||||
// Silver replacements
|
||||
event.replaceInput({ id: "occultism:crafting/magic_lamp_empty" }, "#forge:ingots/silver", "#forge:ingots/iron")
|
||||
event.replaceInput({ id: "occultism:crafting/lens_frame" }, "#forge:ingots/silver", "#forge:ingots/zinc")
|
||||
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:dusts/silver", "#forge:dusts/zinc")
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:ingots/silver", "#forge:ingots/zinc")
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:storage_blocks/silver", "#forge:storage_blocks/zinc")
|
||||
|
||||
// use dust instead of raw ore for ritual recipes
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:raw_materials/silver", "#forge:dusts/zinc")
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:raw_materials/iron", "#forge:dusts/iron")
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:raw_materials/gold", "#forge:dusts/gold")
|
||||
event.replaceInput({ type: "occultism:ritual" }, "#forge:raw_materials/copper", "#forge:dusts/copper")
|
||||
|
||||
|
||||
// crushing unification
|
||||
event.replaceOutput({ type: "occultism:crushing" }, "occultism:iron_dust", "thermal:iron_dust")
|
||||
event.replaceOutput({ type: "occultism:crushing" }, "occultism:gold_dust", "thermal:gold_dust")
|
||||
event.replaceOutput({ type: "occultism:crushing" }, "occultism:copper_dust", "thermal:copper_dust")
|
||||
event.replaceOutput({ type: "occultism:crushing" }, "occultism:iron_dust", "thermal:iron_dust")
|
||||
event.replaceOutput({ type: "occultism:crushing" }, "occultism:gold_dust", "thermal:gold_dust")
|
||||
event.replaceOutput({ type: "occultism:crushing" }, "occultism:silver_dust", "thermal:silver_dust")
|
||||
})
|
||||
|
||||
// PlayerEvents.loggedIn(event => {
|
||||
|
||||
// if (!global.occultism_reload) {
|
||||
// global.occultism_reload = true
|
||||
// event.server.runCommandSilent(`reload`)
|
||||
// }
|
||||
|
||||
// })
|
||||
49
overrides/kubejs/server_scripts/key_mods/projectred_core.js
Normal file
49
overrides/kubejs/server_scripts/key_mods/projectred_core.js
Normal file
@@ -0,0 +1,49 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
// So many recipes that we don't want
|
||||
event.remove({ mod: "projectred_core" })
|
||||
|
||||
// red alloy ingot
|
||||
event.recipes.create.compacting([Item.of("projectred_core:red_ingot")], [Fluid.of("thermal:redstone", 250).toJson(), Item.of("minecraft:copper_ingot")] )
|
||||
|
||||
event.recipes.create.compacting([Item.of("projectred_core:red_ingot")], [Item.of("minecraft:redstone", 4), Item.of("minecraft:copper_ingot")] )
|
||||
|
||||
event.recipes.thermal.smelter("projectred_core:red_ingot", ["minecraft:copper_ingot", "minecraft:redstone"])
|
||||
|
||||
// recreate the circuit plate smelting recipes
|
||||
event.smelting(Item.of("projectred_core:plate", 2), "minecraft:smooth_stone")
|
||||
// recreate illumar recipes
|
||||
colours.forEach(c=>{
|
||||
event.shapeless(`projectred_core:${c}_illumar`, ["minecraft:glowstone_dust", "minecraft:glowstone_dust", "#forge:dyes/" + c, "#forge:dyes/" + c])
|
||||
})
|
||||
// recreate screwdriver recipe
|
||||
event.shaped("projectred_core:screwdriver", [
|
||||
"I ",
|
||||
" IB",
|
||||
" BI"
|
||||
], {
|
||||
I: "#forge:ingots/iron",
|
||||
B: "#forge:dyes/blue"
|
||||
})
|
||||
|
||||
// Platformed plate
|
||||
// The projectred transmission script replaces red ingot with red alloy wire
|
||||
event.shapeless("projectred_core:platformed_plate", [
|
||||
"projectred_core:plate",
|
||||
Platform.isLoaded("projectred_transmission") ? "projectred_transmission:red_alloy_wire" : "projectred_core:red_ingot",
|
||||
"create:andesite_alloy"
|
||||
]).id("kubejs:platformed_plate")
|
||||
// Circuit cutting. Projectred Transmission circuit recipes are added in the circuit script in the mods folder
|
||||
let circuit = (id, override) => {
|
||||
if (override)
|
||||
event.remove({ output: id })
|
||||
event.stonecutting(Item.of(id, 1), "projectred_core:platformed_plate")
|
||||
}
|
||||
circuit("minecraft:repeater", false)
|
||||
circuit("minecraft:comparator", false)
|
||||
circuit("create:pulse_repeater", true)
|
||||
circuit("create:pulse_extender", true)
|
||||
circuit("create:pulse_timer", true)
|
||||
circuit("create:powered_latch", true)
|
||||
circuit("create:powered_toggle_latch", true)
|
||||
})
|
||||
278
overrides/kubejs/server_scripts/key_mods/tconstruct.js
Normal file
278
overrides/kubejs/server_scripts/key_mods/tconstruct.js
Normal file
@@ -0,0 +1,278 @@
|
||||
// priority: 1
|
||||
|
||||
wood_types.push("tconstruct:greenheart")
|
||||
wood_types.push("tconstruct:skyroot")
|
||||
wood_types.push("tconstruct:bloodshroom")
|
||||
wood_types.push("tconstruct:enderbark")
|
||||
|
||||
ServerEvents.recipes(event => {
|
||||
|
||||
// It is possible to duplicate rails in 1.20.1 Minecraft, so we need to remove rail melting
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": [
|
||||
{
|
||||
"item": "minecraft:iron_bars"
|
||||
}
|
||||
],
|
||||
"result": {
|
||||
"amount": 30,
|
||||
"tag": "forge:molten_iron"
|
||||
},
|
||||
"temperature": 800,
|
||||
"time": 35
|
||||
}).id("tconstruct:smeltery/melting/metal/iron/nugget_3")
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": [
|
||||
{
|
||||
"item": "minecraft:stonecutter"
|
||||
},
|
||||
{
|
||||
"item": "minecraft:piston"
|
||||
},
|
||||
{
|
||||
"item": "minecraft:sticky_piston"
|
||||
}
|
||||
],
|
||||
"result": {
|
||||
"amount": 90,
|
||||
"tag": "forge:molten_iron"
|
||||
},
|
||||
"temperature": 800,
|
||||
"time": 60
|
||||
}).id("tconstruct:smeltery/melting/metal/iron/ingot_1")
|
||||
event.remove({ id: "tconstruct:smeltery/melting/metal/gold/powered_rail" })
|
||||
|
||||
// Obsidian pane crafting
|
||||
// Not sure where the original recipe went
|
||||
event.shaped(Item.of("tconstruct:obsidian_pane", 8), [
|
||||
"SSS",
|
||||
"SSS"
|
||||
], {
|
||||
S: "minecraft:obsidian"
|
||||
})
|
||||
// melt blaze rods into blazing blood
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": { "tag": "forge:rods/blaze" },
|
||||
"result": { "fluid": "tconstruct:blazing_blood", "amount": 100 },
|
||||
"temperature": 790,
|
||||
"time": 40
|
||||
})
|
||||
// Melt redstone into destabilized redstone
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": { "item": "minecraft:redstone" },
|
||||
"result": { "fluid": "thermal:redstone", "amount": 100 },
|
||||
"temperature": 300,
|
||||
"time": 10
|
||||
});
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": { "item": "minecraft:redstone_block" },
|
||||
"result": { "fluid": "thermal:redstone", "amount": 900 },
|
||||
"temperature": 500,
|
||||
"time": 90
|
||||
});
|
||||
// Remove coin cast
|
||||
event.remove({ id: "tconstruct:smeltery/casts/sand_casts/coins" })
|
||||
event.remove({ id: "tconstruct:smeltery/casts/red_sand_casts/coins" })
|
||||
event.remove({ id: "tconstruct:smeltery/casts/gold_casts/coins" })
|
||||
|
||||
let coinMaterials = [
|
||||
"iron",
|
||||
"gold",
|
||||
"copper",
|
||||
"netherite",
|
||||
"tin",
|
||||
"lead",
|
||||
"silver",
|
||||
"nickel",
|
||||
"bronze",
|
||||
"electrum",
|
||||
"invar",
|
||||
"constantan",
|
||||
"signalum",
|
||||
"lumium",
|
||||
"enderium"
|
||||
];
|
||||
coinMaterials.forEach(material => {
|
||||
event.remove({ id: `tconstruct:smeltery/casting/metal/${material}/coin_gold_cast` })
|
||||
event.remove({ id: `tconstruct:smeltery/casting/metal/${material}/coin_sand_cast` })
|
||||
})
|
||||
// Chains can be crafted using Zinc
|
||||
event.remove({ id: "tconstruct:smeltery/melting/metal/iron/chain" })
|
||||
// Remove enchanted apple melting recipe
|
||||
event.remove({ id: "tconstruct:smeltery/melting/metal/gold/enchanted_apple" })
|
||||
// Remove Tconstruct cheese since it only costs milk to craft and cheese already exists on the moon.
|
||||
event.remove({ id: "tconstruct:smeltery/casting/cheese_block" })
|
||||
event.remove({ id: "tconstruct:smeltery/casting/cheese_ingot_gold_cast" })
|
||||
event.remove({ id: "tconstruct:smeltery/casting/cheese_ingot_sand_cast" })
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
// zinc anvils
|
||||
event.get("tconstruct:anvil_metal").add("create:zinc_block")
|
||||
event.remove("tconstruct:anvil_metal", "#forge:storage_blocks/bronze")
|
||||
|
||||
event.add("forge:ingots/seared_brick", "tconstruct:seared_brick")
|
||||
event.add("forge:ingots/scorched_brick", "tconstruct:scorched_brick")
|
||||
})
|
||||
|
||||
ServerEvents.tags("block", event => {
|
||||
event.remove("tconstruct:anvil_metal", "#forge:storage_blocks/bronze")
|
||||
|
||||
event.get("tconstruct:mineable/melting_blacklist")
|
||||
.add("#forge:storage_blocks/raw_iron")
|
||||
.add("#forge:storage_blocks/raw_copper")
|
||||
.add("#forge:storage_blocks/raw_gold")
|
||||
.add("#forge:storage_blocks/raw_zinc")
|
||||
.add("#forge:storage_blocks/raw_lead")
|
||||
.add("#forge:storage_blocks/raw_nickel")
|
||||
})
|
||||
|
||||
ServerEvents.highPriorityData(event => {
|
||||
// Use crushed ore instead of raw ore for the autosmelt modifier
|
||||
event.addJson("tconstruct:recipes/tools/modifiers/ability/autosmelt", {
|
||||
"type": "tconstruct:modifier",
|
||||
"allow_crystal": true,
|
||||
"check_trait_level": true,
|
||||
"inputs": [
|
||||
{ "tag": "create:crushed_raw_materials" },
|
||||
{ "item": "minecraft:blast_furnace" },
|
||||
{ "tag": "forge:ingots" },
|
||||
{ "tag": "forge:storage_blocks/coal" },
|
||||
{ "tag": "forge:storage_blocks/coal" }
|
||||
],
|
||||
"level": 1,
|
||||
"result": "tconstruct:autosmelt",
|
||||
"slots": { "abilities": 1 },
|
||||
"tools": { "tag": "tconstruct:modifiable/harvest" }
|
||||
})
|
||||
|
||||
// Make Melting exclusive to the melting pan
|
||||
event.addJson("tconstruct:recipes/tools/modifiers/ability/melting", {
|
||||
"type": "tconstruct:modifier",
|
||||
"allow_crystal": true,
|
||||
"check_trait_level": true,
|
||||
"inputs": [
|
||||
{
|
||||
"item": "minecraft:blaze_rod"
|
||||
},
|
||||
{
|
||||
"ingredient": [
|
||||
{
|
||||
"item": "tconstruct:seared_melter"
|
||||
},
|
||||
{
|
||||
"item": "tconstruct:smeltery_controller"
|
||||
},
|
||||
{
|
||||
"item": "tconstruct:foundry_controller"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"item": "minecraft:blaze_rod"
|
||||
},
|
||||
{
|
||||
"item": "minecraft:lava_bucket"
|
||||
},
|
||||
{
|
||||
"item": "minecraft:lava_bucket"
|
||||
}
|
||||
],
|
||||
"level": 1,
|
||||
"result": "tconstruct:melting",
|
||||
"slots": {
|
||||
"abilities": 1
|
||||
},
|
||||
"tools": [
|
||||
{
|
||||
"item": "tconstruct:melting_pan"
|
||||
}
|
||||
]
|
||||
})
|
||||
|
||||
event.addJson("tconstruct:tinkering/tool_definitions/melting_pan", {
|
||||
"modules": [
|
||||
{
|
||||
"type": "tconstruct:material_stats",
|
||||
"primary_part": 0,
|
||||
"stat_types": [
|
||||
"tconstruct:plating_shield",
|
||||
"tconstruct:limb"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:default_materials",
|
||||
"materials": [
|
||||
{
|
||||
"type": "tconstruct:random"
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:random"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:material_traits",
|
||||
"hooks": [
|
||||
"tconstruct:rebalanced_trait"
|
||||
],
|
||||
"material_index": 1,
|
||||
"stat_type": "tconstruct:limb"
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:base_stats",
|
||||
"stats": {
|
||||
"tconstruct:block_amount": 10.0,
|
||||
"tconstruct:harvest_tier": "minecraft:iron",
|
||||
"tconstruct:knockback_resistance": 0.1,
|
||||
"tconstruct:mining_speed": 6.0
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:modifier_slots",
|
||||
"slots": {
|
||||
"abilities": 2,
|
||||
"defense": 1,
|
||||
"upgrades": 1
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:melting_fluid_effective",
|
||||
"ignore_tier": false,
|
||||
"inverted_type": "mantle:tag",
|
||||
"predicate_type": "mantle:inverted",
|
||||
"tag": "tconstruct:mineable/melting_blacklist",
|
||||
"temperature": 1500
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:volatile_flag",
|
||||
"flag": "tconstruct:force_melting"
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:vein_aoe",
|
||||
"max_distance": 0
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:traits",
|
||||
"traits": [
|
||||
{
|
||||
"level": 2,
|
||||
"name": "tconstruct:melting"
|
||||
},
|
||||
{
|
||||
"level": 1,
|
||||
"name": "tconstruct:tank"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "tconstruct:dual_option_interaction"
|
||||
}
|
||||
]
|
||||
})
|
||||
})
|
||||
220
overrides/kubejs/server_scripts/key_mods/thermal.js
Normal file
220
overrides/kubejs/server_scripts/key_mods/thermal.js
Normal file
@@ -0,0 +1,220 @@
|
||||
// priority: 1
|
||||
|
||||
wood_types.push("thermal:rubberwood")
|
||||
ServerEvents.recipes(event => {
|
||||
// filter augment recipe change
|
||||
event.remove({ id: "thermal:augments/item_filter_augment" })
|
||||
event.shapeless("thermal:item_filter_augment", ["create:filter", "thermal:lapis_gear"])
|
||||
// Augments that do nothing in 1.18.2
|
||||
event.remove({ id: "thermal:augments/rs_control_augment" })
|
||||
event.remove({ id: "thermal:augments/side_config_augment" })
|
||||
// Silver replacements
|
||||
event.replaceInput({ id: "thermal:augments/rf_coil_storage_augment" }, "#forge:ingots/silver", "#forge:ingots/iron")
|
||||
event.replaceInput({ id: "thermal:augments/rf_coil_xfer_augment" }, "#forge:ingots/silver", "#forge:ingots/iron")
|
||||
event.replaceInput({ id: "thermal:augments/rf_coil_augment" }, "#forge:ingots/silver", "#forge:ingots/iron")
|
||||
event.replaceInput({ id: "thermal:tools/detonator" }, "#forge:ingots/silver", "#forge:ingots/lead")
|
||||
// why are these even recipes?
|
||||
event.remove({ id: "thermal:lightning_charge/zombified_piglin_from_pig"})
|
||||
event.remove({ id: "thermal:lightning_charge/witch_from_villager"})
|
||||
// duplicate storage block recipes
|
||||
event.remove({ id: "thermal:storage/carrot_block" })
|
||||
event.remove({ id: "thermal:storage/potato_block" })
|
||||
event.remove({ id: "thermal:storage/beetroot_block" })
|
||||
// Obsidian pulverizing
|
||||
event.recipes.thermal.pulverizer(["create:powdered_obsidian"], "#forge:obsidian", 0, 8000)
|
||||
// Ender pearl pulverizing
|
||||
event.replaceOutput({ id: "thermal:machines/pulverizer/pulverizer_ender_pearl" }, "thermal:ender_pearl_dust", "ae2:ender_dust")
|
||||
event.replaceOutput({ id: "thermal:earth_charge/ender_pearl_dust_from_ender_pearl" }, "thermal:ender_pearl_dust", "ae2:ender_dust")
|
||||
// Bitumen crushing recipes
|
||||
event.recipes.create.crushing([Item.of("thermal:bitumen"), Item.of("thermal:bitumen", 2).withChance(0.75), Item.of("thermal:tar", 1).withChance(0.75), Item.of("minecraft:sand").withChance(0.25)], "thermal:oil_sand")
|
||||
event.recipes.create.crushing([Item.of("thermal:bitumen"), Item.of("thermal:bitumen", 2).withChance(0.75), Item.of("thermal:tar", 1).withChance(0.75), Item.of("minecraft:red_sand").withChance(0.25)], "thermal:oil_red_sand")
|
||||
// ruby and sapphire block recipes
|
||||
let blockTemplate = [ "III", "III", "III" ]
|
||||
event.shaped(Item.of("thermal:ruby_block", 1), blockTemplate, { I: "#forge:gems/ruby"})
|
||||
event.shapeless(Item.of("thermal:ruby", 9), ["#forge:storage_blocks/ruby"])
|
||||
event.shaped(Item.of("thermal:sapphire_block", 1), blockTemplate, { I: "#forge:gems/sapphire"})
|
||||
event.shapeless(Item.of("thermal:sapphire", 9), ["#forge:storage_blocks/sapphire"])
|
||||
// Ruby and sapphire dusts from pulverizing
|
||||
event.recipes.thermal.pulverizer("thermal:sapphire_dust", "thermal:sapphire", 0, 4000)
|
||||
event.recipes.thermal.pulverizer("thermal:ruby_dust", "thermal:ruby", 0, 4000)
|
||||
// Ruby and sapphire dusts from earth charges
|
||||
event.shapeless(Item.of("thermal:ruby_dust"), ["#forge:gems/ruby", "thermal:earth_charge"])
|
||||
event.shapeless(Item.of("thermal:sapphire_dust"), ["#forge:gems/sapphire", "thermal:earth_charge"])
|
||||
// Make molten glass with the cruicible
|
||||
event.recipes.thermal.crucible(Fluid.of("tconstruct:molten_glass", 1000), "#forge:sand", 0, 6000)
|
||||
event.recipes.thermal.crucible(Fluid.of("tconstruct:molten_glass", 1000), "#forge:glass/colorless", 0, 3000)
|
||||
// Gourmand fuel recipes for farmer's delight crates
|
||||
event.custom({"type": "thermal:gourmand_fuel", "ingredient": {"item": "farmersdelight:carrot_crate"}, "energy": 48000})
|
||||
event.custom({"type": "thermal:gourmand_fuel", "ingredient": {"item": "farmersdelight:potato_crate"}, "energy": 16000})
|
||||
event.custom({"type": "thermal:gourmand_fuel", "ingredient": {"item": "farmersdelight:beetroot_crate"}, "energy": 16000})
|
||||
event.custom({"type": "thermal:gourmand_fuel", "ingredient": {"item": "farmersdelight:cabbage_crate"}, "energy": 32000})
|
||||
event.custom({"type": "thermal:gourmand_fuel", "ingredient": {"item": "farmersdelight:onion_crate"}, "energy": 32000})
|
||||
event.custom({"type": "thermal:gourmand_fuel", "ingredient": {"item": "farmersdelight:tomato_crate"}, "energy": 16000})
|
||||
// Igneous Extruder recipes
|
||||
let bedrock_cobblegen = (adjacent, output) => {
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": adjacent,
|
||||
"below": "minecraft:bedrock",
|
||||
"result": { "item": output }
|
||||
})
|
||||
}
|
||||
bedrock_cobblegen("minecraft:packed_ice", "minecraft:andesite")
|
||||
bedrock_cobblegen("architects_palette:polished_packed_ice", "minecraft:granite")
|
||||
bedrock_cobblegen("architects_palette:chiseled_packed_ice", "minecraft:diorite")
|
||||
// Also add igneous extruder recipes for the 2 create stone gen recipes
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": "create:chocolate",
|
||||
"result": { "item": "create:scoria"}
|
||||
})
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": "create:honey",
|
||||
"result": { "item": "create:limestone"}
|
||||
})
|
||||
|
||||
// thermal dynamics stuff
|
||||
// thermal dynamics might be split into a compatability mod eventually
|
||||
|
||||
// Energy duct recipe change
|
||||
event.remove({ output: "thermal:energy_duct" })
|
||||
event.shaped("8x thermal:energy_duct", [ "PMP" ], {
|
||||
P: "thermal:invar_ingot",
|
||||
M: "minecraft:redstone"
|
||||
})
|
||||
|
||||
// Remove existing insolator flower recipes since we're adding them back anyways
|
||||
event.remove({ type: "thermal:insolator", input: "#minecraft:flowers", not:{ input:"#minecraft:saplings" } })
|
||||
|
||||
Ingredient.of("#minecraft:flowers").itemIds.forEach(flower => {
|
||||
// Automatically adds all flowers as thermal insolator recipes. We're blacklisting special cases like leaves and saplings which are occasionally tagged as flowers for some reason
|
||||
if( !( Ingredient.of("#minecraft:saplings").test(flower) || Ingredient.of("#minecraft:leaves").test(flower) ) ) {
|
||||
event.custom({
|
||||
"type": "thermal:insolator",
|
||||
"ingredient": {
|
||||
"item": flower
|
||||
},
|
||||
"result": [
|
||||
{
|
||||
"item": flower,
|
||||
"chance": 2
|
||||
}
|
||||
],
|
||||
"experience": 0
|
||||
})
|
||||
}
|
||||
})
|
||||
|
||||
// port melting recipes for dusts, ingots and gems
|
||||
const TICMETALS = [
|
||||
"aluminum",
|
||||
"amethyst_bronze",
|
||||
"brass",
|
||||
"bronze",
|
||||
"cobalt",
|
||||
"constantan",
|
||||
// "copper",
|
||||
"electrum",
|
||||
"enderium",
|
||||
// "gold",
|
||||
"hepatizon",
|
||||
"invar",
|
||||
// "iron",
|
||||
"knightslime",
|
||||
// "lead",
|
||||
"lumium",
|
||||
"manyullyn",
|
||||
"netherite",
|
||||
// "nickel",
|
||||
"osmium",
|
||||
"pewter",
|
||||
"pig_iron",
|
||||
"platinum",
|
||||
"queens_slime",
|
||||
"refined_glowstone",
|
||||
"refined_obsidian",
|
||||
"rose_gold",
|
||||
"signalum",
|
||||
"silver",
|
||||
"slimesteel",
|
||||
"soulsteel",
|
||||
"steel",
|
||||
"tin",
|
||||
"tungsten",
|
||||
"uranium"// ,
|
||||
// "zinc"
|
||||
];
|
||||
const TICGEMS = [
|
||||
"diamond",
|
||||
"emerald",
|
||||
"quartz",
|
||||
"amethyst",
|
||||
]
|
||||
|
||||
TICMETALS.forEach(metal=>{
|
||||
if (Ingredient.of(`#forge:dusts/${metal}`).first != Item.empty) {
|
||||
event.custom({
|
||||
type:"thermal:crucible",
|
||||
ingredients:{tag: `forge:dusts/${metal}`},
|
||||
result:{fluid: `tconstruct:molten_${metal}`, amount: 90},
|
||||
energy:5000
|
||||
}).id(`kubejs:crucible/${metal}/dust`)
|
||||
}
|
||||
})
|
||||
TICMETALS.concat(["copper", "gold", "iron", "lead", "nickel", "zinc"]).forEach(metal=>{
|
||||
let ingotTag = `forge:ingots/${metal}`
|
||||
let rodTag = `forge:rods/${metal}`
|
||||
|
||||
let fluid = `tconstruct:molten_${metal}`
|
||||
|
||||
if (Ingredient.of("#" + ingotTag).first != Item.empty) {
|
||||
event.recipes.thermal.crucible(Fluid.of(fluid, 90), "#" + ingotTag, 0, 5000).id(`kubejs:crucible/${metal}/ingot`)
|
||||
|
||||
event.recipes.thermal.chiller(getPreferredItemFromTag(ingotTag), [Fluid.of(fluid, 90), "thermal:chiller_ingot_cast"]).id(`kubejs:chiller/${metal}/ingot`)
|
||||
}
|
||||
if (Ingredient.of("#" + rodTag).first != Item.empty) {
|
||||
event.recipes.thermal.chiller(getPreferredItemFromTag(rodTag), [Fluid.of(fluid, 45), "thermal:chiller_rod_cast"]).id(`kubejs:chiller/${metal}/rod`)
|
||||
}
|
||||
})
|
||||
TICGEMS.forEach(gem=>{
|
||||
let gemTag = `forge:gems/${gem}`
|
||||
|
||||
let fluid = `tconstruct:molten_${gem}`
|
||||
|
||||
if (Ingredient.of(`#forge:gems/${gem}`).first != Item.empty) {
|
||||
event.recipes.thermal.crucible(Fluid.of(fluid, 100), "#" + gemTag, 0, 5000).id(`kubejs:crucible/${gem}/gem`)
|
||||
}
|
||||
})
|
||||
|
||||
const OTHER_INGOTS = [
|
||||
{name: "brick", fluid: "tconstruct:molten_clay"},
|
||||
{name: "seared_brick", fluid: "tconstruct:seared_stone"},
|
||||
{name: "scorched_brick", fluid: "tconstruct:scorched_stone"},
|
||||
{name: "netherite_scrap", fluid: "tconstruct:molten_debris"}
|
||||
]
|
||||
OTHER_INGOTS.forEach(material=>{
|
||||
let name = material.name
|
||||
let ingotTag = "forge:ingots/" + material.name
|
||||
let fluid = material.fluid
|
||||
|
||||
if (Ingredient.of("#" + ingotTag).first != Item.empty) {
|
||||
event.recipes.thermal.crucible(Fluid.of(fluid, 90), "#" + ingotTag, 0, 5000).id(`kubejs:crucible/${name}`)
|
||||
|
||||
event.recipes.thermal.chiller(getPreferredItemFromTag(ingotTag), [Fluid.of(fluid, 90), "thermal:chiller_ingot_cast"]).id(`kubejs:chiller/${name}`)
|
||||
}
|
||||
})
|
||||
|
||||
// Ball recipes
|
||||
event.recipes.thermal.chiller("minecraft:slime_ball", [Fluid.of("tconstruct:earth_slime", 250), "thermal:chiller_ball_cast"]).id("kubejs:chiller/slime_ball");
|
||||
event.recipes.thermal.chiller("tconstruct:sky_slime_ball", [Fluid.of("tconstruct:sky_slime", 250), "thermal:chiller_ball_cast"]).id("kubejs:chiller/sky_slime_ball");
|
||||
event.recipes.thermal.chiller("tconstruct:ender_slime_ball", [Fluid.of("tconstruct:ender_slime", 250), "thermal:chiller_ball_cast"]).id("kubejs:chiller/ender_slime_ball");
|
||||
event.recipes.thermal.chiller("tconstruct:blood_slime_ball", [Fluid.of("tconstruct:blood", 250), "thermal:chiller_ball_cast"]).id("kubejs:chiller/blood_slime_ball");
|
||||
})
|
||||
|
||||
|
||||
ServerEvents.lowPriorityData(event => {
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/thermal/beetroot_block", ["farmersdelight:beetroot_crate", "thermal:beetroot_block"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/thermal/carrot_block", ["farmersdelight:carrot_crate", "thermal:carrot_block"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/thermal/potato_block", ["farmersdelight:potato_crate", "thermal:potato_block"])
|
||||
})
|
||||
@@ -0,0 +1,9 @@
|
||||
// priority: 1
|
||||
ServerEvents.recipes(event => {
|
||||
// Might be considered as part of chapter 1
|
||||
event.remove({ output: "strainers:iron_mesh" })
|
||||
|
||||
let strainerPattern = ["SSS", "MAM", "SSS"]
|
||||
event.shaped("kubejs:strainer_filter", strainerPattern,
|
||||
{ A: "farmersdelight:canvas", M: "farmersdelight:canvas", S: "minecraft:stick" }).id("kubejs:sediment_strainer")
|
||||
})
|
||||
100
overrides/kubejs/server_scripts/loot.js
Normal file
100
overrides/kubejs/server_scripts/loot.js
Normal file
@@ -0,0 +1,100 @@
|
||||
let metal_ores_drop_dust = (id, crushedId, dustId) => {
|
||||
return {
|
||||
"type": "minecraft:block",
|
||||
"pools": [
|
||||
{
|
||||
"rolls": 1,
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:alternatives",
|
||||
"children": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": dustId,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
"count": 9
|
||||
}
|
||||
],
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "tconstruct:has_modifier",
|
||||
"modifier": "tconstruct:melting"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": id,
|
||||
"conditions": [
|
||||
{
|
||||
"condition": "minecraft:match_tool",
|
||||
"predicate": {
|
||||
"enchantments": [
|
||||
{
|
||||
"enchantment": "minecraft:silk_touch",
|
||||
"levels": {
|
||||
"min": 1
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"name": crushedId,
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
"count":
|
||||
{
|
||||
"min": 2.0,
|
||||
"max": 3.0,
|
||||
"type": "minecraft:uniform"
|
||||
}
|
||||
},
|
||||
{
|
||||
"function": "minecraft:apply_bonus",
|
||||
"enchantment": "minecraft:fortune",
|
||||
"formula": "minecraft:uniform_bonus_count",
|
||||
"parameters": { "bonusMultiplier": 1 }
|
||||
},
|
||||
{
|
||||
"function": "minecraft:explosion_decay"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
ServerEvents.blockLootTables(event => {
|
||||
|
||||
event.addSimpleBlock("minecraft:twisting_vines", "minecraft:twisting_vines")
|
||||
event.addSimpleBlock("minecraft:weeping_vines", "minecraft:weeping_vines")
|
||||
|
||||
let extra_ores = ["minecraft:", "minecraft:deepslate_"]
|
||||
|
||||
extra_ores.forEach(e => {
|
||||
let iron = e + "iron_ore"
|
||||
event.addJson(iron, metal_ores_drop_dust(iron, "create:crushed_raw_iron", "thermal:iron_dust"))
|
||||
let gold = e + "gold_ore"
|
||||
event.addJson(gold, metal_ores_drop_dust(gold, "create:crushed_raw_gold", "thermal:gold_dust"))
|
||||
})
|
||||
event.addJson("minecraft:copper_ore", metal_ores_drop_dust("minecraft:copper_ore", "create:crushed_raw_copper", "thermal:copper_dust"))
|
||||
event.addJson("minecraft:deepslate_copper_ore", metal_ores_drop_dust("minecraft:deepslate_copper_ore", "create:crushed_raw_copper", "thermal:copper_dust"))
|
||||
event.addJson("create:zinc_ore", metal_ores_drop_dust("create:zinc_ore", "create:crushed_raw_zinc", "kubejs:zinc_dust"))
|
||||
event.addJson("create:deepslate_zinc_ore", metal_ores_drop_dust("create:deepslate_zinc_ore", "create:crushed_raw_zinc", "kubejs:zinc_dust"))
|
||||
event.addJson("thermal:nickel_ore", metal_ores_drop_dust("thermal:nickel_ore", "create:crushed_raw_nickel", "thermal:nickel_dust"))
|
||||
event.addJson("thermal:deepslate_nickel_ore", metal_ores_drop_dust("thermal:deepslate_nickel_ore", "create:crushed_raw_nickel", "thermal:nickel_dust"))
|
||||
event.addJson("thermal:lead_ore", metal_ores_drop_dust("thermal:lead_ore", "create:crushed_raw_lead", "thermal:lead_dust"))
|
||||
event.addJson("thermal:deepslate_lead_ore", metal_ores_drop_dust("thermal:deepslate_lead_ore", "create:crushed_raw_lead", "thermal:lead_dust"))
|
||||
event.addJson("ad_astra:moon_iron_ore", metal_ores_drop_dust("ad_astra:moon_iron_ore", "create:crushed_raw_iron", "thermal:iron_dust"))
|
||||
})
|
||||
4
overrides/kubejs/server_scripts/mods/_mods_readme.md
Normal file
4
overrides/kubejs/server_scripts/mods/_mods_readme.md
Normal file
@@ -0,0 +1,4 @@
|
||||
Mods Scripts for CABIN
|
||||
These are mods that are installed in the pack by default but aren't necessary for beating the modpack.
|
||||
Some people may want to remove a mod from here in favour of adding a mod from the compatability scripts or an entirely different mod.
|
||||
Be aware that some of the side content quests may not work after a mod is removed. The main quest line will remain in tact though.
|
||||
7
overrides/kubejs/server_scripts/mods/aquaculture.js
Normal file
7
overrides/kubejs/server_scripts/mods/aquaculture.js
Normal file
@@ -0,0 +1,7 @@
|
||||
if(Platform.isLoaded("aquaculture")) {
|
||||
unregistered_axes.push("aquaculture:neptunium_axe")
|
||||
|
||||
ServerEvents.recipes(event => {
|
||||
event.recipes.create.crushing([Item.of(Item.of("aquaculture:neptunium_ingot", 2)), Item.of(Item.of("aquaculture:neptunium_nugget", 5)).withChance(.5)], "aquaculture:neptunes_bounty").processingTime(500)
|
||||
})
|
||||
}
|
||||
18
overrides/kubejs/server_scripts/mods/balancedflight.js
Normal file
18
overrides/kubejs/server_scripts/mods/balancedflight.js
Normal file
@@ -0,0 +1,18 @@
|
||||
if(Platform.isLoaded("balancedflight")) {
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ mod: "balancedflight" })
|
||||
event.recipes.create.sequenced_assembly([
|
||||
"balancedflight:flight_anchor",
|
||||
], "minecraft:beacon", [
|
||||
event.recipes.create.deploying("kubejs:incomplete_flight_anchor", ["kubejs:incomplete_flight_anchor", "kubejs:gold_machine"]),
|
||||
event.recipes.create.deploying("kubejs:incomplete_flight_anchor", ["kubejs:incomplete_flight_anchor", "kubejs:inductive_mechanism"]),
|
||||
event.recipes.create.deploying("kubejs:incomplete_flight_anchor", ["kubejs:incomplete_flight_anchor", "kubejs:inductive_mechanism"]),
|
||||
event.recipes.create.deploying("kubejs:incomplete_flight_anchor", ["kubejs:incomplete_flight_anchor", "create:shaft"]),
|
||||
event.recipes.create.deploying("kubejs:incomplete_flight_anchor", ["kubejs:incomplete_flight_anchor", Platform.isLoaded("magicfeather") ? "magicfeather:magicfeather" : "minecraft:elytra"]),
|
||||
]).loops(1)
|
||||
.transitionalItem("kubejs:incomplete_flight_anchor")
|
||||
.id("kubejs:compat/balancedflight/flight_anchor")
|
||||
|
||||
event.remove({output: "balancedflight:ascended_flight_ring"})
|
||||
})
|
||||
}
|
||||
139
overrides/kubejs/server_scripts/mods/biomesoplenty.js
Normal file
139
overrides/kubejs/server_scripts/mods/biomesoplenty.js
Normal file
@@ -0,0 +1,139 @@
|
||||
if(Platform.isLoaded("biomesoplenty")) {
|
||||
wood_types.push("biomesoplenty:fir")
|
||||
wood_types.push("biomesoplenty:pine")
|
||||
wood_types.push("biomesoplenty:maple")
|
||||
wood_types.push("biomesoplenty:redwood")
|
||||
wood_types.push("biomesoplenty:mahogany")
|
||||
wood_types.push("biomesoplenty:jacaranda")
|
||||
wood_types.push("biomesoplenty:palm")
|
||||
wood_types.push("biomesoplenty:willow")
|
||||
wood_types.push("biomesoplenty:dead")
|
||||
wood_types.push("biomesoplenty:magic")
|
||||
wood_types.push("biomesoplenty:umbran")
|
||||
wood_types.push("biomesoplenty:hellbark")
|
||||
wood_types.push("biomesoplenty:empyreal")
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
// Has the block tag but not the item tag
|
||||
event.add("minecraft:flowers", "biomesoplenty:waterlily")
|
||||
|
||||
event.get("forge:vines").add("biomesoplenty:willow_vine").add("biomesoplenty:spanish_moss")
|
||||
|
||||
event.get("kubejs:strainer/sands").add("biomesoplenty:white_sand").add("biomesoplenty:orange_sand")
|
||||
})
|
||||
ServerEvents.recipes(event => {
|
||||
// Tree Extracting recipes for leaves that don't match their log names
|
||||
addTreeOutput(event, "minecraft:oak_log", "biomesoplenty:origin_leaves")
|
||||
addTreeOutput(event, "minecraft:oak_log", "biomesoplenty:flowering_oak_leaves")
|
||||
addTreeOutput(event, "minecraft:spruce_log", "biomesoplenty:cypress_leaves")
|
||||
addTreeOutput(event, "minecraft:birch_log", "biomesoplenty:rainbow_birch_leaves")
|
||||
addTreeOutput(event, "minecraft:cherry_log", "biomesoplenty:snowblossom_leaves")
|
||||
addTreeOutput(event, "biomesoplenty:maple_log", "biomesoplenty:yellow_maple_leaves")
|
||||
addTreeOutput(event, "biomesoplenty:maple_log", "biomesoplenty:orange_maple_leaves")
|
||||
addTreeOutput(event, "biomesoplenty:maple_log", "biomesoplenty:red_maple_leaves")
|
||||
|
||||
// kubejs throws a duplicate recipe error, we'd need to change how resin recipes are created to avoid that error
|
||||
// event.custom({
|
||||
// type: "thermal:tree_extractor",
|
||||
// trunk: {
|
||||
// Name: "biomesoplenty:magic_log",
|
||||
// Properties: {
|
||||
// axis: "y"
|
||||
// }
|
||||
// },
|
||||
// leaves: {
|
||||
// Name: "biomesoplenty:magic_leaves",
|
||||
// Properties: {
|
||||
// persistent: "false"
|
||||
// }
|
||||
// },
|
||||
// result: {
|
||||
// fluid: "create:potion",
|
||||
// amount: 25,
|
||||
// nbt: {
|
||||
// Bottle: 'REGULAR',
|
||||
// Potion: "minecraft:thick"
|
||||
// }
|
||||
// }
|
||||
// })//.id('kubejs:devices/tree_extractor/tree_extractor_magic')
|
||||
|
||||
// Wash sand into clay
|
||||
event.recipes.create.splashing([Item.of("minecraft:clay_ball", 1).withChance(0.25)], "biomesoplenty:black_sand")
|
||||
event.recipes.create.splashing([Item.of("minecraft:clay_ball", 1).withChance(0.25)], "biomesoplenty:white_sand")
|
||||
event.recipes.create.splashing([Item.of("minecraft:clay_ball", 1).withChance(0.25)], "biomesoplenty:orange_sand")
|
||||
// Flesh igeneous extruder recipe.
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": "biomesoplenty:blood",
|
||||
"result": { "item": "biomesoplenty:flesh"}
|
||||
})
|
||||
})
|
||||
|
||||
// Fix biome tags
|
||||
// onEvent("tags.worldgen.biome", event=>{
|
||||
// const BOP_OVERWORLD = [
|
||||
// "biomesoplenty:bamboo_grove",
|
||||
// "biomesoplenty:bayou",
|
||||
// "biomesoplenty:bog",
|
||||
// "biomesoplenty:boreal_forest",
|
||||
// "biomesoplenty:cherry_blossom_grove",
|
||||
// "biomesoplenty:clover_patch",
|
||||
// "biomesoplenty:cold_desert",
|
||||
// "biomesoplenty:coniferous_forest",
|
||||
// "biomesoplenty:crag",
|
||||
// "biomesoplenty:dead_forest",
|
||||
// "biomesoplenty:dryland",
|
||||
// "biomesoplenty:dune_beach",
|
||||
// "biomesoplenty:field",
|
||||
// "biomesoplenty:fir_clearing",
|
||||
// "biomesoplenty:floodplain",
|
||||
// "biomesoplenty:forested_field",
|
||||
// "biomesoplenty:fungal_jungle",
|
||||
// "biomesoplenty:glowing_grotto",
|
||||
// "biomesoplenty:grassland",
|
||||
// "biomesoplenty:highland",
|
||||
// "biomesoplenty:highland_moor",
|
||||
// "biomesoplenty:jade_cliffs",
|
||||
// "biomesoplenty:lavender_field",
|
||||
// "biomesoplenty:lavender_forest",
|
||||
// "biomesoplenty:lush_desert",
|
||||
// "biomesoplenty:lush_savanna",
|
||||
// "biomesoplenty:maple_woods",
|
||||
// "biomesoplenty:marsh",
|
||||
// "biomesoplenty:mediterranean_forest",
|
||||
// "biomesoplenty:muskeg",
|
||||
// "biomesoplenty:mystic_grove",
|
||||
// "biomesoplenty:old_growth_dead_forest",
|
||||
// "biomesoplenty:old_growth_woodland",
|
||||
// "biomesoplenty:ominous_woods",
|
||||
// "biomesoplenty:orchard",
|
||||
// "biomesoplenty:origin_valley",
|
||||
// "biomesoplenty:pasture",
|
||||
// "biomesoplenty:prairie",
|
||||
// "biomesoplenty:pumpkin_patch",
|
||||
// "biomesoplenty:rainbow_hills",
|
||||
// "biomesoplenty:rainforest",
|
||||
// "biomesoplenty:redwood_forest",
|
||||
// "biomesoplenty:rocky_rainforest",
|
||||
// "biomesoplenty:rocky_shrubland",
|
||||
// "biomesoplenty:scrubland",
|
||||
// "biomesoplenty:seasonal_forest",
|
||||
// "biomesoplenty:shrubland",
|
||||
// "biomesoplenty:snowy_coniferous_forest",
|
||||
// "biomesoplenty:snowy_fir_clearing",
|
||||
// "biomesoplenty:snowy_maple_woods",
|
||||
// "biomesoplenty:spider_nest",
|
||||
// "biomesoplenty:tropics",
|
||||
// "biomesoplenty:tundra",
|
||||
// "biomesoplenty:volcanic_plains",
|
||||
// "biomesoplenty:volcano",
|
||||
// "biomesoplenty:wasteland",
|
||||
// "biomesoplenty:wetland",
|
||||
// "biomesoplenty:wooded_scrubland",
|
||||
// "biomesoplenty:wooded_wasteland",
|
||||
// "biomesoplenty:woodland"
|
||||
// ]
|
||||
// event.get("forge:is_overworld").add(BOP_OVERWORLD)
|
||||
// event.get("ae2:has_meteorites").add(BOP_OVERWORLD)
|
||||
// })
|
||||
}
|
||||
20
overrides/kubejs/server_scripts/mods/computercraft.js
Normal file
20
overrides/kubejs/server_scripts/mods/computercraft.js
Normal file
@@ -0,0 +1,20 @@
|
||||
if (Platform.isLoaded("computercraft")) {
|
||||
ServerEvents.recipes(event => {
|
||||
event.replaceInput({ id: "computercraft:cable" }, "minecraft:redstone", "projectred_core:red_ingot")
|
||||
event.replaceInput({ id: "computercraft:wired_modem" }, "minecraft:redstone", "projectred_core:red_ingot")
|
||||
|
||||
event.remove({ id: "computercraft:turtle_advanced" })
|
||||
event.remove({ id: "computercraft:turtle_advanced_upgrade" })
|
||||
event.remove({ id: "computercraft:turtle_normal" })
|
||||
|
||||
leadMachine(event, "computercraft:computer_normal", "projectred_core:red_ingot")
|
||||
leadMachine(event, "computercraft:computer_advanced", "minecraft:netherite_scrap")
|
||||
leadMachine(event, "computercraft:disk_drive", "computercraft:disk")
|
||||
leadMachine(event, "computercraft:printer", "minecraft:paper")
|
||||
|
||||
createMachine("computercraft:computer_normal", event, "computercraft:turtle_normal", "thermal:invar_gear")
|
||||
createMachine("computercraft:computer_advanced", event, "computercraft:turtle_advanced", "thermal:invar_gear")
|
||||
createMachine("computercraft:computer_normal", event, "computercraft:monitor_normal", "minecraft:glass_pane")
|
||||
createMachine("computercraft:computer_advanced", event, "computercraft:monitor_advanced", "minecraft:glass_pane")
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
if(Platform.isLoaded("create_central_kitchen")) {
|
||||
ServerEvents.recipes(event => {
|
||||
// fix cooking guide recipe since sturdy sheets are removed in CABIN
|
||||
event.remove({ id: "create_central_kitchen:crafting/cooking_guide" })
|
||||
event.shapeless("create_central_kitchen:cooking_guide", ["create:schedule", "farmersdelight:canvas"])
|
||||
|
||||
// Some sequenced assembly recipes don't exist for some reason
|
||||
let transitional = "create_central_kitchen:incomplete_mutton_wrap"
|
||||
event.recipes.create.sequenced_assembly([
|
||||
"farmersdelight:mutton_wrap",
|
||||
], "#forge:bread", [
|
||||
event.recipes.create.deploying(transitional, [transitional, "#forge:cooked_mutton"]),
|
||||
event.recipes.create.deploying(transitional, [transitional, "#forge:crops/cabbage"]),
|
||||
event.recipes.create.deploying(transitional, [transitional, "#forge:crops/onion"])
|
||||
]).transitionalItem(transitional)
|
||||
.loops(1)
|
||||
.id("kubejs:mutton_wrap")
|
||||
|
||||
transitional = "create_central_kitchen:incomplete_hamburger"
|
||||
event.recipes.create.sequenced_assembly([
|
||||
"farmersdelight:hamburger",
|
||||
], "#forge:bread", [
|
||||
event.recipes.create.deploying(transitional, [transitional, "farmersdelight:beef_patty"]),
|
||||
event.recipes.create.deploying(transitional, [transitional, "#forge:crops/cabbage"]),
|
||||
event.recipes.create.deploying(transitional, [transitional, "#forge:crops/tomato"]),
|
||||
event.recipes.create.deploying(transitional, [transitional, "#forge:crops/onion"])
|
||||
]).transitionalItem(transitional)
|
||||
.loops(1)
|
||||
.id("kubejs:hamburger")
|
||||
|
||||
event.remove({ mod: "create_central_kitchen", output: "create:dough" })
|
||||
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
// Create central kitchen somes ends up removing automatic shapeless recipes while providing no alternatives.
|
||||
// This is mainly an issue with bowl recipes
|
||||
event.get("create:ignored_in_automatic_shapeless")
|
||||
.remove("minecraft:bowl")
|
||||
})
|
||||
}
|
||||
62
overrides/kubejs/server_scripts/mods/create_crystal_clear.js
Normal file
62
overrides/kubejs/server_scripts/mods/create_crystal_clear.js
Normal file
@@ -0,0 +1,62 @@
|
||||
if (Platform.isLoaded("create_crystal_clear")) {
|
||||
ServerEvents.recipes(event => {
|
||||
let tweak_glass_casing = (name) => {
|
||||
// event.remove({ output: ("create_crystal_clear:" + name + "_glass_casing") })
|
||||
event.remove({ id: (`create_crystal_clear:${name}_clear_glass_casing`) })
|
||||
event.custom({
|
||||
type: "create:item_application",
|
||||
ingredients: [
|
||||
{ item: `create_crystal_clear:${name}_casing` },
|
||||
{ item: "tconstruct:clear_glass" }
|
||||
],
|
||||
results: [
|
||||
{ item: `create_crystal_clear:${name}_clear_glass_casing` }
|
||||
]
|
||||
}).id(`kubejs:mods/create_crystal_clear/item_application/${name}_clear_glass_casing`)
|
||||
event.shapeless(`create_crystal_clear:${name}_glass_casing`, [`create:${name}_casing`, "minecraft:glass"]).id("kubejs:mods/create_crystal_clear/" + name + "_glass_casing")
|
||||
event.shapeless(`create_crystal_clear:${name}_clear_glass_casing`, [`create:${name}_casing`, "tconstruct:clear_glass"]).id("kubejs:mods/create_crystal_clear/" + name + "_clear_glass_casing")
|
||||
}
|
||||
|
||||
tweak_glass_casing("andesite")
|
||||
tweak_glass_casing("copper")
|
||||
tweak_glass_casing("brass")
|
||||
|
||||
event.remove({ id: ("create_crystal_clear:train_clear_glass_casing") })
|
||||
event.custom({
|
||||
type: "create:item_application",
|
||||
ingredients: [
|
||||
{ item: "create:railway_casing" },
|
||||
{ item: "tconstruct:clear_glass" }
|
||||
],
|
||||
results: [
|
||||
{ item: "create_crystal_clear:train_clear_glass_casing" }
|
||||
]
|
||||
}).id("kubejs:mods/create_crystal_clear/item_application/train_clear_glass_casing")
|
||||
event.shapeless("create_crystal_clear:train_glass_casing", ["create:railway_casing", "minecraft:glass"]).id("kubejs:mods/create_crystal_clear/train_glass_casing")
|
||||
event.shapeless("create_crystal_clear:train_clear_glass_casing", ["create:railway_casing", "tconstruct:clear_glass"]).id("kubejs:mods/create_crystal_clear/train_clear_glass_casing")
|
||||
})
|
||||
|
||||
ServerEvents.blockLootTables(event => {
|
||||
// Fix broken loot tables
|
||||
let cogwheelDrop = {
|
||||
type: "minecraft:block",
|
||||
pools: [
|
||||
{
|
||||
rolls: 1,
|
||||
entries: [
|
||||
{
|
||||
type: "minecraft:item",
|
||||
conditions: [{ condition: "minecraft:survives_explosion" }],
|
||||
name: "create:large_cogwheel"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
let cogwheelCasings = ["andesite", "brass", "train"]
|
||||
cogwheelCasings.forEach(casing=>{
|
||||
event.addJson(`create_crystal_clear:${casing}_glass_encased_large_cogwheel`, cogwheelDrop)
|
||||
event.addJson(`create_crystal_clear:${casing}_clear_glass_encased_large_cogwheel`, cogwheelDrop)
|
||||
})
|
||||
})
|
||||
}
|
||||
23
overrides/kubejs/server_scripts/mods/curios.js
Normal file
23
overrides/kubejs/server_scripts/mods/curios.js
Normal file
@@ -0,0 +1,23 @@
|
||||
if (Platform.isLoaded("curios")) {
|
||||
ServerEvents.lowPriorityData(event=>{
|
||||
event.addJson("kubejs:curios/slots/goggles", {
|
||||
"order": 20,
|
||||
"size": 1,
|
||||
"icon": "cabin:slot/empty_goggles_slot",
|
||||
"dropRule": "ALWAYS_KEEP"
|
||||
})
|
||||
event.addJson("kubejs:curios/entities/player", {
|
||||
"entities": ["player"],
|
||||
"slots": ["goggles"]
|
||||
})
|
||||
|
||||
event.addJson("kubejs:curios/slots/head", {
|
||||
"size": 0
|
||||
})
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event=>{
|
||||
event.add("curios:goggles", "create:goggles")
|
||||
event.remove("curios:head", "create:goggles")
|
||||
})
|
||||
}
|
||||
22
overrides/kubejs/server_scripts/mods/dungeoncrawl.js
Normal file
22
overrides/kubejs/server_scripts/mods/dungeoncrawl.js
Normal file
@@ -0,0 +1,22 @@
|
||||
if (Platform.isLoaded("dungeoncrawl")) {
|
||||
ServerEvents.lowPriorityData(event => {
|
||||
event.addJson("dungeoncrawl:worldgen/structure_set/dungeons", {
|
||||
"structures": [
|
||||
{
|
||||
"structure": "dungeoncrawl:dungeon",
|
||||
"weight": 1
|
||||
}
|
||||
],
|
||||
"placement": {
|
||||
"type": "integrated_api:advanced_random_spread",
|
||||
"super_exclusion_zone": {
|
||||
"chunk_count": 12,
|
||||
"other_set": "#cabin:dungeon_crawl_avoid"
|
||||
},
|
||||
"salt": 10387313,
|
||||
"spacing": 32,
|
||||
"separation": 12
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
87
overrides/kubejs/server_scripts/mods/functionalstorage.js
Normal file
87
overrides/kubejs/server_scripts/mods/functionalstorage.js
Normal file
@@ -0,0 +1,87 @@
|
||||
if(Platform.isLoaded("functionalstorage")) {
|
||||
ServerEvents.recipes(event => {
|
||||
zincMachine(event, Item.of("functionalstorage:storage_controller", 1), "minecraft:diamond")
|
||||
zincMachine(event, Item.of("functionalstorage:controller_extension", 1), "minecraft:gold_ingot")
|
||||
zincMachine(event, Item.of("functionalstorage:simple_compacting_drawer", 1), "create:mechanical_piston")
|
||||
zincMachine(event, Item.of("functionalstorage:compacting_drawer", 1), "create:sticky_mechanical_piston")
|
||||
enderiumMachine(event, Item.of("functionalstorage:fluid_1", 4))
|
||||
enderiumMachine(event, Item.of("functionalstorage:fluid_2", 4))
|
||||
enderiumMachine(event, Item.of("functionalstorage:fluid_4", 4))
|
||||
enderiumMachine(event, Item.of("functionalstorage:ender_drawer", 1))
|
||||
|
||||
event.remove({id:"functionalstorage:oak_drawer_alternate_x1"})
|
||||
event.remove({id:"functionalstorage:oak_drawer_alternate_x2"})
|
||||
event.remove({id:"functionalstorage:oak_drawer_alternate_x4"})
|
||||
// framed drawers
|
||||
event.remove({id:"functionalstorage:compacting_framed_drawer"})
|
||||
event.remove({id:"functionalstorage:framed_storage_controller"})
|
||||
event.remove({id:"functionalstorage:framed_controller_extension"})
|
||||
event.remove({id:"functionalstorage:framed_simple_compacting_drawer"})
|
||||
let pattern = ["III","IDI","III"]
|
||||
event.shaped(Item.of("functionalstorage:compacting_framed_drawer", 1), pattern,
|
||||
{I:"#forge:nuggets/iron", D:"functionalstorage:compacting_drawer"})
|
||||
event.shaped(Item.of("functionalstorage:framed_storage_controller", 1), pattern,
|
||||
{I:"#forge:nuggets/iron", D:"functionalstorage:storage_controller"})
|
||||
event.shaped(Item.of("functionalstorage:framed_controller_extension", 1), pattern,
|
||||
{I:"#forge:nuggets/iron", D:"functionalstorage:controller_extension"})
|
||||
event.shaped(Item.of("functionalstorage:framed_simple_compacting_drawer", 1), pattern,
|
||||
{I:"#forge:nuggets/iron", D:"functionalstorage:simple_compacting_drawer"})
|
||||
|
||||
event.remove({ id: "functionalstorage:copper_upgrade" })
|
||||
event.remove({ id: "functionalstorage:gold_upgrade" })
|
||||
event.remove({ id: "functionalstorage:diamond_upgrade" })
|
||||
event.remove({ id: "functionalstorage:netherite_upgrade" })
|
||||
|
||||
let upgradePattern = ["IBI", "CDC", "IBI"]
|
||||
|
||||
event.shaped(Item.of("functionalstorage:copper_upgrade", 2), upgradePattern, {
|
||||
B: "#forge:storage_blocks/andesite_alloy",
|
||||
C: "#forge:chests/wooden",
|
||||
D: "#functionalstorage:drawer",
|
||||
I: "#forge:ingots/zinc"
|
||||
})
|
||||
|
||||
event.shaped(Item.of("functionalstorage:gold_upgrade", 2), upgradePattern, {
|
||||
B: "functionalstorage:copper_upgrade",
|
||||
C: "#forge:chests/wooden",
|
||||
D: "#functionalstorage:drawer",
|
||||
I: "#forge:ingots/amethyst_bronze"
|
||||
})
|
||||
|
||||
event.shaped(Item.of("functionalstorage:diamond_upgrade", 2), upgradePattern, {
|
||||
B: "functionalstorage:gold_upgrade",
|
||||
C: "#forge:chests/wooden",
|
||||
D: "#functionalstorage:drawer",
|
||||
I: "#forge:ingots/lumium"
|
||||
})
|
||||
|
||||
event.shaped(Item.of("functionalstorage:netherite_upgrade", 2), upgradePattern, {
|
||||
B: "functionalstorage:diamond_upgrade",
|
||||
C: "#forge:chests/wooden",
|
||||
D: "#functionalstorage:drawer",
|
||||
I: "#forge:ingots/hepatizon"
|
||||
})
|
||||
|
||||
event.remove({ id:"functionalstorage:iron_downgrade" })
|
||||
donutCraft(event, Item.of("functionalstorage:iron_downgrade", 4), "#functionalstorage:drawer", "#forge:ingots/iron")
|
||||
|
||||
event.remove({ id:"functionalstorage:redstone_upgrade"})
|
||||
event.shaped(Item.of("functionalstorage:redstone_upgrade", 4), [
|
||||
"IBI",
|
||||
"CDC",
|
||||
"IBI"
|
||||
], {
|
||||
B: "minecraft:redstone_block",
|
||||
C: "minecraft:comparator",
|
||||
D: "#functionalstorage:drawer",
|
||||
I: "minecraft:redstone"
|
||||
})
|
||||
event.remove({ id:"functionalstorage:void_upgrade"})
|
||||
donutCraft(event, Item.of("functionalstorage:void_upgrade", 4), "#functionalstorage:drawer", "minecraft:obsidian")
|
||||
})
|
||||
|
||||
ServerEvents.tags("block", event => {
|
||||
event.add("create:wrench_pickup", /functionalstorage/)
|
||||
event.add("create:wrench_pickup", /everycomp:fs\//)
|
||||
})
|
||||
}
|
||||
24
overrides/kubejs/server_scripts/mods/moreminecarts.js
Normal file
24
overrides/kubejs/server_scripts/mods/moreminecarts.js
Normal file
@@ -0,0 +1,24 @@
|
||||
if(Platform.isLoaded("moreminecarts")) {
|
||||
ServerEvents.tags("block", event => {
|
||||
// None of the blocks from this mod have tags for some reason
|
||||
event.get("minecraft:mineable/pickaxe")
|
||||
.add("moreminecarts:silica_steel_block")
|
||||
.add("moreminecarts:chunkrodite_block")
|
||||
.add("moreminecarts:corrugated_silica_steel")
|
||||
.add("moreminecarts:silica_steel_pillar")
|
||||
.add("moreminecarts:organic_glass")
|
||||
.add("moreminecarts:organic_glass_pane")
|
||||
.add("moreminecarts:chiseled_organic_glass")
|
||||
.add("moreminecarts:chiseled_organic_glass_pane")
|
||||
.add("moreminecarts:holo_scaffold_generator")
|
||||
.add("moreminecarts:chunk_loader")
|
||||
.add("moreminecarts:minecart_loader")
|
||||
.add("moreminecarts:minecart_unloader")
|
||||
.add("moreminecarts:filter_unloader")
|
||||
.add("moreminecarts:pearl_stasis_chamber")
|
||||
})
|
||||
LootJS.modifiers((event) => {
|
||||
event.addBlockLootModifier("moreminecarts:filter_unloader")
|
||||
.addLoot("moreminecarts:filter_unloader")
|
||||
})
|
||||
}
|
||||
80
overrides/kubejs/server_scripts/mods/prettypipes.js
Normal file
80
overrides/kubejs/server_scripts/mods/prettypipes.js
Normal file
@@ -0,0 +1,80 @@
|
||||
if (Platform.isLoaded("prettypipes")) {
|
||||
ServerEvents.recipes(event => {
|
||||
// There are so few recipes that we want to keep that we're better off removing them all
|
||||
event.remove({ mod: "prettypipes" })
|
||||
// machine recipes
|
||||
brassMachine(event, Item.of("prettypipes:item_terminal", 1), "thermal:diamond_gear")
|
||||
brassMachine(event, Item.of("prettypipes:pressurizer", 1), "create:propeller")
|
||||
|
||||
event.shaped(Item.of("prettypipes:pipe", 8), [
|
||||
"PMP"
|
||||
], {
|
||||
P: "create:brass_sheet",
|
||||
M: "create:brass_ingot"
|
||||
})
|
||||
event.shaped("prettypipes:wrench", [
|
||||
"PI ",
|
||||
"II ",
|
||||
" R"
|
||||
], {
|
||||
P: "prettypipes:pipe",
|
||||
I: "#forge:ingots/iron",
|
||||
R: "#forge:dyes/red"
|
||||
})
|
||||
event.shaped("prettypipes:crafting_terminal", [
|
||||
" T ",
|
||||
"RIR",
|
||||
" R "
|
||||
], {
|
||||
T: "minecraft:crafting_table",
|
||||
I: "prettypipes:item_terminal",
|
||||
R: "#forge:dusts/redstone"
|
||||
})
|
||||
event.shapeless("prettypipes:pipe_frame", ["minecraft:item_frame", "prettypipes:pipe", "#forge:dusts/redstone"])
|
||||
|
||||
let module = (type, result) => {
|
||||
// event.remove({ output: "prettypipes:"+result })
|
||||
event.stonecutting("prettypipes:" + result, "kubejs:pipe_module_" + type)
|
||||
}
|
||||
|
||||
module("utility", "filter_increase_modifier")
|
||||
module("utility", "tag_filter_modifier")
|
||||
module("utility", "mod_filter_modifier")
|
||||
module("utility", "nbt_filter_modifier")
|
||||
module("utility", "damage_filter_modifier")
|
||||
module("utility", "round_robin_sorting_modifier")
|
||||
module("utility", "random_sorting_modifier")
|
||||
module("utility", "redstone_module")
|
||||
module("utility", "stack_size_module")
|
||||
module("utility", "low_high_priority_module")
|
||||
module("utility", "medium_high_priority_module")
|
||||
module("utility", "high_high_priority_module")
|
||||
module("utility", "low_low_priority_module")
|
||||
module("utility", "medium_low_priority_module")
|
||||
module("utility", "high_low_priority_module")
|
||||
|
||||
let tiers = ["low", "medium", "high"]
|
||||
for (let i = 0; i < tiers.length; i++) {
|
||||
let tier = "tier_" + (i + 1)
|
||||
let prefix = tiers[i] + "_"
|
||||
module(tier, prefix + "extraction_module")
|
||||
module(tier, prefix + "retrieval_module")
|
||||
module(tier, prefix + "speed_module")
|
||||
module(tier, prefix + "filter_module")
|
||||
module(tier, prefix + "crafting_module")
|
||||
}
|
||||
|
||||
let attachment_base = (id, amount, other_ingredient) => {
|
||||
event.remove({ output: id })
|
||||
if (other_ingredient) {
|
||||
event.smithing(Item.of(id, amount), "kubejs:attachment_base", other_ingredient)
|
||||
event.recipes.create.mechanical_crafting(Item.of(id, amount), "AB", { A: "kubejs:attachment_base", B: other_ingredient })
|
||||
}
|
||||
else
|
||||
event.stonecutting(Item.of(id, amount), "kubejs:attachment_base")
|
||||
}
|
||||
attachment_base("thermal:turbo_servo_attachment", 1)
|
||||
attachment_base("thermal:filter_attachment", 1)
|
||||
attachment_base("thermal:energy_limiter_attachment", 1)
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
if (Platform.isLoaded("projectred_illumination")) {
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ mod: "projectred_illumination" })
|
||||
let convert = (c, id) => {
|
||||
let lamp = `projectred_illumination:${c}${id}`
|
||||
let inverted = `projectred_illumination:${c}_inverted${id}`
|
||||
event.shapeless(inverted, [lamp])
|
||||
event.shapeless(lamp, [inverted])
|
||||
}
|
||||
|
||||
colours.forEach(c => {
|
||||
event.shaped(Item.of(`projectred_illumination:${c}_illumar_lamp`, 1), [
|
||||
"G",
|
||||
"C",
|
||||
"S"
|
||||
], {
|
||||
G: "#forge:glass/colorless",
|
||||
C: `projectred_core:${c}_illumar`,
|
||||
S: "minecraft:redstone"
|
||||
})
|
||||
|
||||
event.stonecutting(Item.of(`projectred_illumination:${c}_fixture_light`, 4), `projectred_illumination:${c}_illumar_lamp`)
|
||||
event.stonecutting(Item.of(`projectred_illumination:${c}_fallout_light`, 4), `projectred_illumination:${c}_illumar_lamp`)
|
||||
event.stonecutting(Item.of(`projectred_illumination:${c}_lantern`, 4), `projectred_illumination:${c}_illumar_lamp`)
|
||||
event.stonecutting(Item.of(`projectred_illumination:${c}_cage_light`, 4), `projectred_illumination:${c}_illumar_lamp`)
|
||||
convert(c, "_illumar_lamp")
|
||||
convert(c, "_fallout_light")
|
||||
convert(c, "_lantern")
|
||||
convert(c, "_cage_light")
|
||||
convert(c, "_fixture_light")
|
||||
})
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
if (Platform.isLoaded("projectred_integration")) {
|
||||
ServerEvents.recipes(event => {
|
||||
let p_circuit = (id) => event.stonecutting(Item.of("projectred_integration:" + id + "_gate", 1), "projectred_core:platformed_plate")
|
||||
|
||||
event.remove({ mod:"projectred_integration" })
|
||||
|
||||
p_circuit("or")
|
||||
p_circuit("nor")
|
||||
p_circuit("not")
|
||||
p_circuit("and")
|
||||
p_circuit("nand")
|
||||
p_circuit("xor")
|
||||
p_circuit("xnor")
|
||||
p_circuit("buffer")
|
||||
p_circuit("multiplexer")
|
||||
p_circuit("pulse")
|
||||
p_circuit("repeater")
|
||||
p_circuit("randomizer")
|
||||
p_circuit("sr_latch")
|
||||
p_circuit("toggle_latch")
|
||||
p_circuit("transparent_latch")
|
||||
p_circuit("light_sensor")
|
||||
p_circuit("rain_sensor")
|
||||
p_circuit("timer")
|
||||
p_circuit("sequencer")
|
||||
p_circuit("counter")
|
||||
p_circuit("state_cell")
|
||||
p_circuit("synchronizer")
|
||||
p_circuit("bus_transceiver")
|
||||
p_circuit("null_cell")
|
||||
p_circuit("invert_cell")
|
||||
p_circuit("buffer_cell")
|
||||
p_circuit("comparator")
|
||||
p_circuit("and_cell")
|
||||
p_circuit("bus_randomizer")
|
||||
p_circuit("bus_converter")
|
||||
p_circuit("bus_input_panel")
|
||||
p_circuit("segment_display")
|
||||
p_circuit("dec_randomizer")
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
if (Platform.isLoaded("projectred_transmission")) {
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ id: "projectred_transmission:wired_plate" })
|
||||
event.remove({ id: "projectred_transmission:bundled_plate" })
|
||||
})
|
||||
}
|
||||
134
overrides/kubejs/server_scripts/mods/quark.js
Normal file
134
overrides/kubejs/server_scripts/mods/quark.js
Normal file
@@ -0,0 +1,134 @@
|
||||
if(Platform.isLoaded("quark")) {
|
||||
|
||||
// Add quark wood types to the arrays of wood types
|
||||
wood_types.push("quark:ancient")
|
||||
wood_types.push("quark:azalea")
|
||||
wood_types.push("quark:blossom")
|
||||
|
||||
ServerEvents.recipes(event => {
|
||||
// Unwanted duplicate compressed block recipes
|
||||
event.remove({ id: "quark:building/crafting/compressed/charcoal_block"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/sugar_cane_block"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/gunpowder_sack"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/apple_crate"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/potato_crate"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/carrot_crate"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/beetroot_crate"})
|
||||
event.remove({ id: "quark:building/crafting/compressed/bamboo_block"})
|
||||
|
||||
// Tree resin
|
||||
addTreeOutput(event, "quark:blossom_log", "quark:blue_blossom_leaves")
|
||||
addTreeOutput(event, "quark:blossom_log", "quark:lavender_blossom_leaves")
|
||||
addTreeOutput(event, "quark:blossom_log", "quark:orange_blossom_leaves")
|
||||
addTreeOutput(event, "quark:blossom_log", "quark:yellow_blossom_leaves")
|
||||
addTreeOutput(event, "quark:blossom_log", "quark:red_blossom_leaves")
|
||||
|
||||
// Stone generation
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": "kubejs:chromatic_waste",
|
||||
"below": "minecraft:end_stone",
|
||||
"result": { "item": "quark:myalite"}
|
||||
})
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": "kubejs:chromatic_waste",
|
||||
"below": "minecraft:clay",
|
||||
"result": { "item": "quark:shale"}
|
||||
})
|
||||
event.custom({
|
||||
"type": "thermal:rock_gen",
|
||||
"adjacent": "kubejs:chromatic_waste",
|
||||
"below": "minecraft:quartz_block",
|
||||
"result": { "item": "quark:jasper"}
|
||||
})
|
||||
|
||||
// Modify quark easy sticks recipe to prevent conflicts with decorative blocks wood beams
|
||||
event.replaceInput({ id: "quark:tweaks/crafting/utility/misc/easy_sticks" }, "#minecraft:logs", "#kubejs:easy_sticks_logs")
|
||||
})
|
||||
|
||||
ServerEvents.tags("block", event => {
|
||||
|
||||
event.add("create:wrench_pickup", "quark:ender_watcher")
|
||||
// I really don't know why these blocks are missing the pressure plate tag
|
||||
// All the other pressure plates from quark and forbidden have the tag.
|
||||
event.add("minecraft:pressure_plates", "quark:obsidian_pressure_plate")
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
// Create a new set of tags for logs ok to use for the easy sticks recipe
|
||||
const easy_sticks = event.get("minecraft:logs").getObjectIds()
|
||||
const easy_sticks_blacklist = Ingredient.of("/.*stripped.*/")
|
||||
easy_sticks.forEach(easy_sticks => {
|
||||
if (!easy_sticks_blacklist.test(easy_sticks)) event.add("kubejs:easy_sticks_logs", easy_sticks)
|
||||
})
|
||||
// We only want to remove stripped logs, not stripped wood
|
||||
event.add("kubejs:easy_sticks_logs", "#forge:stripped_wood")
|
||||
})
|
||||
|
||||
ServerEvents.lowPriorityData(event => {
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/limestone", [
|
||||
"create:limestone",
|
||||
"quark:limestone",
|
||||
"quark:polished_limestone",
|
||||
"quark:limestone_bricks",
|
||||
"quark:chiseled_limestone_bricks",
|
||||
"quark:limestone_pillar"
|
||||
])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/apple_block", ["thermal:apple_block", "quark:apple_crate"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/beetroot_block", ["farmersdelight:beetroot_crate", "quark:beetroot_crate"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/carrot_block", ["farmersdelight:carrot_crate", "quark:carrot_crate"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/charcoal_block", ["thermal:charcoal_block", "quark:charcoal_block"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/gunpowder_block", ["thermal:gunpowder_block", "quark:gunpowder_sack"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/potato_block", ["farmersdelight:potato_crate", "quark:potato_crate"])
|
||||
addChiselingRecipe(event, "kubejs:chiseling_recipes/compat/quark/sugar_cane_block", ["thermal:sugar_cane_block", "quark:sugar_cane_block"])
|
||||
|
||||
// Remove the Forgotten Hat from the forgotten's drop pool (spawns in strongholds with integrated strongholds)
|
||||
event.addJson("quark:loot_tables/entities/forgotten", {
|
||||
"type": "minecraft:entity",
|
||||
"pools": [
|
||||
{
|
||||
"rolls": 1,
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
"count": {"min": 4.0, "max": 8.0, "type": "minecraft:uniform"}
|
||||
},
|
||||
{
|
||||
"function": "minecraft:looting_enchant",
|
||||
"count": {"min": 1.0, "max": 2.0}
|
||||
}
|
||||
],
|
||||
"name": "minecraft:arrow"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"rolls": 1,
|
||||
"entries": [
|
||||
{
|
||||
"type": "minecraft:item",
|
||||
"functions": [
|
||||
{
|
||||
"function": "minecraft:set_count",
|
||||
"count": {"min": 2.0, "max": 3.0, "type": "minecraft:uniform"}
|
||||
},
|
||||
{
|
||||
"function": "minecraft:looting_enchant",
|
||||
"count": {"min": 0.0, "max": 1.0}
|
||||
}
|
||||
],
|
||||
"name": "minecraft:bone"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
})
|
||||
|
||||
// remove soul beads
|
||||
event.addJson("quark:loot_tables/entities/wraith", {})
|
||||
})
|
||||
}
|
||||
7
overrides/kubejs/server_scripts/mods/reliquary.js
Normal file
7
overrides/kubejs/server_scripts/mods/reliquary.js
Normal file
@@ -0,0 +1,7 @@
|
||||
if(Platform.isLoaded("reliquary")) {
|
||||
ServerEvents.recipes(event => {
|
||||
event.forEachRecipe({id: /alkahestry/}, recipe => {
|
||||
recipe.id(recipe.getId() + "_manual_only")
|
||||
})
|
||||
})
|
||||
}
|
||||
133
overrides/kubejs/server_scripts/mods/sophstorage.js
Normal file
133
overrides/kubejs/server_scripts/mods/sophstorage.js
Normal file
@@ -0,0 +1,133 @@
|
||||
/**
|
||||
* Configuration of Sophisticated Storage
|
||||
*/
|
||||
ServerEvents.recipes(event => {
|
||||
// const modids = ["sophisticatedstorage", "sophisticatedbackpacks"]
|
||||
|
||||
// Remove XP pump upgrades
|
||||
event.remove({ id: "sophisticatedstorage:xp_pump_upgrade" })
|
||||
event.remove({ id: "sophisticatedbackpacks:xp_pump_upgrade" })
|
||||
|
||||
// Remove Limited barrels
|
||||
event.remove({ id: /^sophisticatedstorage:.*limited.+barrel.+$/ })
|
||||
event.remove({ output: /^sophisticatedstorage:limited_barrel.+$/ })
|
||||
|
||||
// Remove Copper tier storage (not used)
|
||||
event.remove({ output: "sophisticatedstorage:copper_barrel" })
|
||||
event.remove({ output: "sophisticatedstorage:copper_chest" })
|
||||
event.remove({ output: "sophisticatedstorage:copper_shulker_box" })
|
||||
// Remove Copper tier upgrades
|
||||
event.remove({ output: /^sophisticatedstorage:.*copper.*tier_upgrade$/ })
|
||||
event.remove({ input: /^sophisticatedstorage:.*copper.*tier_upgrade$/ })
|
||||
|
||||
// Barrel, Chest, Shulker Box upgrading
|
||||
const sophStorageMaterials = [
|
||||
["", null, null],
|
||||
// ["copper_", "tconstruct:steel_ingot", "lead"],
|
||||
["iron_", "bronze"],
|
||||
["gold_", "invar"],
|
||||
["diamond_", "slimesteel"],
|
||||
["netherite_", "manyullyn"],
|
||||
]
|
||||
const sophStorageTypes = [
|
||||
["", "barrel"],
|
||||
["", "chest"],
|
||||
["", "shulker_box"]
|
||||
]
|
||||
|
||||
let upgradePattern = ["NIN", "NCN", "NIN"]
|
||||
|
||||
sophStorageMaterials.forEach((material, toIndex) => {
|
||||
if (toIndex == 0) return;
|
||||
|
||||
// Tier upgrade items
|
||||
for (let fromIndex = 0; fromIndex < toIndex; fromIndex++) {
|
||||
let fromTierName = (fromIndex == 0 ? "basic_" : sophStorageMaterials[fromIndex][0]);
|
||||
let prevTierName = (toIndex - 1 == 0 ? "basic_" : sophStorageMaterials[toIndex - 1][0]);
|
||||
let toTierName = material[0];
|
||||
|
||||
event.shaped(`sophisticatedstorage:${fromTierName}to_${toTierName}tier_upgrade`,
|
||||
upgradePattern, {
|
||||
N: `#forge:nuggets/${material[1]}`,
|
||||
I: `#forge:ingots/${material[1]}`,
|
||||
C: (fromTierName == prevTierName ? "minecraft:redstone_torch" : `sophisticatedstorage:${fromTierName}to_${prevTierName}tier_upgrade`),
|
||||
}).id(`sophisticatedstorage:${fromTierName}to_${toTierName}tier_upgrade`)
|
||||
}
|
||||
|
||||
// Barrel-in-table upgrades
|
||||
sophStorageTypes.forEach(storageType => {
|
||||
// Works for upgrades as the recipe type implies, but doesn't work for making new barrels/chests/boxes from scratch
|
||||
let outputStorage = `sophisticatedstorage:${storageType[0]}${material[0]}${storageType[1]}`
|
||||
let inputStorage = `sophisticatedstorage:${storageType[0]}${sophStorageMaterials[toIndex - 1][0]}${storageType[1]}`
|
||||
event.remove({ mod: "sophisticatedstorage", output: outputStorage })
|
||||
event.custom({
|
||||
"type": "sophisticatedstorage:storage_tier_upgrade",
|
||||
"conditions": [
|
||||
{
|
||||
"type": "sophisticatedcore:item_enabled",
|
||||
"itemRegistryName": outputStorage
|
||||
}
|
||||
],
|
||||
"pattern": upgradePattern,
|
||||
"key": {
|
||||
"N": {
|
||||
"tag": `forge:nuggets/${material[1]}`
|
||||
},
|
||||
"I": {
|
||||
"tag": `forge:ingots/${material[1]}`
|
||||
},
|
||||
"C": {
|
||||
"item": inputStorage
|
||||
}
|
||||
},
|
||||
"result": {
|
||||
"item": outputStorage
|
||||
}
|
||||
});
|
||||
})
|
||||
})
|
||||
|
||||
enderiumMachine(event, Item.of("sophisticatedstorage:controller", 1), "functionalstorage:storage_controller")
|
||||
enderiumMachine(event, Item.of("sophisticatedstorage:controller", 1), "functionalstorage:controller_extension")
|
||||
leadMachine(event, Item.of("sophisticatedstorage:storage_input", 1))
|
||||
leadMachine(event, Item.of("sophisticatedstorage:storage_output", 1))
|
||||
|
||||
// Stack upgrades
|
||||
let stackupgrade = [
|
||||
["", "create:andesite_alloy", ""],
|
||||
["stack_upgrade_tier_1", "create:brass_ingot", "upgrade_base"],
|
||||
["stack_upgrade_tier_2", "thermal:invar_ingot", "stack_upgrade_tier_1"],
|
||||
["stack_upgrade_tier_3", "thermal:enderium_ingot", "stack_upgrade_tier_2"],
|
||||
["stack_upgrade_tier_4", "kubejs:calculation_mechanism", "stack_upgrade_tier_3"]
|
||||
]
|
||||
|
||||
event.remove({ output: "sophisticatedstorage:stack_upgrade_tier_1_plus" })
|
||||
|
||||
for (let i = 1;i < stackupgrade.length;++i) {
|
||||
let upgrade = stackupgrade[i][0]
|
||||
let baseUpgrade = stackupgrade[i][2]
|
||||
|
||||
let ingredient = stackupgrade[i][1]
|
||||
let previousIngredient = stackupgrade[i - 1][1]
|
||||
|
||||
event.remove({ output: `sophisticatedstorage:${upgrade}` })
|
||||
donutCraft(event, `sophisticatedstorage:${upgrade}`, `sophisticatedstorage:${baseUpgrade}`, `${previousIngredient}`)
|
||||
event.remove({ output: `sophisticatedbackpacks:${upgrade}` })
|
||||
donutCraft(event, `sophisticatedbackpacks:${upgrade}`, `sophisticatedbackpacks:${baseUpgrade}`, `${ingredient}`)
|
||||
}
|
||||
|
||||
// Sophisticated Backpacks starter upgrade
|
||||
event.remove({ output: "sophisticatedbackpacks:stack_upgrade_starter_tier" })
|
||||
donutCraft(event, "sophisticatedbackpacks:stack_upgrade_starter_tier", "sophisticatedbackpacks:upgrade_base", "create:andesite_alloy")
|
||||
donutCraft(event, "sophisticatedbackpacks:stack_upgrade_tier_1", "sophisticatedbackpacks:stack_upgrade_starter_tier", "create:brass_ingot")
|
||||
// Sophisticated Storage tier 5 upgrade
|
||||
event.remove({ output: "sophisticatedstorage:stack_upgrade_tier_5" })
|
||||
donutCraft(event, "sophisticatedstorage:stack_upgrade_tier_5", "sophisticatedstorage:stack_upgrade_tier_4", "kubejs:calculation_mechanism")
|
||||
|
||||
event.remove({ id: "sophisticatedbackpacks:inception_upgrade"})
|
||||
event.remove({ id: "sophisticatedbackpacks:stack_upgrade_omega_tier"})
|
||||
event.remove({ output: "sophisticatedstorage:stack_upgrade_omega_tier" })
|
||||
|
||||
// Upgrades
|
||||
brassMachine(event, Item.of("sophisticatedstorage:advanced_hopper_upgrade", 2))
|
||||
})
|
||||
57
overrides/kubejs/server_scripts/mods/supplementaries.js
Normal file
57
overrides/kubejs/server_scripts/mods/supplementaries.js
Normal file
@@ -0,0 +1,57 @@
|
||||
if (Platform.isLoaded("supplementaries")) {
|
||||
ServerEvents.recipes(event => {
|
||||
// Lumisene
|
||||
event.custom({
|
||||
"type": "tconstruct:melting",
|
||||
"ingredient": {"item": "minecraft:glow_berries"},
|
||||
"result": {
|
||||
"fluid": "supplementaries:lumisene",
|
||||
"amount": 125
|
||||
},
|
||||
"temperature": 200,
|
||||
"time": 6
|
||||
}).id("kubejs:smeltery/melting/lumisene")
|
||||
|
||||
event.recipes.thermal.crucible(Fluid.of("supplementaries:lumisene", 125), "minecraft:glow_berries", 0, 1000)
|
||||
|
||||
event.recipes.create.filling("supplementaries:lumisene_bottle", ["minecraft:glass_bottle", Fluid.of("supplementaries:lumisene", 250).toJson()])
|
||||
event.recipes.create.emptying([Fluid.of("supplementaries:lumisene", 250), "minecraft:glass_bottle"], "supplementaries:lumisene_bottle")
|
||||
|
||||
// Timber Frame
|
||||
event.remove({ id:"supplementaries:timber_frame" })
|
||||
donutCraft(event, Item.of("supplementaries:timber_frame", 2), "minecraft:air", "#forge:rods/wooden")
|
||||
|
||||
event.stonecutting("supplementaries:timber_frame", "#kubejs:timber_frame")
|
||||
event.stonecutting("supplementaries:timber_brace", "#kubejs:timber_frame")
|
||||
event.stonecutting("supplementaries:timber_cross_brace", "#kubejs:timber_frame")
|
||||
|
||||
// Fix crafting table dye removal recipes for these items
|
||||
event.shapeless(Item.of("create:copper_valve_handle"), ["#create:valve_handles","supplementaries:soap"] ).id("kubejs:soap_clean_valve_handle_manual_only")
|
||||
// Copy the NBT data for this one so that removing dye doesn't eat our stuff.
|
||||
event.shapeless(Item.of("create:brown_toolbox"), ["#create:toolboxes","supplementaries:soap"] ).id("kubejs:soap_clean_toolbox_manual_only").modifyResult((grid, result) => {
|
||||
const item = grid.find(Ingredient.of("#create:toolboxes"))
|
||||
return result.withNBT(item.nbt)
|
||||
})
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
event.get("kubejs:timber_frame")
|
||||
.add("supplementaries:timber_frame")
|
||||
.add("supplementaries:timber_brace")
|
||||
.add("supplementaries:timber_cross_brace")
|
||||
})
|
||||
|
||||
ServerEvents.tags("block", event => {
|
||||
// Whitelist these items to allow the removal of dye in-world using soap (see supplementaries common config)
|
||||
const dyedHandles = event.get("create:valve_handles").getObjectIds()
|
||||
const dyedHandlesBlacklist = Ingredient.of(/.*copper.*/)
|
||||
dyedHandles.forEach(handle => {
|
||||
if (!dyedHandlesBlacklist.test(handle)) event.add("kubejs:valve_handles_dyed", handle)
|
||||
})
|
||||
const dyedToolboxes = event.get("create:toolboxes").getObjectIds()
|
||||
const dyedToolboxesBlacklist = Ingredient.of(/.*brown.*/)
|
||||
dyedToolboxes.forEach(toolbox => {
|
||||
if (!dyedToolboxesBlacklist.test(toolbox)) event.add("kubejs:toolboxes_dyed", toolbox)
|
||||
})
|
||||
})
|
||||
}
|
||||
65
overrides/kubejs/server_scripts/mods/trials.js
Normal file
65
overrides/kubejs/server_scripts/mods/trials.js
Normal file
@@ -0,0 +1,65 @@
|
||||
// Trial Chamber backport
|
||||
if (Platform.isLoaded("trials")) {
|
||||
ServerEvents.recipes(event => {
|
||||
// Broken Item
|
||||
event.remove({ id:"trials:crafter" })
|
||||
if (Platform.isLoaded("quark")) {
|
||||
event.shapeless("quark:crafter", ["trials:crafter"])
|
||||
}
|
||||
})
|
||||
ServerEvents.lowPriorityData(event => {
|
||||
|
||||
// Make a Trial Processor using IntegratedAPI and Lithostitched
|
||||
// Integrated API's waterlog fix processor is used to fix blocks being waterlogged when the structure generates over water
|
||||
// Lithostitched is used to swap blocks while copying over properties. (without it this processor would be almost 3000 lines long)
|
||||
event.addJson("trials:worldgen/processor_list/generic", {
|
||||
"processors": [
|
||||
{
|
||||
"processor_type": "integrated_api:waterlogging_fix_processor"
|
||||
},
|
||||
{
|
||||
"processor_type": "lithostitched:block_swap",
|
||||
"blocks": {
|
||||
"minecraft:waxed_copper_block": "kubejs:trial_copper_block",
|
||||
"minecraft:waxed_cut_copper": "kubejs:trial_cut_copper",
|
||||
"trials:waxed_chiseled_copper": "kubejs:trial_chiseled_copper",
|
||||
"trials:waxed_copper_grate": "kubejs:trial_copper_grate",
|
||||
"minecraft:waxed_cut_copper_stairs": "kubejs:trial_cut_copper_stairs",
|
||||
"minecraft:waxed_cut_copper_slab": "kubejs:trial_cut_copper_slab",
|
||||
"minecraft:waxed_oxidized_copper": "kubejs:trial_oxidized_copper",
|
||||
"minecraft:waxed_oxidized_cut_copper": "kubejs:trial_oxidized_cut_copper",
|
||||
"trials:waxed_chiseled_copper_oxidized": "kubejs:trial_chiseled_copper_oxidized",
|
||||
"trials:waxed_copper_grate_oxidized": "kubejs:trial_copper_grate_oxidized",
|
||||
"minecraft:waxed_oxidized_cut_copper_stairs": "kubejs:trial_oxidized_cut_copper_stairs",
|
||||
"minecraft:waxed_oxidized_cut_copper_slab": "kubejs:trial_oxidized_cut_copper_slab"
|
||||
}
|
||||
}
|
||||
]
|
||||
})
|
||||
|
||||
event.addJson("trials:worldgen/structure_set/trial_chambers", {
|
||||
"structures": [
|
||||
{
|
||||
"structure": "trials:trials_chambers",
|
||||
"weight": 1
|
||||
}
|
||||
],
|
||||
"placement": {
|
||||
"type": "integrated_api:advanced_random_spread",
|
||||
"super_exclusion_zone": {
|
||||
"chunk_count": 12,
|
||||
"other_set": "#cabin:trial_chambers_avoid"
|
||||
},
|
||||
"spacing": 32,
|
||||
"separation": 21,
|
||||
"salt": 412788945
|
||||
}
|
||||
})
|
||||
|
||||
// Loot Tables are changed in the data folder.
|
||||
|
||||
// We need to change the type of loot tables to 'chest' so that emi Loot chooses to render it
|
||||
// The loot tables still work in trial vaults when they're set to the 'chest' type
|
||||
// Even if Lootjs were good in this version, we would still likely need to use a datapack to change the loot type
|
||||
})
|
||||
}
|
||||
22
overrides/kubejs/server_scripts/oregen.js
Normal file
22
overrides/kubejs/server_scripts/oregen.js
Normal file
@@ -0,0 +1,22 @@
|
||||
ServerEvents.lowPriorityData(event => {
|
||||
removeFeature(event, "minecraft:ore_redstone")
|
||||
removeFeature(event, "minecraft:ore_redstone_lower")
|
||||
|
||||
removeFeature(event, "occultism:ore_silver")
|
||||
removeFeature(event, "occultism:ore_silver_deepslate")
|
||||
removeFeature(event, "occultism:ore_silver_deepslate")
|
||||
// It's possible to disable these in the config, but using configs for oregen is outdated and the way Thermal addons' oregens work are very strange
|
||||
removeFeature(event, "thermal:tin_ore")
|
||||
removeFeature(event, "thermal:silver_ore")
|
||||
|
||||
addOregenOverworld(event, "kubejs:ore_ruby", "thermal:ruby_ore", "minecraft:trapezoid", -144, 16, 4, 6, 0.5)
|
||||
addOregenOverworld(event, "kubejs:ore_sapphire", "thermal:sapphire_ore", "minecraft:trapezoid", -144, 16, 4, 6, 0.5)
|
||||
|
||||
// The defaults for these 2 aren't what we want.
|
||||
// We need Extra Cinnabar to turn into Redstone and Apatite doesn't even generate without Thermal Cultivation.
|
||||
removeFeature(event, "thermal:apatite_ore")
|
||||
removeFeature(event, "thermal:cinnabar_ore")
|
||||
|
||||
addOregenOverworld(event, "kubejs:ore_apatite", "thermal:apatite_ore", "minecraft:trapezoid", -16, 96, 3, 9, 0)
|
||||
addOregenOverworld(event, "kubejs:ore_cinnabar", "thermal:cinnabar_ore", "minecraft:trapezoid", -16, 48, 3, 6, 0)
|
||||
})
|
||||
40
overrides/kubejs/server_scripts/quests.js
Normal file
40
overrides/kubejs/server_scripts/quests.js
Normal file
@@ -0,0 +1,40 @@
|
||||
FTBQuestsEvents.completed("252B9DD5BFB8184A", event => {
|
||||
|
||||
// let runCommand = (cmd) => {
|
||||
// event.server.scheduleInTicks(10, event.server, function (callback) {
|
||||
// callback.data.runCommandSilent(cmd)
|
||||
// })
|
||||
// }
|
||||
// let message;
|
||||
// let refund = false;
|
||||
|
||||
// if (event.player.level.dimension = 'minecraft:nether') {
|
||||
// let structureName = Platform.isLoaded("betterfortresses") ? "betterfortresses:fortress" : "fortress";
|
||||
// let playerLevel = event.player.getLevel().getDimension().getPath();
|
||||
|
||||
// let structure = TagKey.create(Registry.CONFIGURED_STRUCTURE_FEATURE_REGISTRY, structureName);
|
||||
// let blockPos = new BlockPos(event.player.getX(), event.player.getY(), event.player.getZ());
|
||||
// let radius = 32;
|
||||
|
||||
// let position = playerLevel.findNearestMapFeature(structure, blockPos, radius, false);
|
||||
|
||||
// if (blockPos) {
|
||||
// message = `A Fortress was found at ${position.x} ${position.z}.`;
|
||||
|
||||
// } else {
|
||||
// message = "No fortress could be found. Your gold has been refunded.";
|
||||
// refund = true;
|
||||
// }
|
||||
// } else {
|
||||
// message = "The Locator cannot be used here. Your gold has been refunded.";
|
||||
// refund = true;
|
||||
// }
|
||||
|
||||
// event.server.scheduleInTicks(10, event.server, function (callback) {
|
||||
// if (refund) {
|
||||
// event.player.give(Item.of("thermal:gold_coin", 2))
|
||||
// }
|
||||
// callback.data.runCommand(`/tell ${event.player.name.text} ${message}`)
|
||||
// })
|
||||
|
||||
})
|
||||
157
overrides/kubejs/server_scripts/recipes/alchemy.js
Normal file
157
overrides/kubejs/server_scripts/recipes/alchemy.js
Normal 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" }]
|
||||
})
|
||||
})
|
||||
1339
overrides/kubejs/server_scripts/recipes/chapters.js
Normal file
1339
overrides/kubejs/server_scripts/recipes/chapters.js
Normal file
File diff suppressed because it is too large
Load Diff
31
overrides/kubejs/server_scripts/recipes/gem_processing.js
Normal file
31
overrides/kubejs/server_scripts/recipes/gem_processing.js
Normal 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")
|
||||
})
|
||||
31
overrides/kubejs/server_scripts/recipes/illusonaryblocks.js
Normal file
31
overrides/kubejs/server_scripts/recipes/illusonaryblocks.js
Normal 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");
|
||||
}
|
||||
})
|
||||
458
overrides/kubejs/server_scripts/recipes/metallurgy.js
Normal file
458
overrides/kubejs/server_scripts/recipes/metallurgy.js
Normal 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
|
||||
})
|
||||
})
|
||||
9
overrides/kubejs/server_scripts/recipes/minecraft.js
Normal file
9
overrides/kubejs/server_scripts/recipes/minecraft.js
Normal file
@@ -0,0 +1,9 @@
|
||||
ServerEvents.recipes(event => {
|
||||
event.shaped("minecraft:bundle", [
|
||||
"S",
|
||||
"L"
|
||||
], {
|
||||
S: "minecraft:string",
|
||||
L: "minecraft:leather",
|
||||
})
|
||||
})
|
||||
40
overrides/kubejs/server_scripts/recipes/phantomless.js
Normal file
40
overrides/kubejs/server_scripts/recipes/phantomless.js
Normal 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;
|
||||
}
|
||||
})
|
||||
44
overrides/kubejs/server_scripts/recipes/trading.js
Normal file
44
overrides/kubejs/server_scripts/recipes/trading.js
Normal 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")
|
||||
})
|
||||
@@ -0,0 +1,27 @@
|
||||
## Addon Compatibility Scripts for CABIN
|
||||
|
||||
These are for mods that are not installed by default, sections of this script will enable if the applicable mod is installed.
|
||||
With how many create addons there are, it would not be feasible for me to add compat for them all by myself.
|
||||
|
||||
If you have a create addon that you think could fit in the general theme/tone/whathaveyou of CABIN, make a PR with it. Custom textures can also be submitted, if you wish.
|
||||
|
||||
```js
|
||||
if (Platform.isLoaded('YourModID')) { // Mod ID goes here
|
||||
ServerEvents.recipes(event => {
|
||||
// Here's a machine recipe example. The code for these functions are defined in _helper.js
|
||||
// Note that machine recipes will remove all default recipes for the output item
|
||||
// Valid machine materials are andesite, copper, gold, brass, zinc, lead, invar, enderium, and fluix
|
||||
(material)Machine(event,Item.of('minecraft:dirt', 1)) // Recipes without an additional item will be stonecutting (saw) recipes
|
||||
(material)Machine(event,Item.of('minecraft:dispenser', 2), 'minecraft:bow') // Recipes with one are deployer recipes
|
||||
|
||||
//You can also use createMachine() to create a machine recipe using an item other then the normal machine items
|
||||
//This code will create a machine crafting recipe for an enchanting table using a "diamond block" machine with a book as the second material
|
||||
createMachine('minecraft:diamond_block', event, 'minecraft:enchanting_table', 'minecraft:book')
|
||||
|
||||
// Shapeless recipe example
|
||||
event.shapeless("create:creative_crate", ["minecraft:redstone_ore", "minecraft:lapis_ore"])
|
||||
// Please refer to the kubejs wiki for other recipe types
|
||||
// Also note that you can easily get an item's ID with /kjs hand
|
||||
// https://wiki.latvian.dev/books/kubejs/page/recipes
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
if(Platform.isLoaded("create_connected")) {
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ id: "create_connected:sequenced_assembly/control_chip" })
|
||||
event.remove({ id: "create_connected:crafting/kinetics/sequenced_pulse_generator" })
|
||||
event.shapeless("create_connected:sequenced_pulse_generator", ["projectred_core:platformed_plate", "create:electron_tube"])
|
||||
.id("kubejs:compat/create_connected/sequenced_pulse_generator_manual_only")
|
||||
event.recipes.create.deploying("create_connected:sequenced_pulse_generator", ["projectred_core:platformed_plate", "create:electron_tube"])
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
event.get("kubejs:sellable_discs")
|
||||
.add("create_connected:music_disk_elevator")
|
||||
.add("create_connected:music_disk_interlude")
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
if(Platform.isLoaded("create_enchantment_industry")) {
|
||||
ServerEvents.recipes(event => {
|
||||
zincMachine(event, Item.of("create_enchantment_industry:disenchanter", 1), "#create:sandpaper")
|
||||
zincMachine(event, Item.of("create_enchantment_industry:printer", 1), "#forge:storage_blocks/lapis")
|
||||
|
||||
event.remove({ id:"create_enchantment_industry:mixing/hyper_experience"})
|
||||
event.recipes.create.mixing(Fluid.of("create_enchantment_industry:hyper_experience", 10), [
|
||||
"#forge:dusts/enderium",
|
||||
"minecraft:lapis_lazuli",
|
||||
"minecraft:glow_ink_sac",
|
||||
Fluid.of("create_enchantment_industry:experience", 100).toJson()
|
||||
]).superheated()
|
||||
|
||||
event.replaceInput( {id: "create_enchantment_industry:crafting/enchanting_guide"}, "create:sturdy_sheet", "create:schedule" )
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
if(Platform.isLoaded("create_hypertube")) {
|
||||
ServerEvents.recipes(event => {
|
||||
brassMachine(event, Item.of("create_hypertube:hypertube_entrance", 1), "thermal:cured_rubber")
|
||||
|
||||
event.replaceInput( {id: "create_hypertube:crafting/hypertube"}, "create:brass_sheet", "#forge:plates/brass" )
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
if (Platform.isLoaded("create_power_loader")) {
|
||||
ServerEvents.recipes(event => {
|
||||
andesiteMachine(event,Item.of("create_power_loader:empty_andesite_chunk_loader", 1), "minecraft:ghast_tear")
|
||||
brassMachine(event,Item.of("create_power_loader:empty_brass_chunk_loader", 1), "minecraft:nether_star")
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,88 @@
|
||||
// Create: Crafts and Additions
|
||||
if (Platform.isLoaded("createaddition")) {
|
||||
ServerEvents.recipes(event => {
|
||||
andesiteMachine(event, Item.of("createaddition:rolling_mill", 1), "create:shaft")
|
||||
brassMachine(event, Item.of("createaddition:portable_energy_interface", 2))
|
||||
brassMachine(event, Item.of("createaddition:tesla_coil", 1), "createaddition:copper_spool")
|
||||
brassMachine(event, Item.of("createaddition:modular_accumulator", 1), "thermal:energy_cell_frame")
|
||||
|
||||
event.replaceOutput({}, "#forge:nuggets/electrum", "createaddition:electrum_nugget")
|
||||
event.replaceOutput({}, "#forge:ingots/electrum", "createaddition:electrum_ingot")
|
||||
event.replaceOutput({}, "#forge:plates/electrum", "createaddition:electrum_sheet")
|
||||
event.replaceOutput({}, "#forge:storage_blocks/electrum", "createaddition:electrum_block")
|
||||
event.replaceOutput({}, "#forge:dusts/diamond", "createaddition:diamond_grit")
|
||||
|
||||
// event.replaceOutput({ id: "kubejs:machines/smelter/electrum_ingot" }, "thermal:electrum_ingot", "createaddition:electrum_ingot")
|
||||
|
||||
// Duplicate Electrum Recipes
|
||||
event.remove({ id: "createaddition:crafting/electrum_nugget" })
|
||||
event.remove({ id: "createaddition:crafting/electrum"})
|
||||
event.remove({ id: "createaddition:crafting/electrum_ingot"})
|
||||
event.remove({ id: "createaddition:crafting/electrum_block" })
|
||||
|
||||
// Motor & Alternator
|
||||
invarMachine(event, Item.of("createaddition:electric_motor", 1), "createaddition:tesla_coil")
|
||||
enderiumMachine(event, Item.of("createaddition:alternator", 1), "createaddition:electric_motor")
|
||||
|
||||
// Remove capacitors
|
||||
event.remove({ output: "createaddition:capacitor" })
|
||||
|
||||
// Redstone Relay
|
||||
event.remove({ output: "createaddition:redstone_relay" })
|
||||
event.shapeless("createaddition:redstone_relay", ["projectred_core:platformed_plate", "createaddition:connector"])
|
||||
.id("kubejs:compat/createaddition/redstone_relay_manual_only")
|
||||
event.recipes.create.deploying("createaddition:redstone_relay", ["projectred_core:platformed_plate", "createaddition:connector"])
|
||||
|
||||
// Remove heated basin ingot recipes
|
||||
event.remove({ id: "createaddition:mixing/electrum" })
|
||||
|
||||
// Connectors
|
||||
event.remove({ id: "createaddition:crafting/small_connector_copper" })
|
||||
event.remove({ id: "createaddition:crafting/large_connector_gold" })
|
||||
event.remove({ id: "createaddition:crafting/large_connector_electrum" })
|
||||
event.recipes.createSequencedAssembly(
|
||||
[Item.of("createaddition:connector", 4)],
|
||||
"create:andesite_alloy",
|
||||
[
|
||||
event.recipes.create.deploying("kubejs:incomplete_connector", ["kubejs:incomplete_connector", "#forge:rods/copper"]),
|
||||
event.recipes.create.deploying("kubejs:incomplete_connector", ["kubejs:incomplete_connector", "#forge:plates/iron"]),
|
||||
event.recipes.create.pressing("kubejs:incomplete_connector", "kubejs:incomplete_connector")
|
||||
]
|
||||
).transitionalItem("kubejs:incomplete_connector").loops(1)
|
||||
|
||||
event.recipes.createSequencedAssembly(
|
||||
[Item.of("createaddition:large_connector", 1)],
|
||||
"create:andesite_alloy",
|
||||
[
|
||||
event.recipes.create.deploying("kubejs:incomplete_connector", ["kubejs:incomplete_connector", "#forge:rods/gold"]),
|
||||
event.recipes.create.deploying("kubejs:incomplete_connector", ["kubejs:incomplete_connector", "#forge:plates/iron"]),
|
||||
event.recipes.create.pressing("kubejs:incomplete_connector", "kubejs:incomplete_connector"),
|
||||
event.recipes.create.deploying("kubejs:incomplete_connector", ["kubejs:incomplete_connector", "#forge:plates/iron"]),
|
||||
event.recipes.create.pressing("kubejs:incomplete_connector", "kubejs:incomplete_connector")
|
||||
]
|
||||
).transitionalItem("kubejs:incomplete_large_connector").loops(1)
|
||||
|
||||
// Bioethanol & Seed Oil in the Compression Dynamo
|
||||
event.recipes.thermal.compression_fuel(Fluid.of("createaddition:bioethanol", 1000)).energy(1000000)
|
||||
event.recipes.thermal.compression_fuel(Fluid.of("createaddition:seed_oil", 1000)).energy(30000)
|
||||
})
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
event.get("kubejs:cake_slices")
|
||||
.add("create_central_kitchen:chocolate_cake_slice")
|
||||
.add("create_central_kitchen:honey_cake_slice")
|
||||
|
||||
event.add("forge:storage_blocks/electrum", "createaddition:electrum_block")
|
||||
event.add("tconstruct:anvil_metal", "createaddition:electrum_block")
|
||||
})
|
||||
ServerEvents.tags("block", event => {
|
||||
event.add("minecraft:mineable/pickaxe", "createaddition:electrum_block")
|
||||
event.add("minecraft:needs_iron_tool", "createaddition:electrum_block")
|
||||
event.add("minecraft:beacon_base_blocks", "createaddition:electrum_block")
|
||||
event.add("tconstruct:anvil_metal", "createaddition:electrum_block")
|
||||
})
|
||||
|
||||
ServerEvents.blockLootTables(event => {
|
||||
event.addSimpleBlock("createaddition:electrum_block")
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
// Create Encased
|
||||
if (Platform.isLoaded("createcasing")) {
|
||||
ServerEvents.recipes(event => {
|
||||
|
||||
// Cleanup
|
||||
event.remove({ input: "minecraft:iron_block", mod: "createcasing" }) // Removes Presses
|
||||
event.remove({ input: "create:whisk", mod: "createcasing" }) // Removes Mixers
|
||||
event.remove({ input: "#forge:stripped_logs", mod: "createcasing" }) // Removes Wooden Shafts
|
||||
event.remove({ input: "create:brass_ingot", mod: "createcasing" }) // Removes Brass Shaft
|
||||
event.remove({ input: "minecraft:glass", mod: "createcasing" }) // Removes Glass Shaft
|
||||
|
||||
// Mixers
|
||||
let mixer = (output, casing) => {
|
||||
createMachine("create:mechanical_mixer", event, output, casing)
|
||||
}
|
||||
mixer("createcasing:brass_mixer", "create:brass_casing")
|
||||
mixer("createcasing:copper_mixer", "create:copper_casing")
|
||||
mixer("createcasing:industrial_iron_mixer", "create:industrial_iron_block")
|
||||
mixer("createcasing:railway_mixer", "create:railway_casing")
|
||||
mixer("createcasing:creative_mixer", "createcasing:creative_casing")
|
||||
|
||||
// Presses
|
||||
let press = (output, casing) => {
|
||||
createMachine("create:mechanical_press", event, output, casing)
|
||||
}
|
||||
press("createcasing:brass_press", "create:brass_casing")
|
||||
press("createcasing:copper_press", "create:copper_casing")
|
||||
press("createcasing:industrial_iron_press", "create:industrial_iron_block")
|
||||
press("createcasing:railway_press", "create:railway_casing")
|
||||
press("createcasing:creative_press", "createcasing:creative_casing")
|
||||
|
||||
// Adjustable Chain Gearshifts
|
||||
event.replaceInput(
|
||||
{ input: "create:electron_tube", mod: "createcasing" },
|
||||
"create:electron_tube",
|
||||
"minecraft:redstone"
|
||||
)
|
||||
|
||||
event.remove({ id: "createcasing:sequenced_assembly/chorium_ingot" })
|
||||
event.recipes.createSequencedAssembly([
|
||||
"createcasing:chorium_ingot",
|
||||
], "create:polished_rose_quartz", [
|
||||
// event.recipes.create.filling("createcasing:processing_chorium", ["createcasing:processing_chorium", Fluid.of("kubejs:matrix", 125)]),
|
||||
event.custom({
|
||||
type: "create:filling",
|
||||
ingredients: [
|
||||
{ item: "createcasing:processing_chorium" },
|
||||
{ type: "fluid_stack", amount: 125, fluid: "kubejs:matrix" },
|
||||
],
|
||||
results: [Item.of("createcasing:processing_chorium")],
|
||||
}),
|
||||
event.recipes.create.deploying("createcasing:processing_chorium", ["createcasing:processing_chorium", "minecraft:popped_chorus_fruit"]),
|
||||
event.recipes.create.pressing("createcasing:processing_chorium", "createcasing:processing_chorium")
|
||||
]).loops(4)
|
||||
.transitionalItem("createcasing:processing_chorium")
|
||||
.id("kubejs:compat/createcasing/chorium_ingot")
|
||||
})
|
||||
}
|
||||
@@ -0,0 +1,118 @@
|
||||
// Create Diesel Generators
|
||||
if (Platform.isLoaded("createdieselgenerators")) {
|
||||
ServerEvents.recipes(event => {
|
||||
|
||||
// Pumpjack Output
|
||||
event.replaceOutput({ output: "createdieselgenerators:crude_oil" },
|
||||
"createdieselgenerators:crude_oil",
|
||||
"thermal:crude_oil")
|
||||
|
||||
|
||||
// Duplicated Oils
|
||||
event.remove({ id: "createdieselgenerators:mixing/biodiesel" })
|
||||
event.remove({ id: "createdieselgenerators:compacting/plant_oil" })
|
||||
event.remove({ id: "createdieselgenerators:distillation/crude_oil" }) // Distillation outputs can"t be changed with scripts
|
||||
|
||||
// Crude Distilation
|
||||
event.custom({
|
||||
"type": "createdieselgenerators:distillation",
|
||||
"ingredients": [
|
||||
{ "fluid": "thermal:crude_oil", "amount": 200 }
|
||||
],
|
||||
"heatRequirement": "heated",
|
||||
"processingTime": 200,
|
||||
"results": [
|
||||
{ "fluid": "thermal:heavy_oil", "amount": 80 },
|
||||
{ "fluid": "thermal:light_oil", "amount": 120 },
|
||||
]
|
||||
})
|
||||
|
||||
// Crude Extraction
|
||||
copperMachine(event, Item.of("createdieselgenerators:pumpjack_hole", 1))
|
||||
invarMachine(event, Item.of("createdieselgenerators:pumpjack_crank", 1), "create:zinc_block")
|
||||
invarMachine(event, Item.of("createdieselgenerators:oil_scanner", 1), "ae2:charged_certus_quartz_crystal")
|
||||
event.replaceInput({ id: "createdieselgenerators:crafting/pumpjack_bearing" },
|
||||
"create:andesite_alloy",
|
||||
"thermal:invar_ingot")
|
||||
event.replaceInput({ id: "createdieselgenerators:crafting/pumpjack_head" },
|
||||
"create:zinc_ingot",
|
||||
"thermal:invar_ingot")
|
||||
|
||||
// Oil Engines
|
||||
event.remove({ id: "createdieselgenerators:crafting/engine_piston" }) // This one uses a Shaft instead of an Iron Rod
|
||||
event.remove({ id: "createdieselgenerators:crafting/diesel_engine" })
|
||||
event.recipes.create.mechanical_crafting("createdieselgenerators:diesel_engine", [
|
||||
" BLB ",
|
||||
"PPSPP",
|
||||
" BTB "], {
|
||||
L: "createdieselgenerators:lighter",
|
||||
P: "createdieselgenerators:engine_piston",
|
||||
B: "create:brass_ingot",
|
||||
S: "create:shaft",
|
||||
T: "create:fluid_tank",
|
||||
})
|
||||
zincMachine(event, Item.of("createdieselgenerators:large_diesel_engine", 1), "createdieselgenerators:diesel_engine")
|
||||
invarMachine(event, Item.of("createdieselgenerators:huge_diesel_engine", 1), "create:brass_block")
|
||||
|
||||
// Wooden Chips Patch
|
||||
event.remove({ id: "createdieselgenerators:crafting/chip_wood_block" }),
|
||||
event.shaped("createdieselgenerators:chip_wood_block", [
|
||||
"CCC",
|
||||
"CCC",
|
||||
"CCC"], {
|
||||
C: "createdieselgenerators:wood_chip" // Now uses 9 instead of 4 in order to prevent duping exploits
|
||||
})
|
||||
|
||||
// Asphalt from Bucket
|
||||
event.replaceInput({ id: "createdieselgenerators:crafting/asphalt_block" },
|
||||
"createdieselgenerators:crude_oil_bucket",
|
||||
"thermal:crude_oil_bucket")
|
||||
})
|
||||
|
||||
CDGEvents.fuelTypes((event) => {
|
||||
event.add("thermal:creosote").normalSpeed(64).normalStrength(2048).normalBurn(2)
|
||||
.modularSpeed(32).modularStrength(3072).normalBurn(6)
|
||||
.hugeSpeed(32).hugeStrength(3072).normalBurn(6)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("thermal:heavy_oil").normalSpeed(64).normalStrength(2048).normalBurn(2)
|
||||
.modularSpeed(96).modularStrength(6144).normalBurn(3)
|
||||
.hugeSpeed(128).hugeStrength(12288).normalBurn(4)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("thermal:light_oil").normalSpeed(64).normalStrength(3072).normalBurn(2)
|
||||
.modularSpeed(128).modularStrength(6144).normalBurn(3)
|
||||
.hugeSpeed(96).hugeStrength(6144).normalBurn(6)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("thermal:refined_fuel").normalSpeed(64).normalStrength(4096).normalBurn(1)
|
||||
.modularSpeed(128).modularStrength(8192).normalBurn(2)
|
||||
.hugeSpeed(128).hugeStrength(16384).normalBurn(4)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("thermal:tree_oil").normalSpeed(32).normalStrength(1024).normalBurn(1)
|
||||
.modularSpeed(64).modularStrength(2048).normalBurn(2)
|
||||
.hugeSpeed(64).hugeStrength(3072).normalBurn(6)
|
||||
.soundSpeed(1).burnerStrength(1).build();
|
||||
event.add("#forge:biofuel").normalSpeed(64).normalStrength(4096).normalBurn(3)
|
||||
.modularSpeed(128).modularStrength(8192).normalBurn(6)
|
||||
.hugeSpeed(128).hugeStrength(12288).normalBurn(12)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("#forge:diesel").normalSpeed(64).normalStrength(2048).normalBurn(2)
|
||||
.modularSpeed(96).modularStrength(6144).normalBurn(3)
|
||||
.hugeSpeed(128).hugeStrength(12288).normalBurn(4)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("#forge:gasoline").normalSpeed(64).normalStrength(2048).normalBurn(2)
|
||||
.modularSpeed(32).modularStrength(3072).normalBurn(6)
|
||||
.hugeSpeed(32).hugeStrength(3072).normalBurn(6)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("#forge:ethanol").normalSpeed(64).normalStrength(3072).normalBurn(3)
|
||||
.modularSpeed(96).modularStrength(6144).normalBurn(6)
|
||||
.hugeSpeed(96).hugeStrength(6144).normalBurn(12)
|
||||
.soundSpeed(2).burnerStrength(1).build();
|
||||
event.add("#forge:gasoline").normalSpeed(64).normalStrength(3072).normalBurn(2)
|
||||
.modularSpeed(128).modularStrength(6144).normalBurn(3)
|
||||
.hugeSpeed(96).hugeStrength(6144).normalBurn(6)
|
||||
.soundSpeed(3).burnerStrength(1).build();
|
||||
event.add("#forge:plantoil").normalSpeed(32).normalStrength(1024).normalBurn(1)
|
||||
.modularSpeed(64).modularStrength(2048).normalBurn(2)
|
||||
.hugeSpeed(64).hugeStrength(3072).normalBurn(6)
|
||||
.soundSpeed(1).burnerStrength(1).build();
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
// Not loaded by default anymore.
|
||||
if(Platform.isLoaded("forbidden_arcanus")) {
|
||||
unregistered_axes.push("forbidden_arcanus:draco_arcanus_axe")
|
||||
unregistered_axes.push("forbidden_arcanus:arcane_golden_axe")
|
||||
unregistered_axes.push("forbidden_arcanus:reinforced_arcane_golden_axe")
|
||||
|
||||
wood_types.push("forbidden_arcanus:fungyss")
|
||||
wood_types.push("forbidden_arcanus:aurum")
|
||||
wood_types.push("forbidden_arcanus:edelwood")
|
||||
ServerEvents.recipes(event => {
|
||||
event.remove({ id: "forbidden_arcanus:edelwood_bucket" })
|
||||
|
||||
event.remove({ id: "forbidden_arcanus:edelwood_stick" })
|
||||
event.shaped("3x forbidden_arcanus:edelwood_stick", [
|
||||
"S",
|
||||
"A",
|
||||
"S"
|
||||
], {
|
||||
S: "forbidden_arcanus:edelwood_planks",
|
||||
A: "minecraft:stick"
|
||||
})
|
||||
// Eternal stella
|
||||
event.remove({ id: "forbidden_arcanus:eternal_stella" })
|
||||
event.shaped("forbidden_arcanus:eternal_stella", [
|
||||
"PEP",
|
||||
"SDS",
|
||||
"PEP"
|
||||
], {
|
||||
P: "forbidden_arcanus:xpetrified_orb",
|
||||
E: "minecraft:emerald",
|
||||
S: "forbidden_arcanus:stellarite_piece",
|
||||
D: "rubber_duck:rubber_duck_item"
|
||||
})
|
||||
})
|
||||
// Hephaestus forge recipes can only be modified using datapacks
|
||||
|
||||
// ServerEvents.highPriorityData(event => {
|
||||
// event.addJson("forbidden_arcanus:hephaestus_forge/rituals/eternal_stella", {})
|
||||
// event.addJson("kubejs:hephaestus_forge/rituals/eternal_stella", {
|
||||
// "inputs": [
|
||||
// { "item": "forbidden_arcanus:xpetrified_orb", "slot": 0 },
|
||||
// { "item": "forbidden_arcanus:xpetrified_orb", "slot": 1 },
|
||||
// { "item": "minecraft:emerald", "slot": 2 },
|
||||
// { "item": "forbidden_arcanus:xpetrified_orb", "slot": 4 },
|
||||
// { "item": "forbidden_arcanus:stellarite_piece", "slot": 5 }
|
||||
// ],
|
||||
// "hephaestus_forge_item": "rubber_duck:rubber_duck_item",
|
||||
// "essences": { "aureal": 82, "blood": 1000, "souls": 1},
|
||||
// "result": { "item": "forbidden_arcanus:eternal_stella", "count": 1 }
|
||||
// })
|
||||
// })
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
if (Platform.isLoaded("integrated_stronghold")) {
|
||||
ServerEvents.tags("item", event => {
|
||||
event.get("kubejs:sellable_discs").add("integrated_stronghold:music_disc_sight", "integrated_stronghold:music_disc_forlorn");
|
||||
})
|
||||
}
|
||||
13
overrides/kubejs/server_scripts/startingitems.js
Normal file
13
overrides/kubejs/server_scripts/startingitems.js
Normal file
@@ -0,0 +1,13 @@
|
||||
/**
|
||||
* One-time give of items to new players
|
||||
*/
|
||||
|
||||
PlayerEvents.loggedIn(event => {
|
||||
// Check if player doesn't have "starting_items" stage yet
|
||||
if (!event.player.stages.has("starting_items")) {
|
||||
// Add the stage
|
||||
event.player.stages.add("starting_items")
|
||||
// Give qb to player
|
||||
event.player.give("ftbquests:book")
|
||||
}
|
||||
})
|
||||
306
overrides/kubejs/server_scripts/tags.js
Normal file
306
overrides/kubejs/server_scripts/tags.js
Normal file
@@ -0,0 +1,306 @@
|
||||
|
||||
ServerEvents.tags("item", event => {
|
||||
|
||||
event.add("forge:dusts/obsidian", "create:powdered_obsidian")
|
||||
event.add("forge:dusts", "create:powdered_obsidian")
|
||||
|
||||
// Fixes copper dupe.
|
||||
event.remove("forge:storage_blocks/copper", "minecraft:cut_copper");
|
||||
|
||||
colours.forEach(element => {
|
||||
event.get("forge:glazed_terracotta").add(`minecraft:${element}_glazed_terracotta`)
|
||||
});
|
||||
|
||||
global.trades.forEach(element => {
|
||||
event.get("kubejs:transaction_cards/import").add(`kubejs:trade_card_${element}`)
|
||||
});
|
||||
|
||||
global.professions.forEach(element => {
|
||||
event.get("kubejs:transaction_cards/profession").add(`kubejs:profession_card_${element}`)
|
||||
});
|
||||
|
||||
unregistered_axes.forEach(axe => {
|
||||
event.get("forge:tools/axes").add(axe)
|
||||
});
|
||||
|
||||
event.get("forge:vines").add("minecraft:vine")
|
||||
|
||||
// These items aren't obtainable at the moment.
|
||||
// This tag lets these items be melted into iron using the smeltery
|
||||
|
||||
// This tag lets these items be turned into circuit scraps and be melted into invar
|
||||
event.get("kubejs:circuit_press")
|
||||
.add("ae2:name_press")
|
||||
.add("ae2:silicon_press")
|
||||
.add("ae2:logic_processor_press")
|
||||
.add("ae2:engineering_processor_press")
|
||||
.add("ae2:calculation_processor_press")
|
||||
|
||||
event.get("forbidden_arcanus:modifier/eternal_incompatible")
|
||||
.add(/exchangers:.*/)
|
||||
.add(/reliquary:.*/)
|
||||
.add(/waterstrainer:.*/)
|
||||
.add("#occultism:miners/ores")
|
||||
.add("projectred_core:draw_plate")
|
||||
.add("projectred_core:multimeter")
|
||||
|
||||
// crafting tools for the chapters
|
||||
event.get("kubejs:saws").add("cb_microblock:stone_saw").add("cb_microblock:iron_saw").add("cb_microblock:diamond_saw")
|
||||
event.get("kubejs:screwdrivers").add("projectred_core:screwdriver")
|
||||
event.get("kubejs:chromatic_resonators").add("kubejs:chromatic_resonator")
|
||||
event.get("kubejs:flash_drives").add("kubejs:flash_drive")
|
||||
|
||||
event.get("kubejs:machines").add("kubejs:andesite_machine").add("kubejs:copper_machine").add("kubejs:gold_machine").add("kubejs:brass_machine").add("kubejs:zinc_machine").add("kubejs:lead_machine").add("thermal:machine_frame").add("kubejs:enderium_machine").add("ae2:controller")
|
||||
|
||||
event.get("kubejs:sellable_discs").add("minecraft:music_disc_13", "minecraft:music_disc_cat", "minecraft:music_disc_blocks", "minecraft:music_disc_chirp", "minecraft:music_disc_far", "minecraft:music_disc_mall", "minecraft:music_disc_mellohi", "minecraft:music_disc_stal", "minecraft:music_disc_strad", "minecraft:music_disc_ward", "minecraft:music_disc_11", "minecraft:music_disc_wait", "minecraft:music_disc_otherside", "minecraft:music_disc_5", "minecraft:music_disc_pigstep", "minecraft:music_disc_relic", "supplementaries:music_disc_heave_ho", "quark:music_disc_endermosh", "trials:music_disc_creator_box", "trials:music_disc_precipice", "trials:music_disc_creator", "biomesoplenty:music_disc_wanderer");
|
||||
event.get("kubejs:transaction_cards").add("#kubejs:transaction_cards/import")
|
||||
event.get("kubejs:transaction_cards").add("#kubejs:transaction_cards/profession")
|
||||
|
||||
event.add("kubejs:strainer/sands", "minecraft:sand")
|
||||
|
||||
event.get("kubejs:cake_slices")
|
||||
.add("farmersdelight:cake_slice")
|
||||
|
||||
event.remove("tconstruct:anvil_metal", "thermal:bronze_block")
|
||||
|
||||
// Create Deco laser lamps
|
||||
let decoLampColours = ["yellow", "red", "green", "blue"]
|
||||
let decoLampMaterials = ["andesite", "brass", "iron", "copper", "industrial_iron", "zinc"]
|
||||
for (let i = 0;i < decoLampColours.length;++i) {
|
||||
for (let j = 0;j < decoLampMaterials.length;++j) {
|
||||
let lamp = `createdeco:${decoLampColours[i]}_${decoLampMaterials[j]}_lamp`
|
||||
event.add("kubejs:alchemical_laser_lamps", lamp)
|
||||
event.add(`kubejs:alchemical_laser_lamps/${decoLampColours[i]}`, lamp)
|
||||
}
|
||||
}
|
||||
|
||||
// Ad Astra laser lamps
|
||||
for (let i = 0;i < colours.length;++i) {
|
||||
let lamp = `ad_astra:${colours[i]}_industrial_lamp`;
|
||||
event.add("kubejs:alchemical_laser_lamps", lamp)
|
||||
event.add(`kubejs:alchemical_laser_lamps/${colours[i]}`, lamp)
|
||||
lamp = `ad_astra:small_${colours[i]}_industrial_lamp`;
|
||||
event.add("kubejs:alchemical_laser_lamps", lamp)
|
||||
event.add(`kubejs:alchemical_laser_lamps/${colours[i]}`, lamp)
|
||||
}
|
||||
|
||||
// This tag prevents items from being consumed in press (market) recipes
|
||||
event.get("thermal:crafting/dies").add("#kubejs:transaction_cards")
|
||||
event.get("thermal:crafting/dies").add("kubejs:missingno")
|
||||
|
||||
event.get("thermal:crafting/casts").add("kubejs:three_cast").add("kubejs:eight_cast").add("kubejs:plus_cast").add("kubejs:minus_cast").add("kubejs:multiply_cast").add("kubejs:divide_cast").add("#kubejs:circuit_press")
|
||||
|
||||
event.get("create:upright_on_belt")
|
||||
.add("ae2:red_paint_ball")
|
||||
.add("ae2:yellow_paint_ball")
|
||||
.add("ae2:green_paint_ball")
|
||||
.add("ae2:blue_paint_ball")
|
||||
.add("ae2:magenta_paint_ball")
|
||||
.add("ae2:black_paint_ball")
|
||||
|
||||
// Items in the treasure tags are given as loot from treasure pots
|
||||
event.get("kubejs:treasure1")
|
||||
.add("minecraft:cobweb")
|
||||
.add("minecraft:dandelion")
|
||||
.add("minecraft:poppy")
|
||||
.add("minecraft:jungle_sapling")
|
||||
.add("minecraft:brown_mushroom")
|
||||
.add("minecraft:red_mushroom")
|
||||
.add("minecraft:bamboo")
|
||||
.add("minecraft:ladder")
|
||||
.add("minecraft:chain")
|
||||
.add("minecraft:flower_pot")
|
||||
.add("minecraft:painting")
|
||||
.add("minecraft:iron_nugget")
|
||||
.add("minecraft:gold_nugget")
|
||||
.add("create:copper_nugget")
|
||||
.add("create:zinc_nugget")
|
||||
.add("minecraft:charcoal")
|
||||
.add("minecraft:rotten_flesh")
|
||||
.add("minecraft:pumpkin_seeds")
|
||||
.add("minecraft:melon_seeds")
|
||||
.add("minecraft:bone_meal")
|
||||
.add("minecraft:paper")
|
||||
.add("farmersdelight:raw_pasta")
|
||||
.add("architects_palette:algal_blend")
|
||||
.add("farmersdelight:tree_bark")
|
||||
.add("create:cogwheel")
|
||||
.add("kubejs:sky_slimy_fern_leaf")
|
||||
.add("kubejs:earth_slimy_fern_leaf")
|
||||
.add("kubejs:ender_slimy_fern_leaf")
|
||||
.add("thermal:rubber")
|
||||
.add("thermal:phytogro")
|
||||
.add("create:andesite_alloy")
|
||||
.add("minecraft:poisonous_potato")
|
||||
|
||||
event.get("kubejs:treasure2")
|
||||
.add("minecraft:lantern")
|
||||
.add("minecraft:redstone")
|
||||
.add("minecraft:bow")
|
||||
.add("farmersdelight:rice")
|
||||
.add("supplementaries:copper_lantern")
|
||||
.add("supplementaries:brass_lantern")
|
||||
.add("supplementaries:sconce")
|
||||
.add("supplementaries:rope_arrow")
|
||||
.add("supplementaries:slingshot")
|
||||
.add("supplementaries:flax_seeds")
|
||||
.add("supplementaries:bomb")
|
||||
.add("farmersdelight:sweet_berry_cookie")
|
||||
.add("farmersdelight:cabbage_seeds")
|
||||
.add("farmersdelight:tomato_seeds")
|
||||
.add("minecraft:scute")
|
||||
.add("minecraft:iron_ingot")
|
||||
.add("minecraft:copper_ingot")
|
||||
.add("create:zinc_ingot")
|
||||
.add("thermal:rosin")
|
||||
.add("minecraft:spider_eye")
|
||||
.add("minecraft:nether_brick")
|
||||
.add("minecraft:beetroot_seeds")
|
||||
.add("minecraft:book")
|
||||
.add("minecraft:name_tag")
|
||||
.add("farmersdelight:rope")
|
||||
.add("create:cinder_flour")
|
||||
.add("tconstruct:seared_brick")
|
||||
.add("farmersdelight:canvas")
|
||||
.add("thermal:cinnabar")
|
||||
.add("thermal:sulfur")
|
||||
.add("thermal:niter")
|
||||
.add("thermal:apatite")
|
||||
.add("minecraft:compass")
|
||||
.add("minecraft:experience_bottle")
|
||||
.add("minecraft:golden_carrot")
|
||||
// .add('antiqueatlas:empty_antique_atlas')
|
||||
|
||||
// Treasure3 is only given from quartz pots
|
||||
event.get("kubejs:treasure3")
|
||||
.add("minecraft:skeleton_skull")
|
||||
.add("minecraft:clock")
|
||||
.add("minecraft:diamond")
|
||||
.add("minecraft:lapis_lazuli")
|
||||
.add("minecraft:zombie_head")
|
||||
.add("create:rose_quartz")
|
||||
.add("create:brass_hand")
|
||||
.add("minecraft:saddle")
|
||||
.add("ae2:certus_quartz_crystal")
|
||||
.add("ae2:fluix_crystal")
|
||||
.add("thermal:ice_charge")
|
||||
.add("thermal:lightning_charge")
|
||||
.add("thermal:earth_charge")
|
||||
.add("projectred_core:red_ingot")
|
||||
.add("thermal:ruby")
|
||||
.add("thermal:sapphire")
|
||||
.add("create:peculiar_bell")
|
||||
.add("minecraft:spectral_arrow")
|
||||
.add("minecraft:gold_ingot")
|
||||
.add("minecraft:magma_cream")
|
||||
.add("minecraft:ghast_tear")
|
||||
.add("minecraft:quartz")
|
||||
.add("minecraft:prismarine_shard")
|
||||
.add("minecraft:prismarine_crystals")
|
||||
.add("minecraft:chorus_fruit")
|
||||
.add("minecraft:blaze_powder")
|
||||
|
||||
event.get("kubejs:ore_processing/metal/dusts")
|
||||
.add("#forge:dusts/copper")
|
||||
.add("#forge:dusts/iron")
|
||||
.add("#forge:dusts/gold")
|
||||
.add("#forge:dusts/zinc")
|
||||
.add("#forge:dusts/lead")
|
||||
.add("#forge:dusts/nickel")
|
||||
|
||||
// This tag auto adds the beacon_payment_items tag which we don't want
|
||||
event.remove("create:create_ingots", "create:andesite_alloy")
|
||||
})
|
||||
|
||||
ServerEvents.tags("block", event => {
|
||||
|
||||
// Create Deco laser lamps
|
||||
let decoLampColours = ["yellow", "red", "green", "blue"]
|
||||
let decoLampMaterials = ["andesite", "brass", "iron", "copper", "industrial_iron", "zinc"]
|
||||
for (let i = 0;i < decoLampColours.length;++i) {
|
||||
for (let j = 0;j < decoLampMaterials.length;++j) {
|
||||
let lamp = `createdeco:${decoLampColours[i]}_${decoLampMaterials[j]}_lamp`
|
||||
event.add("kubejs:alchemical_laser_lamps", lamp)
|
||||
event.add(`kubejs:alchemical_laser_lamps/${decoLampColours[i]}`, lamp)
|
||||
}
|
||||
}
|
||||
|
||||
// Ad Astra laser lamps
|
||||
for (let i = 0;i < colours.length;++i) {
|
||||
let lamp = `ad_astra:${colours[i]}_industrial_lamp`;
|
||||
event.add("kubejs:alchemical_laser_lamps", lamp)
|
||||
event.add(`kubejs:alchemical_laser_lamps/${colours[i]}`, lamp)
|
||||
lamp = `ad_astra:small_${colours[i]}_industrial_lamp`;
|
||||
event.add("kubejs:alchemical_laser_lamps", lamp)
|
||||
event.add(`kubejs:alchemical_laser_lamps/${colours[i]}`, lamp)
|
||||
}
|
||||
|
||||
event.remove("tconstruct:anvil_metal", "thermal:bronze_block")
|
||||
|
||||
// Not sure if anything checks for this block tag but don't want to risk it.
|
||||
event.remove("forge:storage_blocks/copper", "minecraft:cut_copper");
|
||||
|
||||
// I don't know why this isn't wrenchable by default
|
||||
event.add("create:wrench_pickup", "minecraft:note_block")
|
||||
|
||||
event.add("create:wrench_pickup", "mbd2:strainer")
|
||||
|
||||
event.add("create:wrench_pickup", /thermal:machine/)
|
||||
event.add("create:wrench_pickup", /thermal:device/)
|
||||
event.add("create:wrench_pickup", /thermal:dynamo/)
|
||||
event.add("create:wrench_pickup", "thermal:tinker_bench")
|
||||
event.add("create:wrench_pickup", "thermal:charge_bench")
|
||||
event.add("create:wrench_pickup", "thermal:energy_cell_frame")
|
||||
event.add("create:wrench_pickup", "thermal:energy_cell")
|
||||
event.add("create:wrench_pickup", "thermal:fluid_cell_frame")
|
||||
event.add("create:wrench_pickup", "thermal:fluid_cell")
|
||||
event.add("create:wrench_pickup", "thermal:energy_duct")
|
||||
event.add("create:wrench_pickup", "thermal:fluid_duct")
|
||||
event.add("create:wrench_pickup", "thermal:fluid_duct_windowed")
|
||||
|
||||
event.add("create:wrench_pickup", "supplementaries:cog_block")
|
||||
event.add("create:wrench_pickup", "supplementaries:relayer")
|
||||
event.add("create:wrench_pickup", "supplementaries:spring_launcher")
|
||||
event.add("create:wrench_pickup", "supplementaries:speaker_block")
|
||||
event.add("create:wrench_pickup", "supplementaries:turn_table")
|
||||
// event.add("create:wrench_pickup", 'supplementaries:pulley_block')
|
||||
// event.add("create:wrench_pickup", 'supplementaries:hourglass')
|
||||
event.add("create:wrench_pickup", "supplementaries:bellows")
|
||||
event.add("create:wrench_pickup", "supplementaries:clock_block")
|
||||
event.add("create:wrench_pickup", "supplementaries:crystal_display")
|
||||
event.add("create:wrench_pickup", "supplementaries:sconce_lever")
|
||||
event.add("create:wrench_pickup", "supplementaries:crank")
|
||||
event.add("create:wrench_pickup", "supplementaries:wind_vane")
|
||||
event.add("create:wrench_pickup", "supplementaries:faucet")
|
||||
|
||||
event.add("create:wrench_pickup", "#kubejs:alchemical_laser_lamps")
|
||||
|
||||
event.add("create:wrench_pickup", "cb_multipart:multipart")
|
||||
|
||||
// Add tags to copper grates to allow fans to process through them
|
||||
event.get("create:fan_transparent")
|
||||
.add(/trials:copper_grate*/)
|
||||
.add(/trials:waxed_copper_grate*/)
|
||||
.add(/kubejs:trial_copper_grate*/)
|
||||
|
||||
// Add tags to basic vanilla-like chests and inventories to allow function with create contraptions
|
||||
event.get("create:chest_mounted_storage")
|
||||
.add(/^quark:.*_chest$|^everycomp:q.*_chest$/)
|
||||
|
||||
event.get("create:simple_mounted_storage")
|
||||
.add(/^farmersdelight:.*_cabinet$|^everycomp:fd.*_cabinet$/)
|
||||
// AE2 Sky stone chests (These don't work with the create:chest_mounted_storage tag for some reason so they are here instead)
|
||||
.add("ae2:sky_stone_chest")
|
||||
.add("ae2:smooth_sky_stone_chest")
|
||||
})
|
||||
|
||||
ServerEvents.tags("block_entity_type", event => {
|
||||
|
||||
// Add tags to basic vanilla-like chests and inventories to allow function with tinker's side inventory feature on crafting stations
|
||||
event.get("tconstruct:side_inventories")
|
||||
.add("quark:variant_chest")
|
||||
.add("quark:variant_trapped_chest")
|
||||
.add(/^everycomp:q.*_chest$/)
|
||||
.add("farmersdelight:cabinet")
|
||||
.add("ae2:sky_chest")
|
||||
})
|
||||
Reference in New Issue
Block a user