#help with kubejs and totem of undying

28 messages · Page 1 of 1 (latest)

stoic veldt
#

So, I want to make a recipe for the totem of undying, for context i am playing with the "rats" mod and want to make it cheap, not to use it on me but on my rats, the thing is, i have tried to make the recipe like twenty times and it always gives me errors, help. this is my code right now:

onEvent('recipes', event => {

event.shaped('minecraft:totem_of_undying', [
    'ABA',
    'BBB',
    ' B '
], {
    N: 'minecraft:emerald',
    W: 'minecraft:gold_ingot'
})
vagrant surgeBOT
#

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

lusty lichen
#

change N to A and W to B

stoic veldt
#

omg i am so stupid

#

still does not work

#

onEvent('recipes', event => {

event.shaped('minecraft:totem_of_undying', [
    'ABA',
    'BBB',
    ' B '
], {
    A: 'minecraft:emerald',
    B: 'minecraft:gold_ingot'
})
maiden torrent
#

The recipe works for me

#

Is that all that's in your js file?

stoic veldt
#

yes

#

i am scared

maiden torrent
#

You're missing a closing bracket then

stoic veldt
#

should i send the ingame error?

stoic veldt
maiden torrent
#

I think

stoic veldt
#

where?

lusty lichen
#

at the end

stoic veldt
#

uhm, sorry to be so stupid but what is a closing bracket

#

ive never coded

maiden torrent
#
onEvent('recipes', event => {

    event.shaped('minecraft:totem_of_undying', [
        'ABA',
        'BBB',
        ' B '
    ], {
        A: 'minecraft:emerald',
        B: 'minecraft:gold_ingot'
    })
})```
stoic veldt
#

so i just copy that?

maiden torrent
#

Try it

#

I think it should work

stoic veldt
#

lets see

#

yep

maiden torrent
#

You didn't close off your recipe event

stoic veldt
#

ohh ok

#

thanks you two

maiden torrent
#

Np