#Using Enchanted Books in recipes

46 messages · Page 1 of 1 (latest)

elfin light
#

when i went to make a recipe for an item to make ppl use more mods to get broken stuff, i made this recipe and most things work:

event.recipes.industrialforegoing.dissolution_chamber([
        'projecte:low_covalence_dust',
        'projecte:medium_covalence_dust',
        'projecte:high_covalence_dust',
        'string',
        'paper',
        Item.of('minecraft:enchanted_book').enchant('minecraft:mending', 1)
    ]

except the e-book in JEI shows as just a normal book regardless of how many /reloads i do

turbid wrenBOT
#

Once your ticket has been resolved, please close it with </ticket close:1054771505520717835> command!

elfin light
#

it even works as expected

#

nvm, it doesnt-

latent star
#

what even is that syntax coloring? raha

#

anyways

#

you might have to add .strongNBT() at the end

latent star
autumn jetty
#

its a wierd thing, pretend you dont know about it

latent star
#

what even is that? raha

autumn jetty
#

or was

latent star
autumn jetty
#

its just bleh

elfin light
latent star
elfin light
#

how i got that info in the first place was /kubejs hand

elfin light
#

anything else i should try?

elfin light
#

Hello?

inland wren
#

event.recipes.industrialforegoing.dissolution_chamber([
'projecte:low_covalence_dust',
'projecte:medium_covalence_dust',
'projecte:high_covalence_dust',
'string',
'paper',
Item.of('minecraft:enchanted_book').withNBT({
Enchantments: [{lvl: 1, id: "minecraft:mending"}]
})
]

#

something like that should work

latent star
#
  1. you don't need the .withNBT(), just add it as an argument
  2. ⬇️
#

??codeblock

dull spireBOT
# latent star ??codeblock

You can write your code in a codeblock by typing it between the codeblock delimiters:

```js :arrow_left:

ServerEvents.recipes(event => {
event.smelting('minecraft:glass', '#forge:sand').xp(.1)
})

``` :arrow_left:

As an example, :arrow_up: will look like this:

ServerEvents.recipes(event => {
  event.smelting('minecraft:glass', '#forge:sand').xp(.1)
})
elfin light
#

i tried both methods, neither worked...

rigid parcel
#

so first the recipes you have posted above seems to be incomplete and only has Inputs and second the recipe may doesn't Support nbt in input items.

latent star
rigid parcel
#

yeah

elfin light
#

well damn, that stinks...

#

somethin i gotta throw in the GH if one exists

elfin light
#

here's the full script in case u wanna take a sniff at it:

ServerEvents.recipes(event => {

    event.remove({output: 'projecte:philosophers_stone'})
    event.remove({output: 'projecte:repair_talisman'})
    event.remove({output: 'projecte:harvest_goddess_band'})

    event.recipes.create.mechanical_crafting('projecte:philosophers_stone', [
        'RSSSSSR',
        'SSGGGSS',
        'SG1D2GS',
        'SGDNDGS',
        'SG3D4GS',
        'SSGGGSS',
        'RSSSSSR',
    ], {
        R: 'redstone',
        S: '#dar:soul_items',
        G: '#forge:dusts/gold',
        D: 'diamond',
        N: 'nether_star',
        1: 'botania:rune_fire',
        2: 'botania:rune_water',
        3: 'botania:rune_earth',
        4: 'botania:rune_air'
    })
    event.recipes.industrialforegoing.dissolution_chamber([
        'projecte:low_covalence_dust',
        'projecte:medium_covalence_dust',
        'projecte:high_covalence_dust',
        'string',
        'paper',
        Item.of('minecraft:enchanted_book', {StoredEnchantments: [{lvl: 1, id: "minecraft:mending"}]}).strongNBT()
    ],
    'create_enchantment_industry:hyper_experience',
    'projecte:repair_talisman',
    100).outputFluid("create_enchantment_industry:experience");
    event.recipes.thermal.bottler('projecte:harvest_goddess_band', [Fluid.of('cyclic:biomass', 200),'projecte:iron_band'])
})
rigid parcel
#

can you try event.custom and without stuff like item.of?

#

so pure json basically

elfin light
#

i could take a crack at it, but how would i tell it wut book specifically?

rigid parcel
#
{
  item: "something",
  count: 1
  nbt: 'nbt_json'
}
elfin light
#

hmmmmm, will try this out

rigid parcel
elfin light
#

it still bein stinky...

rigid parcel
#

Then there's probably No way to use nbt in input. You could make a simple conversion recipe that lets you convert the book into a custom Item and the use that.

#

You could also ask the moddev If this is really not supported / there's adifferent key / to add the tag support for input items.

elfin light
#

ill take a crack at it

elfin light
#

apparently if something was to be done for this issue, it'd b for the latest version of the game...

elfin light
#

looks like im sniffin for a new recipe handler!

elfin light
#

alr, until IF decides to enable NBT in recipes, i've found other methods of making these recipes work