#I seem to have done everything right, but still getting the missing element error?

26 messages · Page 1 of 1 (latest)

drowsy hamlet
#
    event.create('incomplete_physgun', 'create:sequenced_assembly')
})

ServerEvents.recipes(event => {
const transitional = 'kubejs:incomplete_physgun'
    event.recipes.create.sequenced_assembly(
        [
            CreateItem.of('the_vmod:physgun',0.13)
        ],
        'vs_clockwork:gravitron',
        [
            event.recipes.create.deploying(transitional, [transitional, 'vstuff:energy_core']), 
            event.recipes.create.filling(transitional, [transitional, Fluid.of('spelunkery:portal_fluid', 500)])
        ]
    )
        .transitionalItem(transitional)
        .loops(10)
})```
im kinda stumped on this one. i read throught the examples, and checked to make sure i didnt repeat the same mistakes as the 3 other posts about this error, but im still getting a ``` missed ] after element list``` on line 14 (or so it claims)
pastel escarpBOT
#

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

normal quartz
#

CreateItem doesn't exist in 1.20.1
Use Item.of(item).withChance(chance)

#

Also, yeah, mostly correct, but first arguments of deploying and filling recipes should be arrays.

#

So [transitional], not transitional

#

Also, the chance in Sequenced Assembly outputs is actually weight

#

So since you have no random salvage defined, the output will be guaranteed

#

You could also try my Create Sequenced Assembly Builder which has less footguns compared to KJS Create syntax:
#1387020522566455437

#

Oh, wait, I see something definitely wrong:

#

You put StartupEvents and SeverEvents in the same script

#

StartupEvents will only work in startup scripts

#

While ServerEvents will only works in server scripts

mint seal
normal quartz
#

1.21.1 syntax for items with chance

mint seal
#

how is it different from Item.withChance()

normal quartz
#

1.21.1 does not support Item.withChance()

#

1.20.1 does

mint seal
#

hmm

#

was this a recent update to kjs cuz ive never seen this before, Item.withChance() worked before

#

this makes no sense and it hurts my brain pain

normal quartz
mint seal
#

im not saying what you said is wrong
im saying this change makes zero sense

drowsy hamlet
#

one last thing; when i try and launch with the transitional item in the startup script, it says unknown type 'create:sequenced_assembly' for object 'incomplete_physgun', is that also something only from the 1.21 environment?

normal quartz
#
StartupEvents.registry('item', event => {
  event.create("kubejs:custom", "create:sequenced_assembly")
})

Nah, this is valid if you have KubeJS Create (which you have)