KubeJS Create Integration
This mod provides complete compatibility between the popular Create mod and the powerful KubeJS scripting tool. Now you can easily configure and add Create recipes through convenient JavaScript scripts.
Supported Recipe Types
The mod allows working with all major Create mechanisms:
createCrushing- crushingcreateCutting- cuttingcreateMilling- millingcreateBasin- basin workcreateMixing- mixing (with support for .heated() and .superheated())createCompacting- compacting (with support for .heated() and .superheated())createPressing- pressingcreateSandpaperPolishing- sandpaper polishingcreateSplashing- washing (bulk)createDeploying- deployingcreateFilling- fillingcreateEmptying- emptying
Note: bulk smoking corresponds to regular smoking recipes, and bulk blasting corresponds to regular blasting recipes.
Recipe Syntax
To create a crushing recipe use:
event.recipes.createCrushing(output[], input[])
Output doesn't have to be an array. It can be items or fluids. Input can also be ingredients or fluids:
Fluid.of('minecraft:water', 1000)
{fluidTag: 'some:fluid_tag', amount: 1000}
Mechanical Crafting
For mechanical crafting use:
event.recipes.createMechanicalCrafting(output, pattern[], {patternKey: input})
This recipe type is similar to regular pattern crafting.
Sequenced Assembly
For complex multi-step recipes:
event.recipes.createSequencedAssembly(output[], input, sequence[])
// output[] - output items
// input - input item
// sequence[] - array of sequential steps
Usage Examples
Redstone crushing:
event.recipes.createCrushing([
'2x minecraft:cobblestone',
'minecraft:redstone',
Item.of('minecraft:redstone').withChance(0.5)
], 'minecraft:redstone_ore')
Mixing with superheating:
event.recipes.createMixing('create:chromatic_compound', [
'#forge:dusts/glowstone',
'#forge:dusts/glowstone',
'#forge:dusts/glowstone',
'create:powdered_obsidian',
'create:powdered_obsidian',
'create:powdered_obsidian',
'create:polished_rose_quartz'
]).superheated()
Filling with fluid:
event.recipes.createFilling('create:blaze_cake', [
'create:blaze_cake_base',
Fluid.of('minecraft:lava', 250)
])
Emptying a bottle:
event.recipes.createEmptying([
'minecraft:glass_bottle',
Fluid.of('create:honey', 250)
], 'minecraft:honey_bottle')
Mechanical piston crafting:
event.recipes.createMechanicalCrafting('minecraft:piston', [
'CCCCC',
'CPIPC',
'CPRPC'
], {
C: '#forge:cobblestone',
P: '#minecraft:planks',
R: '#forge:dusts:redstone',
I: '#forge:ingots/iron'
})
Advanced Features
To create your own transitional items in sequenced assembly, register them in the startup event:
onEvent('item.registry', event => {
// Texture for this item should be in kubejs/assets/kubejs/textures/item/my_part.png
event.create('my_part', 'create:sequenced_assembly').displayName('My Part')
})
Then use transitionalItem('kubejs:my_part') in your recipes.
Important! Mysterious conversion recipes work only on the client side. To add them, use this code in client scripts (outside any events):
let MysteriousItemConversionCategory = java('com.simibubi.create.compat.jei.category.MysteriousItemConversionCategory')
let ConversionRecipe = java('com.simibubi.create.compat.jei.ConversionRecipe')
MysteriousItemConversionCategory.RECIPES.add(ConversionRecipe.create('minecraft:apple', 'minecraft:carrot'))
MysteriousItemConversionCategory.RECIPES.add(ConversionRecipe.create('minecraft:golden_apple', 'minecraft:golden_carrot'))