#KubeJS fails to load scripts MC 1.20

55 messages · Page 1 of 1 (latest)

normal needle
#

Trying to add recipies and i do not think I have the file type right. Assumed it needs to be .js but I do not even get console.log('Hello! The recipe event has fired!') command to fire.
Current file structure is: "...\kubejs\server_scripts\ore_veins.js"

digital needleBOT
#

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

winter bramble
#

that is correct hmmm

#

what is your current code>

normal needle
#

Attempting to add ore veins to a create add-on mod

#

ServerEvents.recipes(event => {

//Adding veins

event.recipes.createoreexcavation.vein('{"text": "uranium vein"}', 'mekanism:raw_uranium').placement(1024, 128, 64825185).id("kubejs:uranium_vein")

....
event.recipes.createoreexcavation.extracting('minecraft:lava', 'kubejs:lava_vein', 10).id("kubejs:mod_vein8");

console.log('Hello! The recipe event has fired!')

});

#

Could upload the js to you if that would be easier.

winter bramble
#

can you send your server.log

normal needle
tropic gustBOT
#

Paste version of server.log from @normal needle

winter bramble
#

says you have zero scripts

#
Loaded 0/0 KubeJS server scripts in 0.004 s
#

so that sounds like youre either not saving the script, or editing the file for a different instance

normal needle
#

Confirmed script is in the same instance i am loading. and also verified the file is saved and closed

winter bramble
#

can i see a screenshot of your file explorer that also shows the path

normal needle
winter bramble
winter bramble
# normal needle

when did you run the game to generate this log? the time is a bit sussy

normal needle
#

sent you the log from this directory

winter bramble
#

i get that, but when did you generate it

#

aka when did you load into the game

#

is this time correct

normal needle
#

it should be. i just launched and exited it a bit ago

#

i will relaunch again

winter bramble
#

does it still say 0/0

normal needle
#

yes

normal needle
#

Do I need any kind of syntax at the start of the JS file?

winter bramble
#

nope, im not sure whats happening there to be completely honest

#

maybe someone else knows

normal needle
#

1 last question, if there are no other mods are those example.js files suppose to kick off when you launch a new world?

winter bramble
#

it depends on the folder and the events you use

#

some, yes, work when you launch a new world

normal needle
#

thanks for the help. Tried a brand new instance and only had this mod loaded and tried 'hello world' to display on the server scripts and got nothin. for whatever reason it feels like kube is not seeing the scripts folders. will throw a few other attempts at it

winter bramble
#

id just wait until others can look at this

normal needle
#

dont suppose theres a few debug commands that can be ran. havnt had any luck finding commands in the wiki. nod

winter bramble
#

but its the middle of the night for most people here, so might have to wait a good few hours

normal needle
#

lol yeah it is getting late

winter bramble
#

im gonna link this thread in a private channel we have, cuz im curious whats going on here too

normal needle
#

thanks again for atleast ruling out the starter stuff

winter bramble
#

lets hope someone sees something ive missed

normal needle
#

Interesting to see what looks like the same issue for another user | Loaded 0/0 KubeJS in 1.20 but not 1.19

normal needle
#

KubeJS fails to load scripts MC 1.20

winter bramble
#

@normal needle what version of KJS are you on

#

just saw

KubeJS 2001.6.3-build.57

normal needle
#

kubejs-forge-2001.6.3-build.57.jar

solar pumice
#

I'm having the same issue, same conditions. Scripts files are saved in the correct folder, while using version kubejs-forge-2001.6.3-build.61.jar

honest oriole
#

It definitely works fine in my dev, this is super weird

solar pumice
#

The example.js scripts that are auto generated also don't work

honest oriole
#

definitely mod issue not script issue

solar pumice
#

@winter bramble Mentioned a private thread about this issue, may I follow?

honest oriole
#

private channel